@primitivedotdev/sdk 0.31.1 → 0.31.3
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/api/index.d.ts +2 -2
- package/dist/api/index.js +3 -3
- package/dist/{api-CMzxyIqH.js → api-DiUGdSFW.js} +95 -14
- package/dist/{index-BwDgniCA.d.ts → index-C4cblPLp.d.ts} +452 -26
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/openapi/index.js +1 -1
- package/dist/{operations.generated-BOlpIYkQ.js → operations.generated-fblmB6G9.js} +1393 -129
- package/package.json +1 -1
|
@@ -10,7 +10,7 @@ const openapiDocument = {
|
|
|
10
10
|
"info": {
|
|
11
11
|
"title": "Primitive API",
|
|
12
12
|
"version": "1.0.0",
|
|
13
|
-
"description": "The Primitive API lets you manage domains, emails, webhook endpoints,\nfilters, and account settings programmatically.\n\n## Authentication\n\nMost endpoints require a Bearer token in the `Authorization` header:\n\n```\nAuthorization: Bearer prim_<your_api_key>\n```\n\nAPI keys are org-scoped. Create and manage them in your dashboard\nunder Settings > API Keys. CLI login
|
|
13
|
+
"description": "The Primitive API lets you manage domains, emails, webhook endpoints,\nfilters, and account settings programmatically.\n\n## Authentication\n\nMost endpoints require a Bearer token in the `Authorization` header:\n\n```\nAuthorization: Bearer prim_<your_api_key>\n```\n\nAPI keys are org-scoped. Create and manage them in your dashboard\nunder Settings > API Keys. CLI login plus CLI/agent signup endpoints\nexplicitly declare `security: []`; they do not require an API key because\nthey are used to create OAuth CLI sessions.\n\n## Rate Limiting\n\nThe API enforces a sliding window rate limit of **120 requests per\n60 seconds** per organization. When exceeded, the API returns `429`\nwith a `Retry-After` header indicating how many seconds to wait.\n\n## Pagination\n\nList endpoints use cursor-based pagination. Responses include a\n`meta` object with `total`, `limit`, and `cursor` fields. Pass the\n`cursor` value as a query parameter to fetch the next page. When\n`cursor` is `null`, there are no more results.\n\n## Response Format\n\nAll responses use a consistent envelope:\n\n```json\n{\n \"success\": true,\n \"data\": { ... },\n \"meta\": { \"total\": 42, \"limit\": 50, \"cursor\": \"...\" }\n}\n```\n\nErrors follow the same pattern:\n\n```json\n{\n \"success\": false,\n \"error\": { \"code\": \"not_found\", \"message\": \"Email not found\" }\n}\n```\n\n## Webhook signing\n\nOutbound webhook deliveries (configured via the `endpoints` API)\nare signed so receivers can verify they came from Primitive and\nhave not been tampered with in transit. The signing scheme is\ndeliberately simple so it can be reimplemented in any language\nin a few lines. The Node SDK's `verifyWebhookSignature` helper\nis the reference implementation; the wire details below let you\nwrite a verifier in Python, Go, Ruby, etc. without reading our\nsource.\n\n**Header**: `Primitive-Signature: t=<unix-seconds>,v1=<hex>`\n\nA legacy `MyMX-Signature` header is also sent on every delivery\nwith the same value, retained for back-compatibility with\nintegrations written before the rename. New code should read\n`Primitive-Signature`.\n\n**Signed string**: `${timestamp}.${rawBody}` where `timestamp`\nis the Unix-seconds integer from the `t=` parameter and\n`rawBody` is the exact bytes of the HTTP request body BEFORE\nany JSON decoding. Verify against the raw body, not a\nre-serialized parse, or you will silently mismatch on\ninsignificant whitespace.\n\n**Signature**: HMAC-SHA256 of the signed string, hex-encoded\n(lowercase). Use the account's webhook secret as the HMAC key,\nas a UTF-8 byte sequence.\n\n**Secret**: returned by `GET /account/webhook-secret`. The\nstring looks base64-shaped (e.g. `XNHBBW8VqoBjRfNs1tkZj11jTk...`)\nbut is NOT base64; use it AS-IS as a UTF-8 string for the HMAC\nkey. Base64-decoding before HMAC will silently produce\nmismatched signatures.\n\n**Tolerance**: by convention, reject deliveries whose `t=`\ntimestamp is more than 5 minutes off your wall-clock to defend\nagainst replay attacks. The Node SDK's helper enforces this by\ndefault.\n\n**Verification recipe** (any language):\n\n```\n1. Read the raw HTTP body (do not parse).\n2. Read `Primitive-Signature: t=<ts>,v1=<sig>`.\n3. Reject if abs(now - ts) > 300 seconds.\n4. expected = HMAC_SHA256_hex(secret_utf8, f\"{ts}.{rawBody}\")\n5. Constant-time compare expected to sig. Reject if not equal.\n```\n\nFor Node, use `verifyWebhookSignature` from\n`@primitivedotdev/sdk/webhook` (or the higher-level\n`handleWebhook` helper if you want a one-liner). For other\nlanguages, the recipe above is everything you need.\n\nTest deliveries: `POST /endpoints/{id}/test` triggers a fake\ndelivery to your endpoint URL, signed with your real account\nsecret, so you can confirm verification end-to-end without\nneeding real inbound mail. The test response carries the exact\n`signature` header value sent on the wire so you can compare\nstrings directly.\n",
|
|
14
14
|
"contact": {
|
|
15
15
|
"name": "Primitive",
|
|
16
16
|
"url": "https://primitive.dev"
|
|
@@ -33,6 +33,10 @@ const openapiDocument = {
|
|
|
33
33
|
"name": "CLI",
|
|
34
34
|
"description": "Browser-assisted CLI authentication"
|
|
35
35
|
},
|
|
36
|
+
{
|
|
37
|
+
"name": "Agent",
|
|
38
|
+
"description": "Agent signup and authentication"
|
|
39
|
+
},
|
|
36
40
|
{
|
|
37
41
|
"name": "Account",
|
|
38
42
|
"description": "Manage your account settings, storage, and webhook secret"
|
|
@@ -96,7 +100,7 @@ const openapiDocument = {
|
|
|
96
100
|
"/cli/login/poll": { "post": {
|
|
97
101
|
"operationId": "pollCliLogin",
|
|
98
102
|
"summary": "Poll CLI browser login",
|
|
99
|
-
"description": "Polls a CLI login session until the browser approval either succeeds,\nis denied, expires, or is polled too quickly. The
|
|
103
|
+
"description": "Polls a CLI login session until the browser approval either succeeds,\nis denied, expires, or is polled too quickly. The OAuth token set is\ncreated only after approval and is returned exactly once.\n",
|
|
100
104
|
"tags": ["CLI"],
|
|
101
105
|
"security": [],
|
|
102
106
|
"requestBody": {
|
|
@@ -105,7 +109,7 @@ const openapiDocument = {
|
|
|
105
109
|
},
|
|
106
110
|
"responses": {
|
|
107
111
|
"200": {
|
|
108
|
-
"description": "CLI login approved and
|
|
112
|
+
"description": "CLI login approved and OAuth token set created",
|
|
109
113
|
"headers": { "Cache-Control": {
|
|
110
114
|
"schema": { "type": "string" },
|
|
111
115
|
"description": "Always `no-store`"
|
|
@@ -246,8 +250,8 @@ const openapiDocument = {
|
|
|
246
250
|
} },
|
|
247
251
|
"/cli/signup/verify": { "post": {
|
|
248
252
|
"operationId": "verifyCliSignup",
|
|
249
|
-
"summary": "Verify CLI signup and create
|
|
250
|
-
"description": "Verifies the email code for a CLI signup session, creates the account,\nredeems the reserved signup code,
|
|
253
|
+
"summary": "Verify CLI signup and create OAuth session",
|
|
254
|
+
"description": "Verifies the email code for a CLI signup session, creates the account,\nredeems the reserved signup code, creates an org-scoped OAuth CLI\nsession, and returns the token set exactly once. This endpoint does not\nrequire an API key.\n",
|
|
251
255
|
"tags": ["CLI"],
|
|
252
256
|
"security": [],
|
|
253
257
|
"requestBody": {
|
|
@@ -256,7 +260,7 @@ const openapiDocument = {
|
|
|
256
260
|
},
|
|
257
261
|
"responses": {
|
|
258
262
|
"200": {
|
|
259
|
-
"description": "CLI signup verified and
|
|
263
|
+
"description": "CLI signup verified and OAuth token set created",
|
|
260
264
|
"headers": { "Cache-Control": {
|
|
261
265
|
"schema": { "type": "string" },
|
|
262
266
|
"description": "Always `no-store`"
|
|
@@ -273,10 +277,106 @@ const openapiDocument = {
|
|
|
273
277
|
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
274
278
|
}
|
|
275
279
|
} },
|
|
280
|
+
"/agent/signup/start": { "post": {
|
|
281
|
+
"operationId": "startAgentSignup",
|
|
282
|
+
"summary": "Start agent account signup",
|
|
283
|
+
"description": "Starts an agent-native signup session. The API validates the signup code,\ncreates a pending signup session, sends an email verification code, and\nreturns an opaque signup token used by the resend and verify steps. This\nendpoint does not require an API key.\n",
|
|
284
|
+
"tags": ["Agent"],
|
|
285
|
+
"security": [],
|
|
286
|
+
"requestBody": {
|
|
287
|
+
"required": true,
|
|
288
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/StartAgentSignupInput" } } }
|
|
289
|
+
},
|
|
290
|
+
"responses": {
|
|
291
|
+
"201": {
|
|
292
|
+
"description": "Agent signup session created and verification email sent",
|
|
293
|
+
"headers": { "Cache-Control": {
|
|
294
|
+
"schema": { "type": "string" },
|
|
295
|
+
"description": "Always `no-store`"
|
|
296
|
+
} },
|
|
297
|
+
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
298
|
+
"type": "object",
|
|
299
|
+
"properties": { "data": { "$ref": "#/components/schemas/AgentSignupStartResult" } }
|
|
300
|
+
}] } } }
|
|
301
|
+
},
|
|
302
|
+
"400": { "$ref": "#/components/responses/ValidationError" },
|
|
303
|
+
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
304
|
+
}
|
|
305
|
+
} },
|
|
306
|
+
"/agent/signup/resend": { "post": {
|
|
307
|
+
"operationId": "resendAgentSignupVerification",
|
|
308
|
+
"summary": "Resend agent signup verification code",
|
|
309
|
+
"description": "Sends a new email verification code for a pending agent signup session.\nThis endpoint does not require an API key.\n",
|
|
310
|
+
"tags": ["Agent"],
|
|
311
|
+
"security": [],
|
|
312
|
+
"requestBody": {
|
|
313
|
+
"required": true,
|
|
314
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/ResendAgentSignupVerificationInput" } } }
|
|
315
|
+
},
|
|
316
|
+
"responses": {
|
|
317
|
+
"200": {
|
|
318
|
+
"description": "Verification email resent",
|
|
319
|
+
"headers": { "Cache-Control": {
|
|
320
|
+
"schema": { "type": "string" },
|
|
321
|
+
"description": "Always `no-store`"
|
|
322
|
+
} },
|
|
323
|
+
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
324
|
+
"type": "object",
|
|
325
|
+
"properties": { "data": { "$ref": "#/components/schemas/AgentSignupResendResult" } }
|
|
326
|
+
}] } } }
|
|
327
|
+
},
|
|
328
|
+
"400": {
|
|
329
|
+
"description": "Invalid token or expired token",
|
|
330
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } }
|
|
331
|
+
},
|
|
332
|
+
"429": {
|
|
333
|
+
"description": "Global rate limit exceeded or resend requested too quickly",
|
|
334
|
+
"headers": { "Retry-After": {
|
|
335
|
+
"schema": { "type": "integer" },
|
|
336
|
+
"description": "Seconds to wait before retrying"
|
|
337
|
+
} },
|
|
338
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } }
|
|
339
|
+
}
|
|
340
|
+
}
|
|
341
|
+
} },
|
|
342
|
+
"/agent/signup/verify": { "post": {
|
|
343
|
+
"operationId": "verifyAgentSignup",
|
|
344
|
+
"summary": "Verify agent signup and create OAuth tokens",
|
|
345
|
+
"description": "Verifies the email code for an agent signup session, creates the account\nwhen needed, redeems the reserved signup code, mints an org-scoped OAuth\nsession for CLI authentication, and returns the raw tokens exactly once.\nFor existing users, the optional `org_id` selects which accessible\nworkspace should receive the new session.\n",
|
|
346
|
+
"tags": ["Agent"],
|
|
347
|
+
"security": [],
|
|
348
|
+
"requestBody": {
|
|
349
|
+
"required": true,
|
|
350
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/VerifyAgentSignupInput" } } }
|
|
351
|
+
},
|
|
352
|
+
"responses": {
|
|
353
|
+
"200": {
|
|
354
|
+
"description": "Agent signup verified and OAuth tokens created",
|
|
355
|
+
"headers": { "Cache-Control": {
|
|
356
|
+
"schema": { "type": "string" },
|
|
357
|
+
"description": "Always `no-store`"
|
|
358
|
+
} },
|
|
359
|
+
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
360
|
+
"type": "object",
|
|
361
|
+
"properties": { "data": { "$ref": "#/components/schemas/AgentSignupVerifyResult" } }
|
|
362
|
+
}] } } }
|
|
363
|
+
},
|
|
364
|
+
"400": {
|
|
365
|
+
"description": "Invalid request, invalid verification code, expired token, invalid signup code, or account creation failure",
|
|
366
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } }
|
|
367
|
+
},
|
|
368
|
+
"403": { "$ref": "#/components/responses/Forbidden" },
|
|
369
|
+
"409": {
|
|
370
|
+
"description": "Existing account is not in a usable workspace state",
|
|
371
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/ErrorResponse" } } }
|
|
372
|
+
},
|
|
373
|
+
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
374
|
+
}
|
|
375
|
+
} },
|
|
276
376
|
"/cli/logout": { "post": {
|
|
277
377
|
"operationId": "cliLogout",
|
|
278
|
-
"summary": "Revoke the current CLI
|
|
279
|
-
"description": "Revokes the
|
|
378
|
+
"summary": "Revoke the current CLI OAuth session",
|
|
379
|
+
"description": "Revokes the OAuth grant used to authenticate the request. API-key\nauthenticated legacy logout requests succeed without deleting server API\nkeys so old local CLI state can be cleared safely.\n",
|
|
280
380
|
"tags": ["CLI"],
|
|
281
381
|
"requestBody": {
|
|
282
382
|
"required": false,
|
|
@@ -284,7 +384,7 @@ const openapiDocument = {
|
|
|
284
384
|
},
|
|
285
385
|
"responses": {
|
|
286
386
|
"200": {
|
|
287
|
-
"description": "CLI
|
|
387
|
+
"description": "CLI logout completed",
|
|
288
388
|
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
289
389
|
"type": "object",
|
|
290
390
|
"properties": { "data": { "$ref": "#/components/schemas/CliLogoutResult" } }
|
|
@@ -410,7 +510,7 @@ const openapiDocument = {
|
|
|
410
510
|
"post": {
|
|
411
511
|
"operationId": "addDomain",
|
|
412
512
|
"summary": "Claim a new domain",
|
|
413
|
-
"description": "Creates an unverified domain claim
|
|
513
|
+
"description": "Creates an unverified domain claim and returns the exact\nDNS records to publish in `dns_records`. Publish those\nrecords before calling the verify endpoint. To give users\nan importable DNS file, call `downloadDomainZoneFile` or run\n`primitive domains zone-file --id <domain-id>`.\n",
|
|
414
514
|
"tags": ["Domains"],
|
|
415
515
|
"requestBody": {
|
|
416
516
|
"required": true,
|
|
@@ -503,7 +603,7 @@ const openapiDocument = {
|
|
|
503
603
|
"post": {
|
|
504
604
|
"operationId": "verifyDomain",
|
|
505
605
|
"summary": "Verify domain ownership",
|
|
506
|
-
"description": "Checks DNS records
|
|
606
|
+
"description": "Checks DNS records required for inbound routing, ownership,\nand outbound authentication: MX, ownership TXT, SPF, DKIM,\nDMARC, and TLS-RPT.\nOn success, the domain is promoted from unverified to verified.\nOn failure, returns which checks passed and which failed,\nplus the exact DNS records still expected. To give users\nan importable DNS file for missing records, call\n`downloadDomainZoneFile` or run\n`primitive domains zone-file --id <domain-id>`.\n",
|
|
507
607
|
"tags": ["Domains"],
|
|
508
608
|
"responses": {
|
|
509
609
|
"200": {
|
|
@@ -519,6 +619,38 @@ const openapiDocument = {
|
|
|
519
619
|
}
|
|
520
620
|
}
|
|
521
621
|
},
|
|
622
|
+
"/domains/{id}/zone-file": {
|
|
623
|
+
"parameters": [{ "$ref": "#/components/parameters/ResourceId" }],
|
|
624
|
+
"get": {
|
|
625
|
+
"operationId": "downloadDomainZoneFile",
|
|
626
|
+
"summary": "Download domain DNS zone file",
|
|
627
|
+
"description": "Downloads a BIND-format DNS zone file containing the DNS records\nrequired for a domain claim. Agents should offer this after\n`addDomain` when users want to import DNS records instead of\ncopying each record manually.\n",
|
|
628
|
+
"tags": ["Domains"],
|
|
629
|
+
"parameters": [{
|
|
630
|
+
"name": "outbound_only",
|
|
631
|
+
"in": "query",
|
|
632
|
+
"schema": { "type": "boolean" },
|
|
633
|
+
"description": "When true, include only outbound DNS records. Verified domains\ndefault to outbound-only; pending claims default to all required\nrecords.\n"
|
|
634
|
+
}],
|
|
635
|
+
"responses": {
|
|
636
|
+
"200": {
|
|
637
|
+
"description": "BIND-format zone file",
|
|
638
|
+
"content": { "text/plain": { "schema": {
|
|
639
|
+
"type": "string",
|
|
640
|
+
"format": "binary"
|
|
641
|
+
} } },
|
|
642
|
+
"headers": { "Content-Disposition": { "schema": {
|
|
643
|
+
"type": "string",
|
|
644
|
+
"example": "attachment; filename=\"example.com.zone\""
|
|
645
|
+
} } }
|
|
646
|
+
},
|
|
647
|
+
"400": { "$ref": "#/components/responses/ValidationError" },
|
|
648
|
+
"401": { "$ref": "#/components/responses/Unauthorized" },
|
|
649
|
+
"404": { "$ref": "#/components/responses/NotFound" },
|
|
650
|
+
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
651
|
+
}
|
|
652
|
+
}
|
|
653
|
+
},
|
|
522
654
|
"/emails": { "get": {
|
|
523
655
|
"operationId": "listEmails",
|
|
524
656
|
"summary": "List inbound emails",
|
|
@@ -2012,7 +2144,14 @@ const openapiDocument = {
|
|
|
2012
2144
|
"slow_down",
|
|
2013
2145
|
"access_denied",
|
|
2014
2146
|
"expired_token",
|
|
2015
|
-
"invalid_device_code"
|
|
2147
|
+
"invalid_device_code",
|
|
2148
|
+
"invalid_signup_code",
|
|
2149
|
+
"invalid_signup_token",
|
|
2150
|
+
"invalid_verification_code",
|
|
2151
|
+
"email_delivery_failed",
|
|
2152
|
+
"clerk_signup_failed",
|
|
2153
|
+
"no_orgs_for_user",
|
|
2154
|
+
"org_not_accessible"
|
|
2016
2155
|
]
|
|
2017
2156
|
},
|
|
2018
2157
|
"message": { "type": "string" },
|
|
@@ -2196,13 +2335,42 @@ const openapiDocument = {
|
|
|
2196
2335
|
"properties": {
|
|
2197
2336
|
"api_key": {
|
|
2198
2337
|
"type": "string",
|
|
2199
|
-
"description": "
|
|
2338
|
+
"description": "Legacy alias for access_token. New CLI builds should persist access_token and refresh_token."
|
|
2200
2339
|
},
|
|
2201
2340
|
"key_id": {
|
|
2341
|
+
"type": "string",
|
|
2342
|
+
"format": "uuid",
|
|
2343
|
+
"description": "Legacy alias for oauth_grant_id"
|
|
2344
|
+
},
|
|
2345
|
+
"key_prefix": {
|
|
2346
|
+
"type": "string",
|
|
2347
|
+
"description": "Legacy display prefix derived from access_token"
|
|
2348
|
+
},
|
|
2349
|
+
"access_token": {
|
|
2350
|
+
"type": "string",
|
|
2351
|
+
"description": "OAuth access token for CLI API authentication"
|
|
2352
|
+
},
|
|
2353
|
+
"refresh_token": {
|
|
2354
|
+
"type": "string",
|
|
2355
|
+
"description": "OAuth refresh token used by the CLI to renew access"
|
|
2356
|
+
},
|
|
2357
|
+
"token_type": {
|
|
2358
|
+
"type": "string",
|
|
2359
|
+
"enum": ["Bearer"]
|
|
2360
|
+
},
|
|
2361
|
+
"expires_in": {
|
|
2362
|
+
"type": "integer",
|
|
2363
|
+
"description": "Seconds until access_token expires"
|
|
2364
|
+
},
|
|
2365
|
+
"auth_method": {
|
|
2366
|
+
"type": "string",
|
|
2367
|
+
"enum": ["oauth"]
|
|
2368
|
+
},
|
|
2369
|
+
"oauth_grant_id": {
|
|
2202
2370
|
"type": "string",
|
|
2203
2371
|
"format": "uuid"
|
|
2204
2372
|
},
|
|
2205
|
-
"
|
|
2373
|
+
"oauth_client_id": { "type": "string" },
|
|
2206
2374
|
"org_id": {
|
|
2207
2375
|
"type": "string",
|
|
2208
2376
|
"format": "uuid"
|
|
@@ -2213,6 +2381,13 @@ const openapiDocument = {
|
|
|
2213
2381
|
"api_key",
|
|
2214
2382
|
"key_id",
|
|
2215
2383
|
"key_prefix",
|
|
2384
|
+
"access_token",
|
|
2385
|
+
"refresh_token",
|
|
2386
|
+
"token_type",
|
|
2387
|
+
"expires_in",
|
|
2388
|
+
"auth_method",
|
|
2389
|
+
"oauth_grant_id",
|
|
2390
|
+
"oauth_client_id",
|
|
2216
2391
|
"org_id",
|
|
2217
2392
|
"org_name"
|
|
2218
2393
|
]
|
|
@@ -2240,7 +2415,7 @@ const openapiDocument = {
|
|
|
2240
2415
|
"type": "string",
|
|
2241
2416
|
"minLength": 1,
|
|
2242
2417
|
"maxLength": 80,
|
|
2243
|
-
"description": "Human-readable device name used for the created CLI
|
|
2418
|
+
"description": "Human-readable device name used for the created CLI OAuth grant"
|
|
2244
2419
|
},
|
|
2245
2420
|
"metadata": {
|
|
2246
2421
|
"type": "object",
|
|
@@ -2341,24 +2516,49 @@ const openapiDocument = {
|
|
|
2341
2516
|
"maxLength": 1024
|
|
2342
2517
|
}
|
|
2343
2518
|
},
|
|
2344
|
-
"required": [
|
|
2345
|
-
"signup_token",
|
|
2346
|
-
"verification_code",
|
|
2347
|
-
"password"
|
|
2348
|
-
]
|
|
2519
|
+
"required": ["signup_token", "verification_code"]
|
|
2349
2520
|
},
|
|
2350
2521
|
"CliSignupVerifyResult": {
|
|
2351
2522
|
"type": "object",
|
|
2352
2523
|
"properties": {
|
|
2353
2524
|
"api_key": {
|
|
2354
2525
|
"type": "string",
|
|
2355
|
-
"description": "
|
|
2526
|
+
"description": "Legacy alias for access_token. New CLI builds should persist access_token and refresh_token."
|
|
2356
2527
|
},
|
|
2357
2528
|
"key_id": {
|
|
2529
|
+
"type": "string",
|
|
2530
|
+
"format": "uuid",
|
|
2531
|
+
"description": "Legacy alias for oauth_grant_id"
|
|
2532
|
+
},
|
|
2533
|
+
"key_prefix": {
|
|
2534
|
+
"type": "string",
|
|
2535
|
+
"description": "Legacy display prefix derived from access_token"
|
|
2536
|
+
},
|
|
2537
|
+
"access_token": {
|
|
2538
|
+
"type": "string",
|
|
2539
|
+
"description": "OAuth access token for CLI API authentication"
|
|
2540
|
+
},
|
|
2541
|
+
"refresh_token": {
|
|
2542
|
+
"type": "string",
|
|
2543
|
+
"description": "OAuth refresh token used by the CLI to renew access"
|
|
2544
|
+
},
|
|
2545
|
+
"token_type": {
|
|
2546
|
+
"type": "string",
|
|
2547
|
+
"enum": ["Bearer"]
|
|
2548
|
+
},
|
|
2549
|
+
"expires_in": {
|
|
2550
|
+
"type": "integer",
|
|
2551
|
+
"description": "Seconds until access_token expires"
|
|
2552
|
+
},
|
|
2553
|
+
"auth_method": {
|
|
2554
|
+
"type": "string",
|
|
2555
|
+
"enum": ["oauth"]
|
|
2556
|
+
},
|
|
2557
|
+
"oauth_grant_id": {
|
|
2358
2558
|
"type": "string",
|
|
2359
2559
|
"format": "uuid"
|
|
2360
2560
|
},
|
|
2361
|
-
"
|
|
2561
|
+
"oauth_client_id": { "type": "string" },
|
|
2362
2562
|
"org_id": {
|
|
2363
2563
|
"type": "string",
|
|
2364
2564
|
"format": "uuid"
|
|
@@ -2369,107 +2569,325 @@ const openapiDocument = {
|
|
|
2369
2569
|
"api_key",
|
|
2370
2570
|
"key_id",
|
|
2371
2571
|
"key_prefix",
|
|
2572
|
+
"access_token",
|
|
2573
|
+
"refresh_token",
|
|
2574
|
+
"token_type",
|
|
2575
|
+
"expires_in",
|
|
2576
|
+
"auth_method",
|
|
2577
|
+
"oauth_grant_id",
|
|
2578
|
+
"oauth_client_id",
|
|
2372
2579
|
"org_id",
|
|
2373
2580
|
"org_name"
|
|
2374
2581
|
]
|
|
2375
2582
|
},
|
|
2376
|
-
"
|
|
2583
|
+
"StartAgentSignupInput": {
|
|
2377
2584
|
"type": "object",
|
|
2378
2585
|
"additionalProperties": false,
|
|
2379
|
-
"properties": { "key_id": {
|
|
2380
|
-
"type": "string",
|
|
2381
|
-
"format": "uuid",
|
|
2382
|
-
"description": "Optional key id guard; when provided it must match the authenticated API key"
|
|
2383
|
-
} }
|
|
2384
|
-
},
|
|
2385
|
-
"CliLogoutResult": {
|
|
2386
|
-
"type": "object",
|
|
2387
2586
|
"properties": {
|
|
2388
|
-
"
|
|
2587
|
+
"email": {
|
|
2588
|
+
"type": "string",
|
|
2589
|
+
"format": "email",
|
|
2590
|
+
"maxLength": 254
|
|
2591
|
+
},
|
|
2592
|
+
"signup_code": {
|
|
2593
|
+
"type": "string",
|
|
2594
|
+
"minLength": 1,
|
|
2595
|
+
"maxLength": 128
|
|
2596
|
+
},
|
|
2597
|
+
"terms_accepted": {
|
|
2389
2598
|
"type": "boolean",
|
|
2390
|
-
"const": true
|
|
2599
|
+
"const": true,
|
|
2600
|
+
"description": "Must be true to confirm acceptance of Primitive's Terms of Service and Privacy Policy"
|
|
2391
2601
|
},
|
|
2392
|
-
"
|
|
2602
|
+
"device_name": {
|
|
2393
2603
|
"type": "string",
|
|
2394
|
-
"
|
|
2604
|
+
"minLength": 1,
|
|
2605
|
+
"maxLength": 80,
|
|
2606
|
+
"description": "Human-readable device name used for the created agent OAuth session"
|
|
2607
|
+
},
|
|
2608
|
+
"metadata": {
|
|
2609
|
+
"type": "object",
|
|
2610
|
+
"additionalProperties": true,
|
|
2611
|
+
"description": "Optional client metadata stored with the signup session; serialized JSON must be 2048 bytes or fewer"
|
|
2395
2612
|
}
|
|
2396
2613
|
},
|
|
2397
|
-
"required": [
|
|
2614
|
+
"required": [
|
|
2615
|
+
"email",
|
|
2616
|
+
"signup_code",
|
|
2617
|
+
"terms_accepted"
|
|
2618
|
+
]
|
|
2398
2619
|
},
|
|
2399
|
-
"
|
|
2620
|
+
"AgentSignupStartResult": {
|
|
2400
2621
|
"type": "object",
|
|
2401
2622
|
"properties": {
|
|
2402
|
-
"
|
|
2623
|
+
"signup_token": {
|
|
2403
2624
|
"type": "string",
|
|
2404
|
-
"
|
|
2625
|
+
"description": "Opaque token used to verify or resend the pending agent signup"
|
|
2405
2626
|
},
|
|
2406
|
-
"email": {
|
|
2407
|
-
"plan": { "type": "string" },
|
|
2408
|
-
"created_at": {
|
|
2627
|
+
"email": {
|
|
2409
2628
|
"type": "string",
|
|
2410
|
-
"format": "
|
|
2629
|
+
"format": "email"
|
|
2411
2630
|
},
|
|
2412
|
-
"
|
|
2413
|
-
|
|
2414
|
-
|
|
2415
|
-
"subscription_current_period_end": {
|
|
2416
|
-
"type": ["string", "null"],
|
|
2417
|
-
"format": "date-time"
|
|
2631
|
+
"expires_in": {
|
|
2632
|
+
"type": "integer",
|
|
2633
|
+
"description": "Seconds until the pending signup expires"
|
|
2418
2634
|
},
|
|
2419
|
-
"
|
|
2420
|
-
|
|
2421
|
-
"
|
|
2422
|
-
"minimum": 0,
|
|
2423
|
-
"maximum": 15
|
|
2635
|
+
"resend_after": {
|
|
2636
|
+
"type": "integer",
|
|
2637
|
+
"description": "Minimum seconds before requesting another verification email"
|
|
2424
2638
|
},
|
|
2425
|
-
"
|
|
2426
|
-
|
|
2427
|
-
"
|
|
2428
|
-
"format": "date-time"
|
|
2639
|
+
"verification_code_length": {
|
|
2640
|
+
"type": "integer",
|
|
2641
|
+
"description": "Number of digits in the emailed verification code"
|
|
2429
2642
|
}
|
|
2430
2643
|
},
|
|
2431
2644
|
"required": [
|
|
2432
|
-
"
|
|
2645
|
+
"signup_token",
|
|
2433
2646
|
"email",
|
|
2434
|
-
"
|
|
2435
|
-
"
|
|
2436
|
-
"
|
|
2647
|
+
"expires_in",
|
|
2648
|
+
"resend_after",
|
|
2649
|
+
"verification_code_length"
|
|
2437
2650
|
]
|
|
2438
2651
|
},
|
|
2439
|
-
"
|
|
2652
|
+
"ResendAgentSignupVerificationInput": {
|
|
2653
|
+
"type": "object",
|
|
2654
|
+
"additionalProperties": false,
|
|
2655
|
+
"properties": { "signup_token": {
|
|
2656
|
+
"type": "string",
|
|
2657
|
+
"minLength": 1
|
|
2658
|
+
} },
|
|
2659
|
+
"required": ["signup_token"]
|
|
2660
|
+
},
|
|
2661
|
+
"AgentSignupResendResult": {
|
|
2440
2662
|
"type": "object",
|
|
2441
2663
|
"properties": {
|
|
2442
|
-
"
|
|
2664
|
+
"email": {
|
|
2443
2665
|
"type": "string",
|
|
2444
|
-
"format": "
|
|
2666
|
+
"format": "email"
|
|
2445
2667
|
},
|
|
2446
|
-
"
|
|
2447
|
-
|
|
2448
|
-
|
|
2449
|
-
"type": ["number", "null"],
|
|
2450
|
-
"minimum": 0,
|
|
2451
|
-
"maximum": 15
|
|
2668
|
+
"expires_in": {
|
|
2669
|
+
"type": "integer",
|
|
2670
|
+
"description": "Seconds until the pending signup expires"
|
|
2452
2671
|
},
|
|
2453
|
-
"
|
|
2672
|
+
"resend_after": {
|
|
2673
|
+
"type": "integer",
|
|
2674
|
+
"description": "Minimum seconds before requesting another verification email"
|
|
2675
|
+
},
|
|
2676
|
+
"verification_code_length": {
|
|
2677
|
+
"type": "integer",
|
|
2678
|
+
"description": "Number of digits in the emailed verification code"
|
|
2679
|
+
}
|
|
2454
2680
|
},
|
|
2455
2681
|
"required": [
|
|
2456
|
-
"id",
|
|
2457
2682
|
"email",
|
|
2458
|
-
"
|
|
2459
|
-
"
|
|
2683
|
+
"expires_in",
|
|
2684
|
+
"resend_after",
|
|
2685
|
+
"verification_code_length"
|
|
2460
2686
|
]
|
|
2461
2687
|
},
|
|
2462
|
-
"
|
|
2688
|
+
"VerifyAgentSignupInput": {
|
|
2463
2689
|
"type": "object",
|
|
2464
2690
|
"additionalProperties": false,
|
|
2465
2691
|
"properties": {
|
|
2466
|
-
"
|
|
2467
|
-
"type":
|
|
2468
|
-
"
|
|
2469
|
-
"maximum": 15,
|
|
2470
|
-
"description": "Global spam score threshold (0-15). Emails scoring above this are rejected. Set to null to disable."
|
|
2692
|
+
"signup_token": {
|
|
2693
|
+
"type": "string",
|
|
2694
|
+
"minLength": 1
|
|
2471
2695
|
},
|
|
2472
|
-
"
|
|
2696
|
+
"verification_code": {
|
|
2697
|
+
"type": "string",
|
|
2698
|
+
"minLength": 1,
|
|
2699
|
+
"maxLength": 32
|
|
2700
|
+
},
|
|
2701
|
+
"org_id": {
|
|
2702
|
+
"type": "string",
|
|
2703
|
+
"format": "uuid",
|
|
2704
|
+
"description": "Optional workspace id to target when the verified email already belongs to multiple workspaces"
|
|
2705
|
+
}
|
|
2706
|
+
},
|
|
2707
|
+
"required": ["signup_token", "verification_code"]
|
|
2708
|
+
},
|
|
2709
|
+
"AgentOrgRef": {
|
|
2710
|
+
"type": "object",
|
|
2711
|
+
"properties": {
|
|
2712
|
+
"id": {
|
|
2713
|
+
"type": "string",
|
|
2714
|
+
"format": "uuid"
|
|
2715
|
+
},
|
|
2716
|
+
"name": { "type": ["string", "null"] }
|
|
2717
|
+
},
|
|
2718
|
+
"required": ["id", "name"]
|
|
2719
|
+
},
|
|
2720
|
+
"AgentSignupVerifyResult": {
|
|
2721
|
+
"type": "object",
|
|
2722
|
+
"properties": {
|
|
2723
|
+
"api_key": {
|
|
2724
|
+
"type": "string",
|
|
2725
|
+
"description": "Legacy alias for access_token. New CLI builds should persist access_token and refresh_token."
|
|
2726
|
+
},
|
|
2727
|
+
"key_id": {
|
|
2728
|
+
"type": "string",
|
|
2729
|
+
"format": "uuid",
|
|
2730
|
+
"description": "Legacy alias for oauth_grant_id"
|
|
2731
|
+
},
|
|
2732
|
+
"key_prefix": {
|
|
2733
|
+
"type": "string",
|
|
2734
|
+
"description": "Legacy display prefix derived from access_token"
|
|
2735
|
+
},
|
|
2736
|
+
"access_token": {
|
|
2737
|
+
"type": "string",
|
|
2738
|
+
"description": "OAuth access token for CLI API authentication"
|
|
2739
|
+
},
|
|
2740
|
+
"refresh_token": {
|
|
2741
|
+
"type": "string",
|
|
2742
|
+
"description": "OAuth refresh token used by the CLI to renew access"
|
|
2743
|
+
},
|
|
2744
|
+
"token_type": {
|
|
2745
|
+
"type": "string",
|
|
2746
|
+
"enum": ["Bearer"]
|
|
2747
|
+
},
|
|
2748
|
+
"expires_in": {
|
|
2749
|
+
"type": "integer",
|
|
2750
|
+
"description": "Seconds until access_token expires"
|
|
2751
|
+
},
|
|
2752
|
+
"auth_method": {
|
|
2753
|
+
"type": "string",
|
|
2754
|
+
"enum": ["oauth"]
|
|
2755
|
+
},
|
|
2756
|
+
"oauth_grant_id": {
|
|
2757
|
+
"type": "string",
|
|
2758
|
+
"format": "uuid"
|
|
2759
|
+
},
|
|
2760
|
+
"oauth_client_id": { "type": "string" },
|
|
2761
|
+
"org_id": {
|
|
2762
|
+
"type": "string",
|
|
2763
|
+
"format": "uuid"
|
|
2764
|
+
},
|
|
2765
|
+
"org_name": { "type": ["string", "null"] },
|
|
2766
|
+
"orgs": {
|
|
2767
|
+
"type": "array",
|
|
2768
|
+
"items": { "$ref": "#/components/schemas/AgentOrgRef" },
|
|
2769
|
+
"description": "Workspaces available to the verified email. The minted session targets `org_id`."
|
|
2770
|
+
}
|
|
2771
|
+
},
|
|
2772
|
+
"required": [
|
|
2773
|
+
"api_key",
|
|
2774
|
+
"key_id",
|
|
2775
|
+
"key_prefix",
|
|
2776
|
+
"access_token",
|
|
2777
|
+
"refresh_token",
|
|
2778
|
+
"token_type",
|
|
2779
|
+
"expires_in",
|
|
2780
|
+
"auth_method",
|
|
2781
|
+
"oauth_grant_id",
|
|
2782
|
+
"oauth_client_id",
|
|
2783
|
+
"org_id",
|
|
2784
|
+
"org_name",
|
|
2785
|
+
"orgs"
|
|
2786
|
+
]
|
|
2787
|
+
},
|
|
2788
|
+
"CliLogoutInput": {
|
|
2789
|
+
"type": "object",
|
|
2790
|
+
"additionalProperties": false,
|
|
2791
|
+
"properties": { "key_id": {
|
|
2792
|
+
"type": "string",
|
|
2793
|
+
"format": "uuid",
|
|
2794
|
+
"description": "Optional id guard; when provided it must match the authenticated OAuth grant id or API key id"
|
|
2795
|
+
} }
|
|
2796
|
+
},
|
|
2797
|
+
"CliLogoutResult": {
|
|
2798
|
+
"type": "object",
|
|
2799
|
+
"properties": {
|
|
2800
|
+
"revoked": {
|
|
2801
|
+
"type": "boolean",
|
|
2802
|
+
"description": "True when an OAuth grant was revoked. False for API-key-authenticated legacy logout, which only clears local CLI state."
|
|
2803
|
+
},
|
|
2804
|
+
"key_id": {
|
|
2805
|
+
"type": "string",
|
|
2806
|
+
"format": "uuid",
|
|
2807
|
+
"description": "API key id for API-key-authenticated legacy logout"
|
|
2808
|
+
},
|
|
2809
|
+
"oauth_grant_id": {
|
|
2810
|
+
"type": "string",
|
|
2811
|
+
"format": "uuid",
|
|
2812
|
+
"description": "OAuth grant id revoked by OAuth-authenticated logout"
|
|
2813
|
+
}
|
|
2814
|
+
},
|
|
2815
|
+
"required": ["revoked"]
|
|
2816
|
+
},
|
|
2817
|
+
"Account": {
|
|
2818
|
+
"type": "object",
|
|
2819
|
+
"properties": {
|
|
2820
|
+
"id": {
|
|
2821
|
+
"type": "string",
|
|
2822
|
+
"format": "uuid"
|
|
2823
|
+
},
|
|
2824
|
+
"email": { "type": "string" },
|
|
2825
|
+
"plan": { "type": "string" },
|
|
2826
|
+
"created_at": {
|
|
2827
|
+
"type": "string",
|
|
2828
|
+
"format": "date-time"
|
|
2829
|
+
},
|
|
2830
|
+
"onboarding_completed": { "type": "boolean" },
|
|
2831
|
+
"onboarding_step": { "type": ["string", "null"] },
|
|
2832
|
+
"stripe_subscription_status": { "type": ["string", "null"] },
|
|
2833
|
+
"subscription_current_period_end": {
|
|
2834
|
+
"type": ["string", "null"],
|
|
2835
|
+
"format": "date-time"
|
|
2836
|
+
},
|
|
2837
|
+
"subscription_cancel_at_period_end": { "type": ["boolean", "null"] },
|
|
2838
|
+
"spam_threshold": {
|
|
2839
|
+
"type": ["number", "null"],
|
|
2840
|
+
"minimum": 0,
|
|
2841
|
+
"maximum": 15
|
|
2842
|
+
},
|
|
2843
|
+
"discard_content_on_webhook_confirmed": { "type": "boolean" },
|
|
2844
|
+
"webhook_secret_rotated_at": {
|
|
2845
|
+
"type": ["string", "null"],
|
|
2846
|
+
"format": "date-time"
|
|
2847
|
+
}
|
|
2848
|
+
},
|
|
2849
|
+
"required": [
|
|
2850
|
+
"id",
|
|
2851
|
+
"email",
|
|
2852
|
+
"plan",
|
|
2853
|
+
"created_at",
|
|
2854
|
+
"discard_content_on_webhook_confirmed"
|
|
2855
|
+
]
|
|
2856
|
+
},
|
|
2857
|
+
"AccountUpdated": {
|
|
2858
|
+
"type": "object",
|
|
2859
|
+
"properties": {
|
|
2860
|
+
"id": {
|
|
2861
|
+
"type": "string",
|
|
2862
|
+
"format": "uuid"
|
|
2863
|
+
},
|
|
2864
|
+
"email": { "type": "string" },
|
|
2865
|
+
"plan": { "type": "string" },
|
|
2866
|
+
"spam_threshold": {
|
|
2867
|
+
"type": ["number", "null"],
|
|
2868
|
+
"minimum": 0,
|
|
2869
|
+
"maximum": 15
|
|
2870
|
+
},
|
|
2871
|
+
"discard_content_on_webhook_confirmed": { "type": "boolean" }
|
|
2872
|
+
},
|
|
2873
|
+
"required": [
|
|
2874
|
+
"id",
|
|
2875
|
+
"email",
|
|
2876
|
+
"plan",
|
|
2877
|
+
"discard_content_on_webhook_confirmed"
|
|
2878
|
+
]
|
|
2879
|
+
},
|
|
2880
|
+
"UpdateAccountInput": {
|
|
2881
|
+
"type": "object",
|
|
2882
|
+
"additionalProperties": false,
|
|
2883
|
+
"properties": {
|
|
2884
|
+
"spam_threshold": {
|
|
2885
|
+
"type": ["number", "null"],
|
|
2886
|
+
"minimum": 0,
|
|
2887
|
+
"maximum": 15,
|
|
2888
|
+
"description": "Global spam score threshold (0-15). Emails scoring above this are rejected. Set to null to disable."
|
|
2889
|
+
},
|
|
2890
|
+
"discard_content_on_webhook_confirmed": {
|
|
2473
2891
|
"type": "boolean",
|
|
2474
2892
|
"description": "Whether to discard email content after the webhook endpoint confirms receipt."
|
|
2475
2893
|
}
|
|
@@ -2522,7 +2940,7 @@ const openapiDocument = {
|
|
|
2522
2940
|
"required": ["secret"]
|
|
2523
2941
|
},
|
|
2524
2942
|
"Domain": {
|
|
2525
|
-
"description": "A domain can be either verified or unverified. Verified domains have\n`is_active` and `spam_threshold` fields. Unverified domains have a\n`verification_token` for DNS
|
|
2943
|
+
"description": "A domain can be either verified or unverified. Verified domains have\n`is_active` and `spam_threshold` fields. Unverified domains have a\n`verification_token` and `dns_records` for DNS setup.\n",
|
|
2526
2944
|
"oneOf": [{ "$ref": "#/components/schemas/VerifiedDomain" }, { "$ref": "#/components/schemas/UnverifiedDomain" }]
|
|
2527
2945
|
},
|
|
2528
2946
|
"VerifiedDomain": {
|
|
@@ -2562,6 +2980,74 @@ const openapiDocument = {
|
|
|
2562
2980
|
"created_at"
|
|
2563
2981
|
]
|
|
2564
2982
|
},
|
|
2983
|
+
"DomainDnsRecord": {
|
|
2984
|
+
"type": "object",
|
|
2985
|
+
"additionalProperties": false,
|
|
2986
|
+
"properties": {
|
|
2987
|
+
"type": {
|
|
2988
|
+
"type": "string",
|
|
2989
|
+
"enum": ["MX", "TXT"],
|
|
2990
|
+
"description": "DNS record type."
|
|
2991
|
+
},
|
|
2992
|
+
"name": {
|
|
2993
|
+
"type": "string",
|
|
2994
|
+
"description": "DNS-provider host/name value relative to the managed root zone."
|
|
2995
|
+
},
|
|
2996
|
+
"fqdn": {
|
|
2997
|
+
"type": "string",
|
|
2998
|
+
"description": "Fully-qualified DNS record name."
|
|
2999
|
+
},
|
|
3000
|
+
"value": {
|
|
3001
|
+
"type": "string",
|
|
3002
|
+
"description": "Exact value to publish."
|
|
3003
|
+
},
|
|
3004
|
+
"priority": {
|
|
3005
|
+
"type": "integer",
|
|
3006
|
+
"description": "MX priority. Present only for MX records."
|
|
3007
|
+
},
|
|
3008
|
+
"ttl": {
|
|
3009
|
+
"type": "integer",
|
|
3010
|
+
"description": "Suggested TTL in seconds when the API can provide one."
|
|
3011
|
+
},
|
|
3012
|
+
"required": {
|
|
3013
|
+
"type": "boolean",
|
|
3014
|
+
"const": true
|
|
3015
|
+
},
|
|
3016
|
+
"purpose": {
|
|
3017
|
+
"type": "string",
|
|
3018
|
+
"enum": [
|
|
3019
|
+
"inbound_mx",
|
|
3020
|
+
"ownership_verification",
|
|
3021
|
+
"spf",
|
|
3022
|
+
"dkim",
|
|
3023
|
+
"dmarc",
|
|
3024
|
+
"tls_reporting"
|
|
3025
|
+
]
|
|
3026
|
+
},
|
|
3027
|
+
"status": {
|
|
3028
|
+
"type": "string",
|
|
3029
|
+
"enum": [
|
|
3030
|
+
"pending",
|
|
3031
|
+
"found",
|
|
3032
|
+
"missing",
|
|
3033
|
+
"incorrect"
|
|
3034
|
+
]
|
|
3035
|
+
},
|
|
3036
|
+
"message": {
|
|
3037
|
+
"type": "string",
|
|
3038
|
+
"description": "Short explanation of why this record is needed."
|
|
3039
|
+
}
|
|
3040
|
+
},
|
|
3041
|
+
"required": [
|
|
3042
|
+
"type",
|
|
3043
|
+
"name",
|
|
3044
|
+
"fqdn",
|
|
3045
|
+
"value",
|
|
3046
|
+
"required",
|
|
3047
|
+
"purpose",
|
|
3048
|
+
"status"
|
|
3049
|
+
]
|
|
3050
|
+
},
|
|
2565
3051
|
"UnverifiedDomain": {
|
|
2566
3052
|
"type": "object",
|
|
2567
3053
|
"properties": {
|
|
@@ -2582,6 +3068,11 @@ const openapiDocument = {
|
|
|
2582
3068
|
"type": "string",
|
|
2583
3069
|
"description": "Add this value as a TXT record to verify ownership"
|
|
2584
3070
|
},
|
|
3071
|
+
"dns_records": {
|
|
3072
|
+
"type": "array",
|
|
3073
|
+
"description": "Exact DNS records to publish for this pending domain claim.",
|
|
3074
|
+
"items": { "$ref": "#/components/schemas/DomainDnsRecord" }
|
|
3075
|
+
},
|
|
2585
3076
|
"created_at": {
|
|
2586
3077
|
"type": "string",
|
|
2587
3078
|
"format": "date-time"
|
|
@@ -2599,12 +3090,23 @@ const openapiDocument = {
|
|
|
2599
3090
|
"AddDomainInput": {
|
|
2600
3091
|
"type": "object",
|
|
2601
3092
|
"additionalProperties": false,
|
|
2602
|
-
"properties": {
|
|
2603
|
-
"
|
|
2604
|
-
|
|
2605
|
-
|
|
2606
|
-
|
|
2607
|
-
|
|
3093
|
+
"properties": {
|
|
3094
|
+
"domain": {
|
|
3095
|
+
"type": "string",
|
|
3096
|
+
"minLength": 1,
|
|
3097
|
+
"maxLength": 253,
|
|
3098
|
+
"description": "The domain name to claim (e.g. \"example.com\")"
|
|
3099
|
+
},
|
|
3100
|
+
"confirmed": {
|
|
3101
|
+
"type": "boolean",
|
|
3102
|
+
"description": "Set to true to confirm replacing an existing mailbox provider after an mx_conflict response."
|
|
3103
|
+
},
|
|
3104
|
+
"outbound": {
|
|
3105
|
+
"type": "boolean",
|
|
3106
|
+
"deprecated": true,
|
|
3107
|
+
"description": "Deprecated and ignored. Outbound DNS is provisioned for every new domain claim."
|
|
3108
|
+
}
|
|
3109
|
+
},
|
|
2608
3110
|
"required": ["domain"]
|
|
2609
3111
|
},
|
|
2610
3112
|
"UpdateDomainInput": {
|
|
@@ -2626,10 +3128,17 @@ const openapiDocument = {
|
|
|
2626
3128
|
},
|
|
2627
3129
|
"DomainVerifyResult": { "oneOf": [{
|
|
2628
3130
|
"type": "object",
|
|
2629
|
-
"properties": {
|
|
2630
|
-
"
|
|
2631
|
-
|
|
2632
|
-
|
|
3131
|
+
"properties": {
|
|
3132
|
+
"verified": {
|
|
3133
|
+
"type": "boolean",
|
|
3134
|
+
"const": true
|
|
3135
|
+
},
|
|
3136
|
+
"dns_records": {
|
|
3137
|
+
"type": "array",
|
|
3138
|
+
"description": "Exact DNS records checked for this verification attempt.",
|
|
3139
|
+
"items": { "$ref": "#/components/schemas/DomainDnsRecord" }
|
|
3140
|
+
}
|
|
3141
|
+
},
|
|
2633
3142
|
"required": ["verified"]
|
|
2634
3143
|
}, {
|
|
2635
3144
|
"type": "object",
|
|
@@ -2646,6 +3155,27 @@ const openapiDocument = {
|
|
|
2646
3155
|
"type": "boolean",
|
|
2647
3156
|
"description": "Whether the TXT verification record was found"
|
|
2648
3157
|
},
|
|
3158
|
+
"spfFound": {
|
|
3159
|
+
"type": "boolean",
|
|
3160
|
+
"description": "Whether the SPF record includes Primitive."
|
|
3161
|
+
},
|
|
3162
|
+
"dkimFound": {
|
|
3163
|
+
"type": "boolean",
|
|
3164
|
+
"description": "Whether the DKIM public key record was found."
|
|
3165
|
+
},
|
|
3166
|
+
"dmarcFound": {
|
|
3167
|
+
"type": "boolean",
|
|
3168
|
+
"description": "Whether the DMARC record was found."
|
|
3169
|
+
},
|
|
3170
|
+
"tlsRptFound": {
|
|
3171
|
+
"type": "boolean",
|
|
3172
|
+
"description": "Whether the TLS-RPT record was found."
|
|
3173
|
+
},
|
|
3174
|
+
"dns_records": {
|
|
3175
|
+
"type": "array",
|
|
3176
|
+
"description": "Exact DNS records checked for this verification attempt.",
|
|
3177
|
+
"items": { "$ref": "#/components/schemas/DomainDnsRecord" }
|
|
3178
|
+
},
|
|
2649
3179
|
"error": {
|
|
2650
3180
|
"type": "string",
|
|
2651
3181
|
"description": "Human-readable verification failure reason"
|
|
@@ -2958,6 +3488,31 @@ const openapiDocument = {
|
|
|
2958
3488
|
"created_at"
|
|
2959
3489
|
]
|
|
2960
3490
|
},
|
|
3491
|
+
"SendMailAttachment": {
|
|
3492
|
+
"type": "object",
|
|
3493
|
+
"additionalProperties": false,
|
|
3494
|
+
"properties": {
|
|
3495
|
+
"filename": {
|
|
3496
|
+
"type": "string",
|
|
3497
|
+
"minLength": 1,
|
|
3498
|
+
"maxLength": 255,
|
|
3499
|
+
"description": "Attachment filename. Control characters are rejected."
|
|
3500
|
+
},
|
|
3501
|
+
"content_type": {
|
|
3502
|
+
"type": "string",
|
|
3503
|
+
"minLength": 1,
|
|
3504
|
+
"maxLength": 255,
|
|
3505
|
+
"description": "Optional MIME content type. Control characters are rejected."
|
|
3506
|
+
},
|
|
3507
|
+
"content_base64": {
|
|
3508
|
+
"type": "string",
|
|
3509
|
+
"minLength": 1,
|
|
3510
|
+
"maxLength": 44040192,
|
|
3511
|
+
"description": "Base64-encoded attachment bytes."
|
|
3512
|
+
}
|
|
3513
|
+
},
|
|
3514
|
+
"required": ["filename", "content_base64"]
|
|
3515
|
+
},
|
|
2961
3516
|
"SendMailInput": {
|
|
2962
3517
|
"type": "object",
|
|
2963
3518
|
"additionalProperties": false,
|
|
@@ -3006,6 +3561,12 @@ const openapiDocument = {
|
|
|
3006
3561
|
"pattern": "^[^\\x00-\\x1F\\x7F]+$"
|
|
3007
3562
|
}
|
|
3008
3563
|
},
|
|
3564
|
+
"attachments": {
|
|
3565
|
+
"type": "array",
|
|
3566
|
+
"maxItems": 100,
|
|
3567
|
+
"description": "Inline attachments. Send requests with attachments to https://api.primitive.dev/v1/send-mail. Combined raw decoded attachment bytes must be at most 31457280.",
|
|
3568
|
+
"items": { "$ref": "#/components/schemas/SendMailAttachment" }
|
|
3569
|
+
},
|
|
3009
3570
|
"wait": {
|
|
3010
3571
|
"type": "boolean",
|
|
3011
3572
|
"description": "When true, wait for the first downstream SMTP delivery outcome before returning."
|
|
@@ -4593,16 +5154,268 @@ const operationManifest = [
|
|
|
4593
5154
|
"discard_content_on_webhook_confirmed"
|
|
4594
5155
|
]
|
|
4595
5156
|
},
|
|
4596
|
-
"sdkName": "updateAccount",
|
|
4597
|
-
"summary": "Update account settings",
|
|
4598
|
-
"tag": "Account",
|
|
4599
|
-
"tagCommand": "account"
|
|
5157
|
+
"sdkName": "updateAccount",
|
|
5158
|
+
"summary": "Update account settings",
|
|
5159
|
+
"tag": "Account",
|
|
5160
|
+
"tagCommand": "account"
|
|
5161
|
+
},
|
|
5162
|
+
{
|
|
5163
|
+
"binaryResponse": false,
|
|
5164
|
+
"bodyRequired": true,
|
|
5165
|
+
"command": "resend-agent-signup-verification",
|
|
5166
|
+
"description": "Sends a new email verification code for a pending agent signup session.\nThis endpoint does not require an API key.\n",
|
|
5167
|
+
"hasJsonBody": true,
|
|
5168
|
+
"method": "POST",
|
|
5169
|
+
"operationId": "resendAgentSignupVerification",
|
|
5170
|
+
"path": "/agent/signup/resend",
|
|
5171
|
+
"pathParams": [],
|
|
5172
|
+
"queryParams": [],
|
|
5173
|
+
"requestSchema": {
|
|
5174
|
+
"type": "object",
|
|
5175
|
+
"additionalProperties": false,
|
|
5176
|
+
"properties": { "signup_token": {
|
|
5177
|
+
"type": "string",
|
|
5178
|
+
"minLength": 1
|
|
5179
|
+
} },
|
|
5180
|
+
"required": ["signup_token"]
|
|
5181
|
+
},
|
|
5182
|
+
"responseSchema": {
|
|
5183
|
+
"type": "object",
|
|
5184
|
+
"properties": {
|
|
5185
|
+
"email": {
|
|
5186
|
+
"type": "string",
|
|
5187
|
+
"format": "email"
|
|
5188
|
+
},
|
|
5189
|
+
"expires_in": {
|
|
5190
|
+
"type": "integer",
|
|
5191
|
+
"description": "Seconds until the pending signup expires"
|
|
5192
|
+
},
|
|
5193
|
+
"resend_after": {
|
|
5194
|
+
"type": "integer",
|
|
5195
|
+
"description": "Minimum seconds before requesting another verification email"
|
|
5196
|
+
},
|
|
5197
|
+
"verification_code_length": {
|
|
5198
|
+
"type": "integer",
|
|
5199
|
+
"description": "Number of digits in the emailed verification code"
|
|
5200
|
+
}
|
|
5201
|
+
},
|
|
5202
|
+
"required": [
|
|
5203
|
+
"email",
|
|
5204
|
+
"expires_in",
|
|
5205
|
+
"resend_after",
|
|
5206
|
+
"verification_code_length"
|
|
5207
|
+
]
|
|
5208
|
+
},
|
|
5209
|
+
"sdkName": "resendAgentSignupVerification",
|
|
5210
|
+
"summary": "Resend agent signup verification code",
|
|
5211
|
+
"tag": "Agent",
|
|
5212
|
+
"tagCommand": "agent"
|
|
5213
|
+
},
|
|
5214
|
+
{
|
|
5215
|
+
"binaryResponse": false,
|
|
5216
|
+
"bodyRequired": true,
|
|
5217
|
+
"command": "start-agent-signup",
|
|
5218
|
+
"description": "Starts an agent-native signup session. The API validates the signup code,\ncreates a pending signup session, sends an email verification code, and\nreturns an opaque signup token used by the resend and verify steps. This\nendpoint does not require an API key.\n",
|
|
5219
|
+
"hasJsonBody": true,
|
|
5220
|
+
"method": "POST",
|
|
5221
|
+
"operationId": "startAgentSignup",
|
|
5222
|
+
"path": "/agent/signup/start",
|
|
5223
|
+
"pathParams": [],
|
|
5224
|
+
"queryParams": [],
|
|
5225
|
+
"requestSchema": {
|
|
5226
|
+
"type": "object",
|
|
5227
|
+
"additionalProperties": false,
|
|
5228
|
+
"properties": {
|
|
5229
|
+
"email": {
|
|
5230
|
+
"type": "string",
|
|
5231
|
+
"format": "email",
|
|
5232
|
+
"maxLength": 254
|
|
5233
|
+
},
|
|
5234
|
+
"signup_code": {
|
|
5235
|
+
"type": "string",
|
|
5236
|
+
"minLength": 1,
|
|
5237
|
+
"maxLength": 128
|
|
5238
|
+
},
|
|
5239
|
+
"terms_accepted": {
|
|
5240
|
+
"type": "boolean",
|
|
5241
|
+
"const": true,
|
|
5242
|
+
"description": "Must be true to confirm acceptance of Primitive's Terms of Service and Privacy Policy"
|
|
5243
|
+
},
|
|
5244
|
+
"device_name": {
|
|
5245
|
+
"type": "string",
|
|
5246
|
+
"minLength": 1,
|
|
5247
|
+
"maxLength": 80,
|
|
5248
|
+
"description": "Human-readable device name used for the created agent OAuth session"
|
|
5249
|
+
},
|
|
5250
|
+
"metadata": {
|
|
5251
|
+
"type": "object",
|
|
5252
|
+
"additionalProperties": true,
|
|
5253
|
+
"description": "Optional client metadata stored with the signup session; serialized JSON must be 2048 bytes or fewer"
|
|
5254
|
+
}
|
|
5255
|
+
},
|
|
5256
|
+
"required": [
|
|
5257
|
+
"email",
|
|
5258
|
+
"signup_code",
|
|
5259
|
+
"terms_accepted"
|
|
5260
|
+
]
|
|
5261
|
+
},
|
|
5262
|
+
"responseSchema": {
|
|
5263
|
+
"type": "object",
|
|
5264
|
+
"properties": {
|
|
5265
|
+
"signup_token": {
|
|
5266
|
+
"type": "string",
|
|
5267
|
+
"description": "Opaque token used to verify or resend the pending agent signup"
|
|
5268
|
+
},
|
|
5269
|
+
"email": {
|
|
5270
|
+
"type": "string",
|
|
5271
|
+
"format": "email"
|
|
5272
|
+
},
|
|
5273
|
+
"expires_in": {
|
|
5274
|
+
"type": "integer",
|
|
5275
|
+
"description": "Seconds until the pending signup expires"
|
|
5276
|
+
},
|
|
5277
|
+
"resend_after": {
|
|
5278
|
+
"type": "integer",
|
|
5279
|
+
"description": "Minimum seconds before requesting another verification email"
|
|
5280
|
+
},
|
|
5281
|
+
"verification_code_length": {
|
|
5282
|
+
"type": "integer",
|
|
5283
|
+
"description": "Number of digits in the emailed verification code"
|
|
5284
|
+
}
|
|
5285
|
+
},
|
|
5286
|
+
"required": [
|
|
5287
|
+
"signup_token",
|
|
5288
|
+
"email",
|
|
5289
|
+
"expires_in",
|
|
5290
|
+
"resend_after",
|
|
5291
|
+
"verification_code_length"
|
|
5292
|
+
]
|
|
5293
|
+
},
|
|
5294
|
+
"sdkName": "startAgentSignup",
|
|
5295
|
+
"summary": "Start agent account signup",
|
|
5296
|
+
"tag": "Agent",
|
|
5297
|
+
"tagCommand": "agent"
|
|
5298
|
+
},
|
|
5299
|
+
{
|
|
5300
|
+
"binaryResponse": false,
|
|
5301
|
+
"bodyRequired": true,
|
|
5302
|
+
"command": "verify-agent-signup",
|
|
5303
|
+
"description": "Verifies the email code for an agent signup session, creates the account\nwhen needed, redeems the reserved signup code, mints an org-scoped OAuth\nsession for CLI authentication, and returns the raw tokens exactly once.\nFor existing users, the optional `org_id` selects which accessible\nworkspace should receive the new session.\n",
|
|
5304
|
+
"hasJsonBody": true,
|
|
5305
|
+
"method": "POST",
|
|
5306
|
+
"operationId": "verifyAgentSignup",
|
|
5307
|
+
"path": "/agent/signup/verify",
|
|
5308
|
+
"pathParams": [],
|
|
5309
|
+
"queryParams": [],
|
|
5310
|
+
"requestSchema": {
|
|
5311
|
+
"type": "object",
|
|
5312
|
+
"additionalProperties": false,
|
|
5313
|
+
"properties": {
|
|
5314
|
+
"signup_token": {
|
|
5315
|
+
"type": "string",
|
|
5316
|
+
"minLength": 1
|
|
5317
|
+
},
|
|
5318
|
+
"verification_code": {
|
|
5319
|
+
"type": "string",
|
|
5320
|
+
"minLength": 1,
|
|
5321
|
+
"maxLength": 32
|
|
5322
|
+
},
|
|
5323
|
+
"org_id": {
|
|
5324
|
+
"type": "string",
|
|
5325
|
+
"format": "uuid",
|
|
5326
|
+
"description": "Optional workspace id to target when the verified email already belongs to multiple workspaces"
|
|
5327
|
+
}
|
|
5328
|
+
},
|
|
5329
|
+
"required": ["signup_token", "verification_code"]
|
|
5330
|
+
},
|
|
5331
|
+
"responseSchema": {
|
|
5332
|
+
"type": "object",
|
|
5333
|
+
"properties": {
|
|
5334
|
+
"api_key": {
|
|
5335
|
+
"type": "string",
|
|
5336
|
+
"description": "Legacy alias for access_token. New CLI builds should persist access_token and refresh_token."
|
|
5337
|
+
},
|
|
5338
|
+
"key_id": {
|
|
5339
|
+
"type": "string",
|
|
5340
|
+
"format": "uuid",
|
|
5341
|
+
"description": "Legacy alias for oauth_grant_id"
|
|
5342
|
+
},
|
|
5343
|
+
"key_prefix": {
|
|
5344
|
+
"type": "string",
|
|
5345
|
+
"description": "Legacy display prefix derived from access_token"
|
|
5346
|
+
},
|
|
5347
|
+
"access_token": {
|
|
5348
|
+
"type": "string",
|
|
5349
|
+
"description": "OAuth access token for CLI API authentication"
|
|
5350
|
+
},
|
|
5351
|
+
"refresh_token": {
|
|
5352
|
+
"type": "string",
|
|
5353
|
+
"description": "OAuth refresh token used by the CLI to renew access"
|
|
5354
|
+
},
|
|
5355
|
+
"token_type": {
|
|
5356
|
+
"type": "string",
|
|
5357
|
+
"enum": ["Bearer"]
|
|
5358
|
+
},
|
|
5359
|
+
"expires_in": {
|
|
5360
|
+
"type": "integer",
|
|
5361
|
+
"description": "Seconds until access_token expires"
|
|
5362
|
+
},
|
|
5363
|
+
"auth_method": {
|
|
5364
|
+
"type": "string",
|
|
5365
|
+
"enum": ["oauth"]
|
|
5366
|
+
},
|
|
5367
|
+
"oauth_grant_id": {
|
|
5368
|
+
"type": "string",
|
|
5369
|
+
"format": "uuid"
|
|
5370
|
+
},
|
|
5371
|
+
"oauth_client_id": { "type": "string" },
|
|
5372
|
+
"org_id": {
|
|
5373
|
+
"type": "string",
|
|
5374
|
+
"format": "uuid"
|
|
5375
|
+
},
|
|
5376
|
+
"org_name": { "type": ["string", "null"] },
|
|
5377
|
+
"orgs": {
|
|
5378
|
+
"type": "array",
|
|
5379
|
+
"items": {
|
|
5380
|
+
"type": "object",
|
|
5381
|
+
"properties": {
|
|
5382
|
+
"id": {
|
|
5383
|
+
"type": "string",
|
|
5384
|
+
"format": "uuid"
|
|
5385
|
+
},
|
|
5386
|
+
"name": { "type": ["string", "null"] }
|
|
5387
|
+
},
|
|
5388
|
+
"required": ["id", "name"]
|
|
5389
|
+
},
|
|
5390
|
+
"description": "Workspaces available to the verified email. The minted session targets `org_id`."
|
|
5391
|
+
}
|
|
5392
|
+
},
|
|
5393
|
+
"required": [
|
|
5394
|
+
"api_key",
|
|
5395
|
+
"key_id",
|
|
5396
|
+
"key_prefix",
|
|
5397
|
+
"access_token",
|
|
5398
|
+
"refresh_token",
|
|
5399
|
+
"token_type",
|
|
5400
|
+
"expires_in",
|
|
5401
|
+
"auth_method",
|
|
5402
|
+
"oauth_grant_id",
|
|
5403
|
+
"oauth_client_id",
|
|
5404
|
+
"org_id",
|
|
5405
|
+
"org_name",
|
|
5406
|
+
"orgs"
|
|
5407
|
+
]
|
|
5408
|
+
},
|
|
5409
|
+
"sdkName": "verifyAgentSignup",
|
|
5410
|
+
"summary": "Verify agent signup and create OAuth tokens",
|
|
5411
|
+
"tag": "Agent",
|
|
5412
|
+
"tagCommand": "agent"
|
|
4600
5413
|
},
|
|
4601
5414
|
{
|
|
4602
5415
|
"binaryResponse": false,
|
|
4603
5416
|
"bodyRequired": false,
|
|
4604
5417
|
"command": "cli-logout",
|
|
4605
|
-
"description": "Revokes the
|
|
5418
|
+
"description": "Revokes the OAuth grant used to authenticate the request. API-key\nauthenticated legacy logout requests succeed without deleting server API\nkeys so old local CLI state can be cleared safely.\n",
|
|
4606
5419
|
"hasJsonBody": true,
|
|
4607
5420
|
"method": "POST",
|
|
4608
5421
|
"operationId": "cliLogout",
|
|
@@ -4615,7 +5428,7 @@ const operationManifest = [
|
|
|
4615
5428
|
"properties": { "key_id": {
|
|
4616
5429
|
"type": "string",
|
|
4617
5430
|
"format": "uuid",
|
|
4618
|
-
"description": "Optional
|
|
5431
|
+
"description": "Optional id guard; when provided it must match the authenticated OAuth grant id or API key id"
|
|
4619
5432
|
} }
|
|
4620
5433
|
},
|
|
4621
5434
|
"responseSchema": {
|
|
@@ -4623,17 +5436,23 @@ const operationManifest = [
|
|
|
4623
5436
|
"properties": {
|
|
4624
5437
|
"revoked": {
|
|
4625
5438
|
"type": "boolean",
|
|
4626
|
-
"
|
|
5439
|
+
"description": "True when an OAuth grant was revoked. False for API-key-authenticated legacy logout, which only clears local CLI state."
|
|
4627
5440
|
},
|
|
4628
5441
|
"key_id": {
|
|
4629
5442
|
"type": "string",
|
|
4630
|
-
"format": "uuid"
|
|
5443
|
+
"format": "uuid",
|
|
5444
|
+
"description": "API key id for API-key-authenticated legacy logout"
|
|
5445
|
+
},
|
|
5446
|
+
"oauth_grant_id": {
|
|
5447
|
+
"type": "string",
|
|
5448
|
+
"format": "uuid",
|
|
5449
|
+
"description": "OAuth grant id revoked by OAuth-authenticated logout"
|
|
4631
5450
|
}
|
|
4632
5451
|
},
|
|
4633
|
-
"required": ["revoked"
|
|
5452
|
+
"required": ["revoked"]
|
|
4634
5453
|
},
|
|
4635
5454
|
"sdkName": "cliLogout",
|
|
4636
|
-
"summary": "Revoke the current CLI
|
|
5455
|
+
"summary": "Revoke the current CLI OAuth session",
|
|
4637
5456
|
"tag": "CLI",
|
|
4638
5457
|
"tagCommand": "cli"
|
|
4639
5458
|
},
|
|
@@ -4641,7 +5460,7 @@ const operationManifest = [
|
|
|
4641
5460
|
"binaryResponse": false,
|
|
4642
5461
|
"bodyRequired": true,
|
|
4643
5462
|
"command": "poll-cli-login",
|
|
4644
|
-
"description": "Polls a CLI login session until the browser approval either succeeds,\nis denied, expires, or is polled too quickly. The
|
|
5463
|
+
"description": "Polls a CLI login session until the browser approval either succeeds,\nis denied, expires, or is polled too quickly. The OAuth token set is\ncreated only after approval and is returned exactly once.\n",
|
|
4645
5464
|
"hasJsonBody": true,
|
|
4646
5465
|
"method": "POST",
|
|
4647
5466
|
"operationId": "pollCliLogin",
|
|
@@ -4662,13 +5481,42 @@ const operationManifest = [
|
|
|
4662
5481
|
"properties": {
|
|
4663
5482
|
"api_key": {
|
|
4664
5483
|
"type": "string",
|
|
4665
|
-
"description": "
|
|
5484
|
+
"description": "Legacy alias for access_token. New CLI builds should persist access_token and refresh_token."
|
|
4666
5485
|
},
|
|
4667
5486
|
"key_id": {
|
|
5487
|
+
"type": "string",
|
|
5488
|
+
"format": "uuid",
|
|
5489
|
+
"description": "Legacy alias for oauth_grant_id"
|
|
5490
|
+
},
|
|
5491
|
+
"key_prefix": {
|
|
5492
|
+
"type": "string",
|
|
5493
|
+
"description": "Legacy display prefix derived from access_token"
|
|
5494
|
+
},
|
|
5495
|
+
"access_token": {
|
|
5496
|
+
"type": "string",
|
|
5497
|
+
"description": "OAuth access token for CLI API authentication"
|
|
5498
|
+
},
|
|
5499
|
+
"refresh_token": {
|
|
5500
|
+
"type": "string",
|
|
5501
|
+
"description": "OAuth refresh token used by the CLI to renew access"
|
|
5502
|
+
},
|
|
5503
|
+
"token_type": {
|
|
5504
|
+
"type": "string",
|
|
5505
|
+
"enum": ["Bearer"]
|
|
5506
|
+
},
|
|
5507
|
+
"expires_in": {
|
|
5508
|
+
"type": "integer",
|
|
5509
|
+
"description": "Seconds until access_token expires"
|
|
5510
|
+
},
|
|
5511
|
+
"auth_method": {
|
|
5512
|
+
"type": "string",
|
|
5513
|
+
"enum": ["oauth"]
|
|
5514
|
+
},
|
|
5515
|
+
"oauth_grant_id": {
|
|
4668
5516
|
"type": "string",
|
|
4669
5517
|
"format": "uuid"
|
|
4670
5518
|
},
|
|
4671
|
-
"
|
|
5519
|
+
"oauth_client_id": { "type": "string" },
|
|
4672
5520
|
"org_id": {
|
|
4673
5521
|
"type": "string",
|
|
4674
5522
|
"format": "uuid"
|
|
@@ -4679,6 +5527,13 @@ const operationManifest = [
|
|
|
4679
5527
|
"api_key",
|
|
4680
5528
|
"key_id",
|
|
4681
5529
|
"key_prefix",
|
|
5530
|
+
"access_token",
|
|
5531
|
+
"refresh_token",
|
|
5532
|
+
"token_type",
|
|
5533
|
+
"expires_in",
|
|
5534
|
+
"auth_method",
|
|
5535
|
+
"oauth_grant_id",
|
|
5536
|
+
"oauth_client_id",
|
|
4682
5537
|
"org_id",
|
|
4683
5538
|
"org_name"
|
|
4684
5539
|
]
|
|
@@ -4845,7 +5700,7 @@ const operationManifest = [
|
|
|
4845
5700
|
"type": "string",
|
|
4846
5701
|
"minLength": 1,
|
|
4847
5702
|
"maxLength": 80,
|
|
4848
|
-
"description": "Human-readable device name used for the created CLI
|
|
5703
|
+
"description": "Human-readable device name used for the created CLI OAuth grant"
|
|
4849
5704
|
},
|
|
4850
5705
|
"metadata": {
|
|
4851
5706
|
"type": "object",
|
|
@@ -4900,7 +5755,7 @@ const operationManifest = [
|
|
|
4900
5755
|
"binaryResponse": false,
|
|
4901
5756
|
"bodyRequired": true,
|
|
4902
5757
|
"command": "verify-cli-signup",
|
|
4903
|
-
"description": "Verifies the email code for a CLI signup session, creates the account,\nredeems the reserved signup code,
|
|
5758
|
+
"description": "Verifies the email code for a CLI signup session, creates the account,\nredeems the reserved signup code, creates an org-scoped OAuth CLI\nsession, and returns the token set exactly once. This endpoint does not\nrequire an API key.\n",
|
|
4904
5759
|
"hasJsonBody": true,
|
|
4905
5760
|
"method": "POST",
|
|
4906
5761
|
"operationId": "verifyCliSignup",
|
|
@@ -4926,24 +5781,49 @@ const operationManifest = [
|
|
|
4926
5781
|
"maxLength": 1024
|
|
4927
5782
|
}
|
|
4928
5783
|
},
|
|
4929
|
-
"required": [
|
|
4930
|
-
"signup_token",
|
|
4931
|
-
"verification_code",
|
|
4932
|
-
"password"
|
|
4933
|
-
]
|
|
5784
|
+
"required": ["signup_token", "verification_code"]
|
|
4934
5785
|
},
|
|
4935
5786
|
"responseSchema": {
|
|
4936
5787
|
"type": "object",
|
|
4937
5788
|
"properties": {
|
|
4938
5789
|
"api_key": {
|
|
4939
5790
|
"type": "string",
|
|
4940
|
-
"description": "
|
|
5791
|
+
"description": "Legacy alias for access_token. New CLI builds should persist access_token and refresh_token."
|
|
4941
5792
|
},
|
|
4942
5793
|
"key_id": {
|
|
5794
|
+
"type": "string",
|
|
5795
|
+
"format": "uuid",
|
|
5796
|
+
"description": "Legacy alias for oauth_grant_id"
|
|
5797
|
+
},
|
|
5798
|
+
"key_prefix": {
|
|
5799
|
+
"type": "string",
|
|
5800
|
+
"description": "Legacy display prefix derived from access_token"
|
|
5801
|
+
},
|
|
5802
|
+
"access_token": {
|
|
5803
|
+
"type": "string",
|
|
5804
|
+
"description": "OAuth access token for CLI API authentication"
|
|
5805
|
+
},
|
|
5806
|
+
"refresh_token": {
|
|
5807
|
+
"type": "string",
|
|
5808
|
+
"description": "OAuth refresh token used by the CLI to renew access"
|
|
5809
|
+
},
|
|
5810
|
+
"token_type": {
|
|
5811
|
+
"type": "string",
|
|
5812
|
+
"enum": ["Bearer"]
|
|
5813
|
+
},
|
|
5814
|
+
"expires_in": {
|
|
5815
|
+
"type": "integer",
|
|
5816
|
+
"description": "Seconds until access_token expires"
|
|
5817
|
+
},
|
|
5818
|
+
"auth_method": {
|
|
5819
|
+
"type": "string",
|
|
5820
|
+
"enum": ["oauth"]
|
|
5821
|
+
},
|
|
5822
|
+
"oauth_grant_id": {
|
|
4943
5823
|
"type": "string",
|
|
4944
5824
|
"format": "uuid"
|
|
4945
5825
|
},
|
|
4946
|
-
"
|
|
5826
|
+
"oauth_client_id": { "type": "string" },
|
|
4947
5827
|
"org_id": {
|
|
4948
5828
|
"type": "string",
|
|
4949
5829
|
"format": "uuid"
|
|
@@ -4954,12 +5834,19 @@ const operationManifest = [
|
|
|
4954
5834
|
"api_key",
|
|
4955
5835
|
"key_id",
|
|
4956
5836
|
"key_prefix",
|
|
5837
|
+
"access_token",
|
|
5838
|
+
"refresh_token",
|
|
5839
|
+
"token_type",
|
|
5840
|
+
"expires_in",
|
|
5841
|
+
"auth_method",
|
|
5842
|
+
"oauth_grant_id",
|
|
5843
|
+
"oauth_client_id",
|
|
4957
5844
|
"org_id",
|
|
4958
5845
|
"org_name"
|
|
4959
5846
|
]
|
|
4960
5847
|
},
|
|
4961
5848
|
"sdkName": "verifyCliSignup",
|
|
4962
|
-
"summary": "Verify CLI signup and create
|
|
5849
|
+
"summary": "Verify CLI signup and create OAuth session",
|
|
4963
5850
|
"tag": "CLI",
|
|
4964
5851
|
"tagCommand": "cli"
|
|
4965
5852
|
},
|
|
@@ -4967,7 +5854,7 @@ const operationManifest = [
|
|
|
4967
5854
|
"binaryResponse": false,
|
|
4968
5855
|
"bodyRequired": true,
|
|
4969
5856
|
"command": "add-domain",
|
|
4970
|
-
"description": "Creates an unverified domain claim
|
|
5857
|
+
"description": "Creates an unverified domain claim and returns the exact\nDNS records to publish in `dns_records`. Publish those\nrecords before calling the verify endpoint. To give users\nan importable DNS file, call `downloadDomainZoneFile` or run\n`primitive domains zone-file --id <domain-id>`.\n",
|
|
4971
5858
|
"hasJsonBody": true,
|
|
4972
5859
|
"method": "POST",
|
|
4973
5860
|
"operationId": "addDomain",
|
|
@@ -4977,12 +5864,23 @@ const operationManifest = [
|
|
|
4977
5864
|
"requestSchema": {
|
|
4978
5865
|
"type": "object",
|
|
4979
5866
|
"additionalProperties": false,
|
|
4980
|
-
"properties": {
|
|
4981
|
-
"
|
|
4982
|
-
|
|
4983
|
-
|
|
4984
|
-
|
|
4985
|
-
|
|
5867
|
+
"properties": {
|
|
5868
|
+
"domain": {
|
|
5869
|
+
"type": "string",
|
|
5870
|
+
"minLength": 1,
|
|
5871
|
+
"maxLength": 253,
|
|
5872
|
+
"description": "The domain name to claim (e.g. \"example.com\")"
|
|
5873
|
+
},
|
|
5874
|
+
"confirmed": {
|
|
5875
|
+
"type": "boolean",
|
|
5876
|
+
"description": "Set to true to confirm replacing an existing mailbox provider after an mx_conflict response."
|
|
5877
|
+
},
|
|
5878
|
+
"outbound": {
|
|
5879
|
+
"type": "boolean",
|
|
5880
|
+
"deprecated": true,
|
|
5881
|
+
"description": "Deprecated and ignored. Outbound DNS is provisioned for every new domain claim."
|
|
5882
|
+
}
|
|
5883
|
+
},
|
|
4986
5884
|
"required": ["domain"]
|
|
4987
5885
|
},
|
|
4988
5886
|
"responseSchema": {
|
|
@@ -5005,6 +5903,78 @@ const operationManifest = [
|
|
|
5005
5903
|
"type": "string",
|
|
5006
5904
|
"description": "Add this value as a TXT record to verify ownership"
|
|
5007
5905
|
},
|
|
5906
|
+
"dns_records": {
|
|
5907
|
+
"type": "array",
|
|
5908
|
+
"description": "Exact DNS records to publish for this pending domain claim.",
|
|
5909
|
+
"items": {
|
|
5910
|
+
"type": "object",
|
|
5911
|
+
"additionalProperties": false,
|
|
5912
|
+
"properties": {
|
|
5913
|
+
"type": {
|
|
5914
|
+
"type": "string",
|
|
5915
|
+
"enum": ["MX", "TXT"],
|
|
5916
|
+
"description": "DNS record type."
|
|
5917
|
+
},
|
|
5918
|
+
"name": {
|
|
5919
|
+
"type": "string",
|
|
5920
|
+
"description": "DNS-provider host/name value relative to the managed root zone."
|
|
5921
|
+
},
|
|
5922
|
+
"fqdn": {
|
|
5923
|
+
"type": "string",
|
|
5924
|
+
"description": "Fully-qualified DNS record name."
|
|
5925
|
+
},
|
|
5926
|
+
"value": {
|
|
5927
|
+
"type": "string",
|
|
5928
|
+
"description": "Exact value to publish."
|
|
5929
|
+
},
|
|
5930
|
+
"priority": {
|
|
5931
|
+
"type": "integer",
|
|
5932
|
+
"description": "MX priority. Present only for MX records."
|
|
5933
|
+
},
|
|
5934
|
+
"ttl": {
|
|
5935
|
+
"type": "integer",
|
|
5936
|
+
"description": "Suggested TTL in seconds when the API can provide one."
|
|
5937
|
+
},
|
|
5938
|
+
"required": {
|
|
5939
|
+
"type": "boolean",
|
|
5940
|
+
"const": true
|
|
5941
|
+
},
|
|
5942
|
+
"purpose": {
|
|
5943
|
+
"type": "string",
|
|
5944
|
+
"enum": [
|
|
5945
|
+
"inbound_mx",
|
|
5946
|
+
"ownership_verification",
|
|
5947
|
+
"spf",
|
|
5948
|
+
"dkim",
|
|
5949
|
+
"dmarc",
|
|
5950
|
+
"tls_reporting"
|
|
5951
|
+
]
|
|
5952
|
+
},
|
|
5953
|
+
"status": {
|
|
5954
|
+
"type": "string",
|
|
5955
|
+
"enum": [
|
|
5956
|
+
"pending",
|
|
5957
|
+
"found",
|
|
5958
|
+
"missing",
|
|
5959
|
+
"incorrect"
|
|
5960
|
+
]
|
|
5961
|
+
},
|
|
5962
|
+
"message": {
|
|
5963
|
+
"type": "string",
|
|
5964
|
+
"description": "Short explanation of why this record is needed."
|
|
5965
|
+
}
|
|
5966
|
+
},
|
|
5967
|
+
"required": [
|
|
5968
|
+
"type",
|
|
5969
|
+
"name",
|
|
5970
|
+
"fqdn",
|
|
5971
|
+
"value",
|
|
5972
|
+
"required",
|
|
5973
|
+
"purpose",
|
|
5974
|
+
"status"
|
|
5975
|
+
]
|
|
5976
|
+
}
|
|
5977
|
+
},
|
|
5008
5978
|
"created_at": {
|
|
5009
5979
|
"type": "string",
|
|
5010
5980
|
"format": "date-time"
|
|
@@ -5048,6 +6018,36 @@ const operationManifest = [
|
|
|
5048
6018
|
"tag": "Domains",
|
|
5049
6019
|
"tagCommand": "domains"
|
|
5050
6020
|
},
|
|
6021
|
+
{
|
|
6022
|
+
"binaryResponse": true,
|
|
6023
|
+
"bodyRequired": false,
|
|
6024
|
+
"command": "download-domain-zone-file",
|
|
6025
|
+
"description": "Downloads a BIND-format DNS zone file containing the DNS records\nrequired for a domain claim. Agents should offer this after\n`addDomain` when users want to import DNS records instead of\ncopying each record manually.\n",
|
|
6026
|
+
"hasJsonBody": false,
|
|
6027
|
+
"method": "GET",
|
|
6028
|
+
"operationId": "downloadDomainZoneFile",
|
|
6029
|
+
"path": "/domains/{id}/zone-file",
|
|
6030
|
+
"pathParams": [{
|
|
6031
|
+
"description": "Resource UUID",
|
|
6032
|
+
"enum": null,
|
|
6033
|
+
"name": "id",
|
|
6034
|
+
"required": true,
|
|
6035
|
+
"type": "string"
|
|
6036
|
+
}],
|
|
6037
|
+
"queryParams": [{
|
|
6038
|
+
"description": "When true, include only outbound DNS records. Verified domains\ndefault to outbound-only; pending claims default to all required\nrecords.\n",
|
|
6039
|
+
"enum": null,
|
|
6040
|
+
"name": "outbound_only",
|
|
6041
|
+
"required": false,
|
|
6042
|
+
"type": "boolean"
|
|
6043
|
+
}],
|
|
6044
|
+
"requestSchema": null,
|
|
6045
|
+
"responseSchema": null,
|
|
6046
|
+
"sdkName": "downloadDomainZoneFile",
|
|
6047
|
+
"summary": "Download domain DNS zone file",
|
|
6048
|
+
"tag": "Domains",
|
|
6049
|
+
"tagCommand": "domains"
|
|
6050
|
+
},
|
|
5051
6051
|
{
|
|
5052
6052
|
"binaryResponse": false,
|
|
5053
6053
|
"bodyRequired": false,
|
|
@@ -5063,7 +6063,7 @@ const operationManifest = [
|
|
|
5063
6063
|
"responseSchema": {
|
|
5064
6064
|
"type": "array",
|
|
5065
6065
|
"items": {
|
|
5066
|
-
"description": "A domain can be either verified or unverified. Verified domains have\n`is_active` and `spam_threshold` fields. Unverified domains have a\n`verification_token` for DNS
|
|
6066
|
+
"description": "A domain can be either verified or unverified. Verified domains have\n`is_active` and `spam_threshold` fields. Unverified domains have a\n`verification_token` and `dns_records` for DNS setup.\n",
|
|
5067
6067
|
"oneOf": [{
|
|
5068
6068
|
"type": "object",
|
|
5069
6069
|
"properties": {
|
|
@@ -5120,6 +6120,78 @@ const operationManifest = [
|
|
|
5120
6120
|
"type": "string",
|
|
5121
6121
|
"description": "Add this value as a TXT record to verify ownership"
|
|
5122
6122
|
},
|
|
6123
|
+
"dns_records": {
|
|
6124
|
+
"type": "array",
|
|
6125
|
+
"description": "Exact DNS records to publish for this pending domain claim.",
|
|
6126
|
+
"items": {
|
|
6127
|
+
"type": "object",
|
|
6128
|
+
"additionalProperties": false,
|
|
6129
|
+
"properties": {
|
|
6130
|
+
"type": {
|
|
6131
|
+
"type": "string",
|
|
6132
|
+
"enum": ["MX", "TXT"],
|
|
6133
|
+
"description": "DNS record type."
|
|
6134
|
+
},
|
|
6135
|
+
"name": {
|
|
6136
|
+
"type": "string",
|
|
6137
|
+
"description": "DNS-provider host/name value relative to the managed root zone."
|
|
6138
|
+
},
|
|
6139
|
+
"fqdn": {
|
|
6140
|
+
"type": "string",
|
|
6141
|
+
"description": "Fully-qualified DNS record name."
|
|
6142
|
+
},
|
|
6143
|
+
"value": {
|
|
6144
|
+
"type": "string",
|
|
6145
|
+
"description": "Exact value to publish."
|
|
6146
|
+
},
|
|
6147
|
+
"priority": {
|
|
6148
|
+
"type": "integer",
|
|
6149
|
+
"description": "MX priority. Present only for MX records."
|
|
6150
|
+
},
|
|
6151
|
+
"ttl": {
|
|
6152
|
+
"type": "integer",
|
|
6153
|
+
"description": "Suggested TTL in seconds when the API can provide one."
|
|
6154
|
+
},
|
|
6155
|
+
"required": {
|
|
6156
|
+
"type": "boolean",
|
|
6157
|
+
"const": true
|
|
6158
|
+
},
|
|
6159
|
+
"purpose": {
|
|
6160
|
+
"type": "string",
|
|
6161
|
+
"enum": [
|
|
6162
|
+
"inbound_mx",
|
|
6163
|
+
"ownership_verification",
|
|
6164
|
+
"spf",
|
|
6165
|
+
"dkim",
|
|
6166
|
+
"dmarc",
|
|
6167
|
+
"tls_reporting"
|
|
6168
|
+
]
|
|
6169
|
+
},
|
|
6170
|
+
"status": {
|
|
6171
|
+
"type": "string",
|
|
6172
|
+
"enum": [
|
|
6173
|
+
"pending",
|
|
6174
|
+
"found",
|
|
6175
|
+
"missing",
|
|
6176
|
+
"incorrect"
|
|
6177
|
+
]
|
|
6178
|
+
},
|
|
6179
|
+
"message": {
|
|
6180
|
+
"type": "string",
|
|
6181
|
+
"description": "Short explanation of why this record is needed."
|
|
6182
|
+
}
|
|
6183
|
+
},
|
|
6184
|
+
"required": [
|
|
6185
|
+
"type",
|
|
6186
|
+
"name",
|
|
6187
|
+
"fqdn",
|
|
6188
|
+
"value",
|
|
6189
|
+
"required",
|
|
6190
|
+
"purpose",
|
|
6191
|
+
"status"
|
|
6192
|
+
]
|
|
6193
|
+
}
|
|
6194
|
+
},
|
|
5123
6195
|
"created_at": {
|
|
5124
6196
|
"type": "string",
|
|
5125
6197
|
"format": "date-time"
|
|
@@ -5221,7 +6293,7 @@ const operationManifest = [
|
|
|
5221
6293
|
"binaryResponse": false,
|
|
5222
6294
|
"bodyRequired": false,
|
|
5223
6295
|
"command": "verify-domain",
|
|
5224
|
-
"description": "Checks DNS records
|
|
6296
|
+
"description": "Checks DNS records required for inbound routing, ownership,\nand outbound authentication: MX, ownership TXT, SPF, DKIM,\nDMARC, and TLS-RPT.\nOn success, the domain is promoted from unverified to verified.\nOn failure, returns which checks passed and which failed,\nplus the exact DNS records still expected. To give users\nan importable DNS file for missing records, call\n`downloadDomainZoneFile` or run\n`primitive domains zone-file --id <domain-id>`.\n",
|
|
5225
6297
|
"hasJsonBody": false,
|
|
5226
6298
|
"method": "POST",
|
|
5227
6299
|
"operationId": "verifyDomain",
|
|
@@ -5237,10 +6309,84 @@ const operationManifest = [
|
|
|
5237
6309
|
"requestSchema": null,
|
|
5238
6310
|
"responseSchema": { "oneOf": [{
|
|
5239
6311
|
"type": "object",
|
|
5240
|
-
"properties": {
|
|
5241
|
-
"
|
|
5242
|
-
|
|
5243
|
-
|
|
6312
|
+
"properties": {
|
|
6313
|
+
"verified": {
|
|
6314
|
+
"type": "boolean",
|
|
6315
|
+
"const": true
|
|
6316
|
+
},
|
|
6317
|
+
"dns_records": {
|
|
6318
|
+
"type": "array",
|
|
6319
|
+
"description": "Exact DNS records checked for this verification attempt.",
|
|
6320
|
+
"items": {
|
|
6321
|
+
"type": "object",
|
|
6322
|
+
"additionalProperties": false,
|
|
6323
|
+
"properties": {
|
|
6324
|
+
"type": {
|
|
6325
|
+
"type": "string",
|
|
6326
|
+
"enum": ["MX", "TXT"],
|
|
6327
|
+
"description": "DNS record type."
|
|
6328
|
+
},
|
|
6329
|
+
"name": {
|
|
6330
|
+
"type": "string",
|
|
6331
|
+
"description": "DNS-provider host/name value relative to the managed root zone."
|
|
6332
|
+
},
|
|
6333
|
+
"fqdn": {
|
|
6334
|
+
"type": "string",
|
|
6335
|
+
"description": "Fully-qualified DNS record name."
|
|
6336
|
+
},
|
|
6337
|
+
"value": {
|
|
6338
|
+
"type": "string",
|
|
6339
|
+
"description": "Exact value to publish."
|
|
6340
|
+
},
|
|
6341
|
+
"priority": {
|
|
6342
|
+
"type": "integer",
|
|
6343
|
+
"description": "MX priority. Present only for MX records."
|
|
6344
|
+
},
|
|
6345
|
+
"ttl": {
|
|
6346
|
+
"type": "integer",
|
|
6347
|
+
"description": "Suggested TTL in seconds when the API can provide one."
|
|
6348
|
+
},
|
|
6349
|
+
"required": {
|
|
6350
|
+
"type": "boolean",
|
|
6351
|
+
"const": true
|
|
6352
|
+
},
|
|
6353
|
+
"purpose": {
|
|
6354
|
+
"type": "string",
|
|
6355
|
+
"enum": [
|
|
6356
|
+
"inbound_mx",
|
|
6357
|
+
"ownership_verification",
|
|
6358
|
+
"spf",
|
|
6359
|
+
"dkim",
|
|
6360
|
+
"dmarc",
|
|
6361
|
+
"tls_reporting"
|
|
6362
|
+
]
|
|
6363
|
+
},
|
|
6364
|
+
"status": {
|
|
6365
|
+
"type": "string",
|
|
6366
|
+
"enum": [
|
|
6367
|
+
"pending",
|
|
6368
|
+
"found",
|
|
6369
|
+
"missing",
|
|
6370
|
+
"incorrect"
|
|
6371
|
+
]
|
|
6372
|
+
},
|
|
6373
|
+
"message": {
|
|
6374
|
+
"type": "string",
|
|
6375
|
+
"description": "Short explanation of why this record is needed."
|
|
6376
|
+
}
|
|
6377
|
+
},
|
|
6378
|
+
"required": [
|
|
6379
|
+
"type",
|
|
6380
|
+
"name",
|
|
6381
|
+
"fqdn",
|
|
6382
|
+
"value",
|
|
6383
|
+
"required",
|
|
6384
|
+
"purpose",
|
|
6385
|
+
"status"
|
|
6386
|
+
]
|
|
6387
|
+
}
|
|
6388
|
+
}
|
|
6389
|
+
},
|
|
5244
6390
|
"required": ["verified"]
|
|
5245
6391
|
}, {
|
|
5246
6392
|
"type": "object",
|
|
@@ -5257,6 +6403,94 @@ const operationManifest = [
|
|
|
5257
6403
|
"type": "boolean",
|
|
5258
6404
|
"description": "Whether the TXT verification record was found"
|
|
5259
6405
|
},
|
|
6406
|
+
"spfFound": {
|
|
6407
|
+
"type": "boolean",
|
|
6408
|
+
"description": "Whether the SPF record includes Primitive."
|
|
6409
|
+
},
|
|
6410
|
+
"dkimFound": {
|
|
6411
|
+
"type": "boolean",
|
|
6412
|
+
"description": "Whether the DKIM public key record was found."
|
|
6413
|
+
},
|
|
6414
|
+
"dmarcFound": {
|
|
6415
|
+
"type": "boolean",
|
|
6416
|
+
"description": "Whether the DMARC record was found."
|
|
6417
|
+
},
|
|
6418
|
+
"tlsRptFound": {
|
|
6419
|
+
"type": "boolean",
|
|
6420
|
+
"description": "Whether the TLS-RPT record was found."
|
|
6421
|
+
},
|
|
6422
|
+
"dns_records": {
|
|
6423
|
+
"type": "array",
|
|
6424
|
+
"description": "Exact DNS records checked for this verification attempt.",
|
|
6425
|
+
"items": {
|
|
6426
|
+
"type": "object",
|
|
6427
|
+
"additionalProperties": false,
|
|
6428
|
+
"properties": {
|
|
6429
|
+
"type": {
|
|
6430
|
+
"type": "string",
|
|
6431
|
+
"enum": ["MX", "TXT"],
|
|
6432
|
+
"description": "DNS record type."
|
|
6433
|
+
},
|
|
6434
|
+
"name": {
|
|
6435
|
+
"type": "string",
|
|
6436
|
+
"description": "DNS-provider host/name value relative to the managed root zone."
|
|
6437
|
+
},
|
|
6438
|
+
"fqdn": {
|
|
6439
|
+
"type": "string",
|
|
6440
|
+
"description": "Fully-qualified DNS record name."
|
|
6441
|
+
},
|
|
6442
|
+
"value": {
|
|
6443
|
+
"type": "string",
|
|
6444
|
+
"description": "Exact value to publish."
|
|
6445
|
+
},
|
|
6446
|
+
"priority": {
|
|
6447
|
+
"type": "integer",
|
|
6448
|
+
"description": "MX priority. Present only for MX records."
|
|
6449
|
+
},
|
|
6450
|
+
"ttl": {
|
|
6451
|
+
"type": "integer",
|
|
6452
|
+
"description": "Suggested TTL in seconds when the API can provide one."
|
|
6453
|
+
},
|
|
6454
|
+
"required": {
|
|
6455
|
+
"type": "boolean",
|
|
6456
|
+
"const": true
|
|
6457
|
+
},
|
|
6458
|
+
"purpose": {
|
|
6459
|
+
"type": "string",
|
|
6460
|
+
"enum": [
|
|
6461
|
+
"inbound_mx",
|
|
6462
|
+
"ownership_verification",
|
|
6463
|
+
"spf",
|
|
6464
|
+
"dkim",
|
|
6465
|
+
"dmarc",
|
|
6466
|
+
"tls_reporting"
|
|
6467
|
+
]
|
|
6468
|
+
},
|
|
6469
|
+
"status": {
|
|
6470
|
+
"type": "string",
|
|
6471
|
+
"enum": [
|
|
6472
|
+
"pending",
|
|
6473
|
+
"found",
|
|
6474
|
+
"missing",
|
|
6475
|
+
"incorrect"
|
|
6476
|
+
]
|
|
6477
|
+
},
|
|
6478
|
+
"message": {
|
|
6479
|
+
"type": "string",
|
|
6480
|
+
"description": "Short explanation of why this record is needed."
|
|
6481
|
+
}
|
|
6482
|
+
},
|
|
6483
|
+
"required": [
|
|
6484
|
+
"type",
|
|
6485
|
+
"name",
|
|
6486
|
+
"fqdn",
|
|
6487
|
+
"value",
|
|
6488
|
+
"required",
|
|
6489
|
+
"purpose",
|
|
6490
|
+
"status"
|
|
6491
|
+
]
|
|
6492
|
+
}
|
|
6493
|
+
},
|
|
5260
6494
|
"error": {
|
|
5261
6495
|
"type": "string",
|
|
5262
6496
|
"description": "Human-readable verification failure reason"
|
|
@@ -8630,6 +9864,36 @@ const operationManifest = [
|
|
|
8630
9864
|
"pattern": "^[^\\x00-\\x1F\\x7F]+$"
|
|
8631
9865
|
}
|
|
8632
9866
|
},
|
|
9867
|
+
"attachments": {
|
|
9868
|
+
"type": "array",
|
|
9869
|
+
"maxItems": 100,
|
|
9870
|
+
"description": "Inline attachments. Send requests with attachments to https://api.primitive.dev/v1/send-mail. Combined raw decoded attachment bytes must be at most 31457280.",
|
|
9871
|
+
"items": {
|
|
9872
|
+
"type": "object",
|
|
9873
|
+
"additionalProperties": false,
|
|
9874
|
+
"properties": {
|
|
9875
|
+
"filename": {
|
|
9876
|
+
"type": "string",
|
|
9877
|
+
"minLength": 1,
|
|
9878
|
+
"maxLength": 255,
|
|
9879
|
+
"description": "Attachment filename. Control characters are rejected."
|
|
9880
|
+
},
|
|
9881
|
+
"content_type": {
|
|
9882
|
+
"type": "string",
|
|
9883
|
+
"minLength": 1,
|
|
9884
|
+
"maxLength": 255,
|
|
9885
|
+
"description": "Optional MIME content type. Control characters are rejected."
|
|
9886
|
+
},
|
|
9887
|
+
"content_base64": {
|
|
9888
|
+
"type": "string",
|
|
9889
|
+
"minLength": 1,
|
|
9890
|
+
"maxLength": 44040192,
|
|
9891
|
+
"description": "Base64-encoded attachment bytes."
|
|
9892
|
+
}
|
|
9893
|
+
},
|
|
9894
|
+
"required": ["filename", "content_base64"]
|
|
9895
|
+
}
|
|
9896
|
+
},
|
|
8633
9897
|
"wait": {
|
|
8634
9898
|
"type": "boolean",
|
|
8635
9899
|
"description": "When true, wait for the first downstream SMTP delivery outcome before returning."
|