EmailOffer
A domain's email offer in the deprecated Email API: get or update it.
Operations
Every route this entity exposes. Each route links to its own reference on this page.
| Method | Route | SDK operation | Returns |
|---|---|---|---|
GET |
/email/offers/{domain} |
load |
OK |
PATCH |
/email/offers/{domain} |
update |
Accepted |
Examples
One example per SDK, generated from the API model. The argument names are the parameters and fields of this entity, and the values are placeholders. The examples are not compiled or executed.
Golang
Construct client as shown in the Golang setup, then call the operations:
email_offer, err := client.EmailOffer(nil).Load(map[string]any{"domain": "example"}, nil)
if err != nil {
panic(err)
}
fmt.Println(email_offer)
updated, err := client.EmailOffer(nil).Update(map[string]any{"domain": "example", "antispam": "example"}, nil)
if err != nil {
panic(err)
}
fmt.Println(updated)
Lua
Construct client as shown in the Lua setup, then call the operations:
local email_offer, err = client:EmailOffer():load({ domain = "example" })
local updated, err = client:EmailOffer():update({ domain = "example", antispam = "example" })
PHP
Construct client as shown in the PHP setup, then call the operations:
$email_offer = $client->EmailOffer()->load(["domain" => "example"]);
$updated = $client->EmailOffer()->update(["domain" => "example", "antispam" => "example"]);
Python
Construct client as shown in the Python setup, then call the operations:
email_offer = client.EmailOffer().load({"domain": "example"})
updated = client.EmailOffer().update({"domain": "example", "antispam": "example"})
Ruby
Construct client as shown in the Ruby setup, then call the operations:
email_offer = client.EmailOffer.load({ "domain" => "example" })
updated = client.EmailOffer.update({ "domain" => "example", "antispam" => "example" })
TypeScript
Construct client as shown in the TypeScript setup, then call the operations:
const email_offer = await client.EmailOffer().load({ domain: "example" })
const updated = await client.EmailOffer().update({ domain: "example", antispam: "example" })
Fields
| Field | Type | Required | Description |
|---|---|---|---|
antispam |
string |
Yes | Antispam |
dkim |
string |
Yes | Dkim |
message |
string |
Yes | Message |
status |
string |
Yes | Status |
version |
integer |
Yes | Version |
load
GET /email/offers/{domain}
Operation ID: getEmailOffersDomain.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
domain |
path |
string |
Yes |
Responses
200: OK
application/json
| Property | Type | Required | Description |
|---|---|---|---|
antispam |
enum: active, inactive, mixed |
Yes | |
dkim |
enum: active, inactive |
Yes | |
status |
enum: active, inactive |
Yes | |
version |
enum: 1, 2, 3 |
Yes |
401: Unauthorized
application/json
| Property | Type | Required | Description |
|---|---|---|---|
cause |
string |
Yes | |
code |
integer |
Yes | |
message |
string |
Yes | |
object |
string |
Yes |
403: Forbidden
application/json
| Property | Type | Required | Description |
|---|---|---|---|
cause |
string |
Yes | |
code |
integer |
Yes | |
message |
string |
Yes | |
object |
string |
Yes |
update
PATCH /email/offers/{domain}
Operation ID: patchEmailOffersDomain.
Authentication: bearer token (bearerAuth).
Parameters
| Parameter | In | Type | Required | Description |
|---|---|---|---|---|
domain |
path |
string |
Yes |
Request body
application/json
| Property | Type | Required | Description |
|---|---|---|---|
antispam |
enum: active, inactive |
Yes | |
dkim |
enum: active, inactive |
Yes |
Responses
202: Accepted
application/json
| Property | Type | Required | Description |
|---|---|---|---|
message |
string |
Yes |
401: Unauthorized
application/json
| Property | Type | Required | Description |
|---|---|---|---|
cause |
string |
Yes | |
code |
integer |
Yes | |
message |
string |
Yes | |
object |
string |
Yes |
403: Forbidden
application/json
| Property | Type | Required | Description |
|---|---|---|---|
cause |
string |
Yes | |
code |
integer |
Yes | |
message |
string |
Yes | |
object |
string |
Yes |