跳转到内容
简体中文

邮箱设置

PATCH/v1/mailboxes/{mailbox_id}

通过 /v1 可修改 name、password 和 signature。共用配额 quota_mb 请在托管服务控制面板中修改。文件没有独立配额。Idempotency-Key 为可选项,但建议在重试时使用。

授权和访问区域 · 错误和重复

要求

终端窗口
curl -X PATCH 'https://adapt-mail.com/v1/mailboxes/<mailbox_id>' \
-H 'Authorization: Bearer <access_token>' \
-H 'Idempotency-Key: message-20261019-0001' \
-H 'Content-Type: application/json' \
--data '{"name":"Support","signature":"Support team"}'

选项

mailbox_idpath一定

integer

X-Customer-IDheader
选项 1

string

选项 2

null

Idempotency-Keyheader

string

minLength: 8

maxLength: 128

请求正文 · application/json

object

name
选项 1

string

minLength: 1

maxLength: 120

选项 2

null

quota_mb
选项 1

integer

minimum: 10240

选项 2

null

file_quota_mb
选项 1

integer

minimum: 256

maximum: 512000

选项 2

null

password
选项 1

string

minLength: 12

maxLength: 128

选项 2

null

signature
选项 1

string

maxLength: 5000

选项 2

null

不接受未知字段。

响应

202 成功回复

application/json

object

id

string · uuid

用于检查状态和取消待处理提交的操作 ID。

kind

string

mailbox_id
选项 1

integer

选项 2

null

status

string

有效值: "queued" "running" "succeeded" "failed" "uncertain" "cancelled"

run_at

string

UTC. 中的日期和时间 如果没有偏移,该值也代表 UTC.

created_at

string

UTC. 中的日期和时间 如果没有偏移,该值也代表 UTC.

completed_at
选项 1

string

UTC. 中的日期和时间 如果没有偏移,该值也代表 UTC.

选项 2

null

error

如果操作未成功完成,则错误的原因。

选项 1

string

选项 2

null

result

操作的结果。对于发送,包含有关接受和拒绝的收件人的信息。

选项 1

object

选项 2

null

400 标头或标识符无效

application/json

object

detail
选项 1

string

选项 2

object

code

string

message

string

选项 3

array

数组元素

object

401 需要登录

application/json

object

detail
选项 1

string

选项 2

object

code

string

message

string

选项 3

array

数组元素

object

403 无法访问

application/json

object

detail
选项 1

string

选项 2

object

code

string

message

string

选项 3

array

数组元素

object

404 找不到资源

application/json

object

detail
选项 1

string

选项 2

object

code

string

message

string

选项 3

array

数组元素

object

409 国家冲突

application/json

object

detail
选项 1

string

选项 2

object

code

string

message

string

选项 3

array

数组元素

object

422 验证错误

application/json

object

detail

array

数组元素

object

loc一定

array

数组元素
选项 1

string

选项 2

integer

msg一定

string

type一定

string

503 暂时无法使用

application/json

object

detail
选项 1

string

选项 2

object

code

string

message

string

选项 3

array

数组元素

object