API

MailboxProduct

The mailbox products on offer, and buying one (create).

Operations

Every route this entity exposes. Each route links to its own reference on this page.

Method Route SDK operation Returns
POST /mailbox/products create Accepted
GET /mailbox/products list OK

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:

mailbox_products, err := client.MailboxProduct(nil).List(nil, nil)
if err != nil {
    panic(err)
}
fmt.Println(mailbox_products)
created, err := client.MailboxProduct(nil).Create(map[string]any{"config_name": "example", "duration_month": 1, "quantity": 1}, nil)
if err != nil {
    panic(err)
}
fmt.Println(created)

Lua

Construct client as shown in the Lua setup, then call the operations:

local mailbox_products, err = client:MailboxProduct():list()
local created, err = client:MailboxProduct():create({ config_name = "example", duration_month = 1, quantity = 1 })

PHP

Construct client as shown in the PHP setup, then call the operations:

$mailbox_products = $client->MailboxProduct()->list();
$created = $client->MailboxProduct()->create(["config_name" => "example", "duration_month" => 1, "quantity" => 1]);

Python

Construct client as shown in the Python setup, then call the operations:

mailbox_products = client.MailboxProduct().list()
created = client.MailboxProduct().create({ "config_name": "example", "duration_month": 1, "quantity": 1 })

Ruby

Construct client as shown in the Ruby setup, then call the operations:

mailbox_products = client.MailboxProduct.list()
created = client.MailboxProduct.create({ "config_name" => "example", "duration_month" => 1, "quantity" => 1 })

TypeScript

Construct client as shown in the TypeScript setup, then call the operations:

const mailbox_products = await client.MailboxProduct().list()
const created = await client.MailboxProduct().create({ config_name: "example", duration_month: 1, quantity: 1 })

Fields

Field Type Required Description
autorenew boolean No Autorenew
config array Yes Config
config_name string Yes Config Name
description string Yes Description
duration_month integer Yes Duration Month
label string Yes Label
message string Yes Message
prices array Yes Prices
quantity integer Yes Quantity
taxes array Yes Taxes
uuid string Yes Uuid

create

POST /mailbox/products

Operation ID: postMailboxProducts.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
sharing_id query string No

Request body

application/json

Property Type Required Description
autorenew boolean No
config_name enum: standard, premium Yes
duration_month enum: 1, 12 Yes
quantity integer 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

list

GET /mailbox/products

Operation ID: getMailboxProducts.

Authentication: bearer token (bearerAuth).

Parameters

Parameter In Type Required Description
sharing_id query string No

Responses

200: OK

application/json

Property Type Required Description
[].config array of object Yes
[].config[].label string Yes
[].config[].name string Yes
[].config[].uuid string Yes
[].config_name string Yes
[].description string Yes
[].label string Yes
[].prices array of object Yes
[].prices[].currency string Yes
[].prices[].duration_unit string Yes
[].prices[].max_duration integer Yes
[].prices[].min_duration integer Yes
[].prices[].normal_price_after_taxes number Yes
[].prices[].normal_price_before_taxes number Yes
[].prices[].price_after_taxes number Yes
[].prices[].price_before_taxes number Yes
[].taxes array of object Yes
[].taxes[].name string Yes
[].taxes[].name_label string Yes
[].taxes[].rate number Yes
[].taxes[].type string Yes
[].uuid 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