SparkPost API (v1)
https://sp-api.omnivery.net/api/v1
Omnivery API allows you to send messages, retrieve delivery stats, check and configure your sending domains and more in multiple formats. This documentation covers the SparkPost compatible API of Omnivery.
As this API is fully compatible with the SparkPost (v1) API any existing software or library supporting SparkPost (v1) API should work without any changes required. The only change that may be required would be the change of the endpoint and API token.
This REST API requires all requests to be authenticated using Authentication header with your access token as a value. API tokens can be found in the UI under Credentials menu in API Keys tab (for domain specific/sending tokens) or under API keys menu. For security reasons we strongly suggest using domain specific API keys rather than account API keys whenever possible.
All data to the API endpoint must be posted in JSON format.
Authentication
-
API Key:
API Key in header as
Authorization
Enter your credentials below to use the Try it feature:
Sending Domains
This endpoint is only accessible using a primary API key.
Verifies all the domain settings required for use of the domain for sending and receiving messages.
Request will perform a complete validation check of all required DNS records. All options available in the original Sparkpost API are ignored, eg. (dkim_verify, cname_verify, spf_verify, etc.)
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | Authorization header must contain your account's primary API token |
domain |
path | string | Yes | Domain name to verify |
Responses
OK
Code Samples
curl -X POST 'https://sp-api.omnivery.net/api/v1/sending-domains/{domain}/verify' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://sp-api.omnivery.net/api/v1/sending-domains/{domain}/verify", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/sending-domains/{domain}/verify', {
method: 'POST',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/sending-domains/{domain}/verify');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.post(
'https://sp-api.omnivery.net/api/v1/sending-domains/{domain}/verify',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
This endpoint is only accessible using a primary API key.
Returns a list of domains under your account in JSON. See examples.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | Authorization header must contain your account's primary API token |
Responses
OK
Code Samples
curl -X GET 'https://sp-api.omnivery.net/api/v1/sending-domains' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://sp-api.omnivery.net/api/v1/sending-domains", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/sending-domains', {
method: 'GET',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/sending-domains');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.get(
'https://sp-api.omnivery.net/api/v1/sending-domains',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
This endpoint is only accessible using a primary API key.
Create a sending domain by providing a sending domain object as the POST request body.
For compatibility reasons the API call will ignore parameters specific to Sparkpost's environment like tracking_domain, dkim, generate_dkim or shared_with_subaccounts.
NOTE: Omnivery takes care of automatic DKIM key rotation using CNAMEs. To facilitate a proper domain setup the response contains an object with all DNS records that need to be set instead of the DKIM object with the selector and public key.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | Authorization header must contain your account's primary API token |
Content-Type |
header | string | Yes | application/json |
Request Body application/json
| Field | Type | Required | Description |
|---|---|---|---|
domain |
string | Yes | The domain or subdomain to create |
Responses
OK
Payment Required
Code Samples
curl -X POST 'https://sp-api.omnivery.net/api/v1/sending-domains' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY' \
-d '{"domain": "string"}'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://sp-api.omnivery.net/api/v1/sending-domains", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/sending-domains', {
method: 'POST',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
body: JSON.stringify({"domain": "string"})
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/sending-domains');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"domain": "string"}');
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.post(
'https://sp-api.omnivery.net/api/v1/sending-domains',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
json={"domain": "string"}
)
print(response.json())
Response
This endpoint is only accessible using a primary API key.
Retrieve a sending domain by specifying its domain name in the URI path. The response includes details about its DKIM key configuration.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | Authorization header must contain your account's primary API token |
Responses
Sending domain detail object
Code Samples
curl -X GET 'https://sp-api.omnivery.net/api/v1/sending-domains/{domain}' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://sp-api.omnivery.net/api/v1/sending-domains/{domain}", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/sending-domains/{domain}', {
method: 'GET',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/sending-domains/{domain}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.get(
'https://sp-api.omnivery.net/api/v1/sending-domains/{domain}',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
This endpoint is only accessible using a primary API key.
Delete an existing sending domain.
Warning: Before deleting a sending domain please ensure you are no longer using it. After deleting a sending domain, any new transmissions that use it will result in a rejection. This includes any transmissions that are in progress, scheduled for the future, or use a stored template referencing the sending domain.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | Authorization header must contain your account's primary API token |
domain |
path | string | Yes | The domain to be deleted |
Responses
No Content
Not Found
Code Samples
curl -X DELETE 'https://sp-api.omnivery.net/api/v1/sending-domains/{domain}' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("DELETE", "https://sp-api.omnivery.net/api/v1/sending-domains/{domain}", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/sending-domains/{domain}', {
method: 'DELETE',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/sending-domains/{domain}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'DELETE');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.delete(
'https://sp-api.omnivery.net/api/v1/sending-domains/{domain}',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
Transmissions
This endpoint is only accessible using both sending and primary API keys. If primary API key is used the
return_pathattribute is required to identify the domain to be used.
You can create a transmission using SparkPost API in a number of ways.
Using Inline Email Part Content
Create a transmission using inline email part content.
Using Inline RFC822 Content (MIME)
Create a transmission using inline RFC822 content. Content headers are not generated for transmissions providing RFC822 content. They are expected to be provided as headers contained in the RFC822 content.
Using a Stored Template
Create a transmission using a stored template by specifying the template_id in the content attribute.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | Authorization header must contain your domain's sending API token or your account's primary API token |
Content-Type |
header | string | Yes | application/json |
Request Body application/json
| Field | Type | Required | Description | ||||||||||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
substitution_data |
object | No | Substitution data are global data substituted for all recipients of this transmission. Substitution data supplied in the recipient's object will override the transmission substitution data |
||||||||||||||||||||||||
return_path |
string | No | Return path allows you to select your sending domain in case you are using a primary API token and in that case it is a required parameter. When using sending API token the return_path attribute has no use |
||||||||||||||||||||||||
campaign_id |
string | No | Campaign ID of your choice to help you identify campaigns. This could be helpful in the future when identifying messages of a larger send. |
||||||||||||||||||||||||
options |
object | No | Message level settings to override the domain level settings |
||||||||||||||||||||||||
recipients |
array | Yes | Recipients object contains not only recipient's address but can also include variables to be passed to template. |
||||||||||||||||||||||||
|
|||||||||||||||||||||||||||
content |
object | Yes | Content object carries the information about the sender (from), message subject as well as message body. The message body can be supplied in multiple formats or retrieved from a template. |
||||||||||||||||||||||||
metadata |
object | No | Metadata are global metadata applied to all recipients of this transmission. Metadata supplied in the recipient's object will override the transmission metadata |
||||||||||||||||||||||||
Responses
Code Samples
curl -X POST 'https://sp-api.omnivery.net/api/v1/transmissions' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY' \
-d '{"substitution_data": {}, "return_path": "string", "campaign_id": "string", "options": {}, "recipients": [], "content": {}, "metadata": {}}'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://sp-api.omnivery.net/api/v1/transmissions", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/transmissions', {
method: 'POST',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
body: JSON.stringify({"substitution_data": {}, "return_path": "string", "campaign_id": "string", "options": {}, "recipients": [], "content": {}, "metadata": {}})
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/transmissions');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"substitution_data": {}, "return_path": "string", "campaign_id": "string", "options": {}, "recipients": [], "content": {}, "metadata": {}}');
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.post(
'https://sp-api.omnivery.net/api/v1/transmissions',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
json={"substitution_data": {}, "return_path": "string", "campaign_id": "string", "options": {}, "recipients": [], "content": {}, "metadata": {}}
)
print(response.json())
Response
Recipient Validation
Runs a given address through a series of checks that catch many common problems, including syntax issues and non-existent mailboxes.
To perform email validation your sending domain must have email validation enabled and you must use your sending domain's API credentials not the account level credentials.
Responses
OK
Code Samples
curl -X POST 'https://sp-api.omnivery.net/api/v1/recipient-validation/single/{address}' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("POST", "https://sp-api.omnivery.net/api/v1/recipient-validation/single/{address}", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/recipient-validation/single/{address}', {
method: 'POST',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/recipient-validation/single/{address}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'POST');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.post(
'https://sp-api.omnivery.net/api/v1/recipient-validation/single/{address}',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
Suppression List
This endpoint is only accessible using a primary API key.
Retrieve the suppression status for a specific recipient by specifying the recipient’s email address in the URI path.
If the recipient is not in the domain-specific exclusion list, an HTTP status of 404 is returned. If the recipient is in the list, an HTTP status of 200 is returned with the full suppression status in the response body.
Due to differences in architecture this endpoint requires the
domainto be passed in the URL and as result its URL is not identical to that used by Sparkpost. Make sure your API library reflects this change.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | |
Accept |
header | string | Yes | |
domain |
path | string | Yes | |
recipient |
path | string | Yes |
Responses
OK
Code Samples
curl -X GET 'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}', {
method: 'GET',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.get(
'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
This endpoint is only accessible using a primary API key.
Delete a recipient from the list by specifying the recipient's email address in the URI path.
If the recipient is not in the domain-specific exclusion list, an HTTP status of 404 is returned. If the recipient is in the list, an HTTP status of 204 is returned indicating a successful deletion.
Due to differences in architecture this endpoint requires the
domainto be passed in the URL and as result its URL is not identical to that used by Sparkpost. Make sure your API library reflects this change.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | |
Accept |
header | string | Yes | |
domain |
path | string | Yes | |
recipient |
path | string | Yes | |
recipient |
query | string | No | Recipient email address |
Request Body application/json
Responses
No Content
Not Found
Code Samples
curl -X DELETE 'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("DELETE", "https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}', {
method: 'DELETE',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'DELETE');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.delete(
'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list/{recipient}',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
This endpoint is only accessible using a primary API key.
Perform a filtered search for entries in your domain-specific exclusion list.
Due to differences in architecture this endpoint requires the
domainto be passed in the URL and as result its URL is not identical to that used by Sparkpost. Make sure your API library reflects this change.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | |
Accept |
header | string | Yes | |
domain |
path | string | Yes | |
from |
query | string | No | Filter results by date starting from |
to |
query | string | No | Filter results by date ending at |
per_page |
query | number | No | Output record limit |
page |
query | number | No | Result page |
sources |
query | string | No | Sources (one of |
Responses
OK
Bad Request
Code Samples
curl -X GET 'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://sp-api.omnivery.net/api/v1/{domain}/suppression-list", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list', {
method: 'GET',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.get(
'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())
Response
This endpoint is only accessible using a primary API key.
Bulk insert entries to the domain-specific exclusion list by providing a JSON object, with a "recipients" key containing an array of recipients to insert or update, as the PUT request body. Maximum size of the JSON object is 10mb. At a minimum, each recipient must have a valid "email" address in recipient field. The optional "description" key can be used to include an explanation of what type of message should be suppressed.
If the type field is used with value transactional the record will be added to the "block" suppressions, otherwise the "unsubscribe" suppression will be used.
If an email address is duplicated in a single request, only the first instance will be processed.
Due to differences in architecture this endpoint requires the
domainto be passed in the URL and as result its URL is not identical to that used by Sparkpost. Make sure your API library reflects this change.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Content-Type |
header | string | No | |
Accept |
header | string | Yes | |
Authorization |
header | string | Yes | |
domain |
path | string | Yes |
Request Body application/json
| Field | Type | Required | Description | ||||||||||||||||
|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|---|
recipients |
array | Yes | |||||||||||||||||
|
|||||||||||||||||||
Responses
OK
Code Samples
curl -X PUT 'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY' \
-d '{"recipients": []}'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("PUT", "https://sp-api.omnivery.net/api/v1/{domain}/suppression-list", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list', {
method: 'PUT',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
body: JSON.stringify({"recipients": []})
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/{domain}/suppression-list');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'PUT');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
curl_setopt($ch, CURLOPT_POSTFIELDS, '{"recipients": []}');
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.put(
'https://sp-api.omnivery.net/api/v1/{domain}/suppression-list',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
json={"recipients": []}
)
print(response.json())
Response
Account Info
This endpoint is only accessible using a primary API key.
Returns complete information about your account, it's settings and current plan and its usage.
Parameters
| Name | In | Type | Required | Description |
|---|---|---|---|---|
Authorization |
header | string | Yes | Authorization header must contain your account's primary API token |
Responses
OK
Code Samples
curl -X GET 'https://sp-api.omnivery.net/api/v1/account' \
-H 'Content-Type: application/json' \
-H 'Authorization: YOUR_API_KEY'
package main
import (
"fmt"
"net/http"
)
func main() {
req, _ := http.NewRequest("GET", "https://sp-api.omnivery.net/api/v1/account", nil)
req.Header.Set("Authorization", "YOUR_API_KEY")
resp, _ := http.DefaultClient.Do(req)
fmt.Println(resp.Status)
}
const response = await fetch('https://sp-api.omnivery.net/api/v1/account', {
method: 'GET',
headers: {'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
});
const data = await response.json();
<?php
$ch = curl_init('https://sp-api.omnivery.net/api/v1/account');
curl_setopt($ch, CURLOPT_CUSTOMREQUEST, 'GET');
curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);
curl_setopt($ch, CURLOPT_HTTPHEADER, ['Authorization: YOUR_API_KEY']);
$response = curl_exec($ch);
curl_close($ch);
echo $response;
import requests
response = requests.get(
'https://sp-api.omnivery.net/api/v1/account',
headers={'Content-Type': 'application/json', 'Authorization': 'YOUR_API_KEY'},
)
print(response.json())