# SDKs & tools

Official v1 API clients in four languages, the OpenAPI spec and a Postman collection. Use a test_ key to try everything: nothing is sent or charged. Base URL: `https://app.ogave.co`

## SDKs {#sdks}

### PHP 8.1+

[Download messaging-api-php-1.1.0.tar.gz](https://app.ogave.co/sdks/messaging-api-php-1.1.0.tar.gz) sha256 929fa5c78987069f1f392eac8862468b72b683ebfd6bc73f8bb160f064363369

```
composer config repositories.msg artifact ./dist
composer require messaging-api/sdk:1.1.0
```

```
$client = new MessagingApi\Client(getenv('API_KEY'), 'https://app.ogave.co');
$m = $client->send(['to' => '+573001234567', 'from' => 'SHOP', 'text' => 'Hello']);
```

### Node.js 18+ / TypeScript

[Download messaging-api-1.1.0.tgz](https://app.ogave.co/sdks/messaging-api-1.1.0.tgz) sha256 5da13ec310996529fff216292219351f034a62ed2cbc4cda00dc9dbe4c115976

```
npm install ./messaging-api-1.1.0.tgz
```

```
const { Client } = require('messaging-api');
const client = new Client(process.env.API_KEY, 'https://app.ogave.co');
const m = await client.send({ to: '+573001234567', from: 'SHOP', text: 'Hello' });
```

### Python 3.9+

[Download messaging_api-1.1.0.tar.gz](https://app.ogave.co/sdks/messaging_api-1.1.0.tar.gz) sha256 95925e9053605f09cb7d74c00e845afe7c1d928f5f15794f4f481123842b803f

```
pip install messaging_api-1.1.0.tar.gz
```

```
from messaging_api import Client
client = Client(os.environ['API_KEY'], 'https://app.ogave.co')
m = client.send({'to': '+573001234567', 'from': 'SHOP', 'text': 'Hello'})
```

### Java 11+

[Download messaging-api-1.1.0.jar](https://app.ogave.co/sdks/messaging-api-1.1.0.jar) sha256 75de751503b4c0bf94aace101e12760ad7366c590630806b3af2154de99d3791

```
mvn install:install-file -Dfile=messaging-api-1.1.0.jar -DpomFile=messaging-api-1.1.0.pom
```

```
Client client = new Client(System.getenv("API_KEY"), "https://app.ogave.co");
Map<String, Object> m = client.send(Map.of("to", "+573001234567", "from", "SHOP", "text", "Hello"));
```

Java sources (with pom.xml): [messaging-api-java-1.1.0.tar.gz](https://app.ogave.co/sdks/messaging-api-java-1.1.0.tar.gz)

## Command line (msg) {#cli}

Node 18+, no dependencies: SMS, email, Verify and following delivery live from a terminal or a script. [Download messaging-cli-1.1.0.tgz](https://app.ogave.co/sdks/messaging-cli-1.1.0.tgz) sha256 e6c43c9209954d790dbbead1e2b102ab4c4dbe085bb43e1bea366cab12916d08

```
npm install -g ./messaging-cli-1.1.0.tgz
msg config set host https://app.ogave.co
msg config set key live_…
msg sms send --to +573001234567 --from SHOP --text "Hello"
msg email send --to ana@example.com --subject "Receipt" --text "Thanks" --attach receipt.pdf
msg verify start --to ana@example.com --channel email
msg messages tail --since 10m
```

## What they do {#features}

- Messages (send, batch, quote, get, list, cancel), email (send, get, list, identities — 1.1.0), Verify, contacts and lists, hooks, conversions, balance and pricing; any other endpoint with request().
- Retries with exponential backoff and Retry-After on 429, 5xx and network errors; POSTs carry an automatic Idempotency-Key, so a retry never sends twice.
- Typed errors: AuthenticationError, PermissionError, NotFoundError, ValidationError, RateLimitError (status, code, param, request id).
- Webhook signature check (Webhook-Signature header, 5-minute tolerance).

## OpenAPI 3.1 {#openapi}

[openapi.json](https://app.ogave.co/docs/api/openapi.json) · [openapi.yaml](https://app.ogave.co/openapi.yaml) — checked against the real API routes; use it to generate clients in other languages.

## Postman {#postman}

[Collection](https://app.ogave.co/docs/api/postman_collection.json) + [environment](https://app.ogave.co/docs/api/postman_environment.json). Import both and put your test_ key in apiKey.
