@primitivedotdev/sdk 1.19.0 → 1.21.0
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-CnvYcgJ-.js → api-Oi6Mo4Us.js} +146 -3
- package/dist/{index-d8WzbPv5.d.ts → index-Da2SjL1d.d.ts} +456 -3
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/openapi/index.js +1 -1
- package/dist/{operations.generated-CORS0UoM.js → operations.generated-BHSC87qb.js} +1588 -203
- package/dist/payloads/index.d.ts +80 -0
- package/dist/payloads/index.js +392 -0
- package/package.json +7 -2
|
@@ -97,6 +97,10 @@ const openapiDocument = {
|
|
|
97
97
|
"name": "Memories",
|
|
98
98
|
"description": "Durable org-scoped or function-scoped JSON key-value storage for\nagents and functions. Keys are caller-defined. Function scope is\nalways addressed by the function id UUID, not by function name.\n"
|
|
99
99
|
},
|
|
100
|
+
{
|
|
101
|
+
"name": "Templates",
|
|
102
|
+
"description": "Browse approved Function templates, install deploy-mode templates, and\npoll install progress.\n"
|
|
103
|
+
},
|
|
100
104
|
{
|
|
101
105
|
"name": "Registries",
|
|
102
106
|
"description": "The Agent Registry: ownable directories of agents, addressable by a\nregistry-scoped handle. A registry's publish policy (owner_only, request,\nor open) decides whether a publish lists immediately or pends owner\napproval. An agent is defined once with a globally unique,\nreachability-verified address, then published into any registry under a\nhandle. Discovery reads (list, resolve, get) are public for public\nregistries; managing a registry and moderating requests use the owner's\nAPI key.\n"
|
|
@@ -2922,6 +2926,167 @@ const openapiDocument = {
|
|
|
2922
2926
|
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
2923
2927
|
}
|
|
2924
2928
|
} },
|
|
2929
|
+
"/templates": { "get": {
|
|
2930
|
+
"operationId": "listTemplates",
|
|
2931
|
+
"summary": "List function templates",
|
|
2932
|
+
"description": "List approved Function templates available for browsing and\ninstallation. Results are cacheable and paginated with\n`data.next_cursor`.\n",
|
|
2933
|
+
"tags": ["Templates"],
|
|
2934
|
+
"security": [],
|
|
2935
|
+
"parameters": [
|
|
2936
|
+
{
|
|
2937
|
+
"name": "q",
|
|
2938
|
+
"in": "query",
|
|
2939
|
+
"required": false,
|
|
2940
|
+
"description": "Search templates by title, summary, or slug.",
|
|
2941
|
+
"schema": {
|
|
2942
|
+
"type": "string",
|
|
2943
|
+
"minLength": 1
|
|
2944
|
+
}
|
|
2945
|
+
},
|
|
2946
|
+
{
|
|
2947
|
+
"name": "tag",
|
|
2948
|
+
"in": "query",
|
|
2949
|
+
"required": false,
|
|
2950
|
+
"description": "Filter templates by an exact tag.",
|
|
2951
|
+
"schema": {
|
|
2952
|
+
"type": "string",
|
|
2953
|
+
"minLength": 1
|
|
2954
|
+
}
|
|
2955
|
+
},
|
|
2956
|
+
{
|
|
2957
|
+
"name": "cursor",
|
|
2958
|
+
"in": "query",
|
|
2959
|
+
"required": false,
|
|
2960
|
+
"description": "Cursor from a previous response `data.next_cursor` value.",
|
|
2961
|
+
"schema": { "type": "string" }
|
|
2962
|
+
},
|
|
2963
|
+
{
|
|
2964
|
+
"name": "limit",
|
|
2965
|
+
"in": "query",
|
|
2966
|
+
"required": false,
|
|
2967
|
+
"description": "Maximum number of templates to return. The server caps this at 100.",
|
|
2968
|
+
"schema": {
|
|
2969
|
+
"type": "integer",
|
|
2970
|
+
"minimum": 1,
|
|
2971
|
+
"maximum": 100,
|
|
2972
|
+
"default": 50
|
|
2973
|
+
}
|
|
2974
|
+
}
|
|
2975
|
+
],
|
|
2976
|
+
"responses": {
|
|
2977
|
+
"200": {
|
|
2978
|
+
"description": "Paginated template registry summaries",
|
|
2979
|
+
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
2980
|
+
"type": "object",
|
|
2981
|
+
"properties": { "data": { "$ref": "#/components/schemas/TemplateRegistryPage" } },
|
|
2982
|
+
"required": ["data"]
|
|
2983
|
+
}] } } }
|
|
2984
|
+
},
|
|
2985
|
+
"400": { "$ref": "#/components/responses/ValidationError" },
|
|
2986
|
+
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
2987
|
+
}
|
|
2988
|
+
} },
|
|
2989
|
+
"/templates/{id}": { "get": {
|
|
2990
|
+
"operationId": "getTemplate",
|
|
2991
|
+
"summary": "Get a function template",
|
|
2992
|
+
"description": "Fetch one approved Function template by slug, including its manifest\nsnapshot and README. The stored source files used for install are not\nreturned.\n",
|
|
2993
|
+
"tags": ["Templates"],
|
|
2994
|
+
"security": [],
|
|
2995
|
+
"parameters": [{
|
|
2996
|
+
"name": "id",
|
|
2997
|
+
"in": "path",
|
|
2998
|
+
"required": true,
|
|
2999
|
+
"description": "Template slug from the template manifest.",
|
|
3000
|
+
"schema": {
|
|
3001
|
+
"type": "string",
|
|
3002
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$"
|
|
3003
|
+
}
|
|
3004
|
+
}],
|
|
3005
|
+
"responses": {
|
|
3006
|
+
"200": {
|
|
3007
|
+
"description": "Template registry detail",
|
|
3008
|
+
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
3009
|
+
"type": "object",
|
|
3010
|
+
"properties": { "data": { "$ref": "#/components/schemas/TemplateRegistryDetail" } },
|
|
3011
|
+
"required": ["data"]
|
|
3012
|
+
}] } } }
|
|
3013
|
+
},
|
|
3014
|
+
"400": { "$ref": "#/components/responses/ValidationError" },
|
|
3015
|
+
"404": { "$ref": "#/components/responses/NotFound" },
|
|
3016
|
+
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
3017
|
+
}
|
|
3018
|
+
} },
|
|
3019
|
+
"/templates/{id}/install": { "post": {
|
|
3020
|
+
"operationId": "installTemplate",
|
|
3021
|
+
"summary": "Install a function template",
|
|
3022
|
+
"description": "Start a one-shot deploy of an approved deploy-mode Function template.\nThe response returns an install record immediately; poll\n`GET /templates/installs/{id}` for progress.\n",
|
|
3023
|
+
"tags": ["Templates"],
|
|
3024
|
+
"security": [{ "BearerAuth": [] }],
|
|
3025
|
+
"parameters": [{
|
|
3026
|
+
"name": "id",
|
|
3027
|
+
"in": "path",
|
|
3028
|
+
"required": true,
|
|
3029
|
+
"description": "Template slug from the template manifest.",
|
|
3030
|
+
"schema": {
|
|
3031
|
+
"type": "string",
|
|
3032
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$"
|
|
3033
|
+
}
|
|
3034
|
+
}],
|
|
3035
|
+
"requestBody": {
|
|
3036
|
+
"required": true,
|
|
3037
|
+
"content": { "application/json": { "schema": { "$ref": "#/components/schemas/InstallTemplateBody" } } }
|
|
3038
|
+
},
|
|
3039
|
+
"responses": {
|
|
3040
|
+
"201": {
|
|
3041
|
+
"description": "Template install started",
|
|
3042
|
+
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
3043
|
+
"type": "object",
|
|
3044
|
+
"properties": { "data": { "$ref": "#/components/schemas/TemplateInstallStatus" } },
|
|
3045
|
+
"required": ["data"]
|
|
3046
|
+
}] } } }
|
|
3047
|
+
},
|
|
3048
|
+
"400": { "$ref": "#/components/responses/ValidationError" },
|
|
3049
|
+
"401": { "$ref": "#/components/responses/Unauthorized" },
|
|
3050
|
+
"403": { "$ref": "#/components/responses/Forbidden" },
|
|
3051
|
+
"404": { "$ref": "#/components/responses/NotFound" },
|
|
3052
|
+
"409": { "$ref": "#/components/responses/Conflict" },
|
|
3053
|
+
"422": { "$ref": "#/components/responses/UnprocessableEntity" },
|
|
3054
|
+
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
3055
|
+
}
|
|
3056
|
+
} },
|
|
3057
|
+
"/templates/installs/{id}": { "get": {
|
|
3058
|
+
"operationId": "getTemplateInstall",
|
|
3059
|
+
"summary": "Get template install status",
|
|
3060
|
+
"description": "Fetch the current state of a template install. Reads may advance the\nself-test phase when a reply effect has been observed.\n",
|
|
3061
|
+
"tags": ["Templates"],
|
|
3062
|
+
"security": [{ "BearerAuth": [] }],
|
|
3063
|
+
"parameters": [{
|
|
3064
|
+
"name": "id",
|
|
3065
|
+
"in": "path",
|
|
3066
|
+
"required": true,
|
|
3067
|
+
"description": "Template install UUID.",
|
|
3068
|
+
"schema": {
|
|
3069
|
+
"type": "string",
|
|
3070
|
+
"format": "uuid",
|
|
3071
|
+
"pattern": "^[0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{4}-[0-9a-fA-F]{12}$"
|
|
3072
|
+
}
|
|
3073
|
+
}],
|
|
3074
|
+
"responses": {
|
|
3075
|
+
"200": {
|
|
3076
|
+
"description": "Current template install status",
|
|
3077
|
+
"content": { "application/json": { "schema": { "allOf": [{ "$ref": "#/components/schemas/SuccessEnvelope" }, {
|
|
3078
|
+
"type": "object",
|
|
3079
|
+
"properties": { "data": { "$ref": "#/components/schemas/TemplateInstallStatus" } },
|
|
3080
|
+
"required": ["data"]
|
|
3081
|
+
}] } } }
|
|
3082
|
+
},
|
|
3083
|
+
"400": { "$ref": "#/components/responses/ValidationError" },
|
|
3084
|
+
"401": { "$ref": "#/components/responses/Unauthorized" },
|
|
3085
|
+
"403": { "$ref": "#/components/responses/Forbidden" },
|
|
3086
|
+
"404": { "$ref": "#/components/responses/NotFound" },
|
|
3087
|
+
"429": { "$ref": "#/components/responses/RateLimited" }
|
|
3088
|
+
}
|
|
3089
|
+
} },
|
|
2925
3090
|
"/x402/payout-addresses": {
|
|
2926
3091
|
"post": {
|
|
2927
3092
|
"operationId": "registerPayoutAddress",
|
|
@@ -4592,6 +4757,16 @@ const openapiDocument = {
|
|
|
4592
4757
|
"org_not_accessible",
|
|
4593
4758
|
"feature_disabled",
|
|
4594
4759
|
"memory_conflict",
|
|
4760
|
+
"template_not_installable",
|
|
4761
|
+
"scaffold_only",
|
|
4762
|
+
"invalid_variables",
|
|
4763
|
+
"unknown_secrets",
|
|
4764
|
+
"missing_secrets",
|
|
4765
|
+
"no_inbound_domain",
|
|
4766
|
+
"domain_cannot_send",
|
|
4767
|
+
"address_taken",
|
|
4768
|
+
"route_cap_reached",
|
|
4769
|
+
"name_exhausted",
|
|
4595
4770
|
"developer_usage_credit_exhausted",
|
|
4596
4771
|
"no_payout_address",
|
|
4597
4772
|
"ownership_proof_failed",
|
|
@@ -6640,6 +6815,40 @@ const openapiDocument = {
|
|
|
6640
6815
|
},
|
|
6641
6816
|
"required": ["filename", "content_base64"]
|
|
6642
6817
|
},
|
|
6818
|
+
"SendMailPayloadRef": {
|
|
6819
|
+
"type": "object",
|
|
6820
|
+
"additionalProperties": false,
|
|
6821
|
+
"description": "A reference to an already-uploaded Primitive Payloads object, delivered as an attachment without inlining the bytes — the way to send an attachment larger than the inline cap. Upload the object via /v1/payloads (with a client-held CEK the server never sees), then reference it here.",
|
|
6822
|
+
"properties": {
|
|
6823
|
+
"root": {
|
|
6824
|
+
"type": "string",
|
|
6825
|
+
"pattern": "^[0-9a-f]{64}$",
|
|
6826
|
+
"description": "The 64-char lowercase-hex Merkle root of a finalized payloads object."
|
|
6827
|
+
},
|
|
6828
|
+
"filename": {
|
|
6829
|
+
"type": "string",
|
|
6830
|
+
"minLength": 1,
|
|
6831
|
+
"maxLength": 255,
|
|
6832
|
+
"description": "Attachment filename presented to the recipient."
|
|
6833
|
+
},
|
|
6834
|
+
"content_type": {
|
|
6835
|
+
"type": "string",
|
|
6836
|
+
"minLength": 1,
|
|
6837
|
+
"maxLength": 255,
|
|
6838
|
+
"description": "Optional MIME content type."
|
|
6839
|
+
},
|
|
6840
|
+
"cek": {
|
|
6841
|
+
"type": "string",
|
|
6842
|
+
"pattern": "^[A-Za-z0-9_-]{1,128}$",
|
|
6843
|
+
"description": "Base64url-encoded (unpadded) content-encryption key the recipient uses to decrypt. Travels with the email; the object store only ever holds ciphertext."
|
|
6844
|
+
}
|
|
6845
|
+
},
|
|
6846
|
+
"required": [
|
|
6847
|
+
"root",
|
|
6848
|
+
"filename",
|
|
6849
|
+
"cek"
|
|
6850
|
+
]
|
|
6851
|
+
},
|
|
6643
6852
|
"SendMailInput": {
|
|
6644
6853
|
"type": "object",
|
|
6645
6854
|
"additionalProperties": false,
|
|
@@ -6694,6 +6903,12 @@ const openapiDocument = {
|
|
|
6694
6903
|
"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.",
|
|
6695
6904
|
"items": { "$ref": "#/components/schemas/SendMailAttachment" }
|
|
6696
6905
|
},
|
|
6906
|
+
"payload_attachments": {
|
|
6907
|
+
"type": "array",
|
|
6908
|
+
"maxItems": 1,
|
|
6909
|
+
"description": "Deliver an already-uploaded Primitive Payloads object as an attachment by reference, without inlining the bytes — the way to send attachments larger than the inline cap. Upload the object via /v1/payloads (client-held CEK), then reference it here. v1 supports at most one.",
|
|
6910
|
+
"items": { "$ref": "#/components/schemas/SendMailPayloadRef" }
|
|
6911
|
+
},
|
|
6697
6912
|
"wait": {
|
|
6698
6913
|
"type": "boolean",
|
|
6699
6914
|
"description": "When true, wait for the first downstream SMTP delivery outcome before returning."
|
|
@@ -9334,72 +9549,542 @@ const openapiDocument = {
|
|
|
9334
9549
|
"key",
|
|
9335
9550
|
"scope"
|
|
9336
9551
|
]
|
|
9337
|
-
}
|
|
9338
|
-
|
|
9339
|
-
|
|
9340
|
-
|
|
9341
|
-
|
|
9342
|
-
|
|
9343
|
-
|
|
9344
|
-
|
|
9345
|
-
"binaryResponse": false,
|
|
9346
|
-
"bodyRequired": false,
|
|
9347
|
-
"command": "get-account",
|
|
9348
|
-
"description": null,
|
|
9349
|
-
"hasJsonBody": false,
|
|
9350
|
-
"method": "GET",
|
|
9351
|
-
"operationId": "getAccount",
|
|
9352
|
-
"path": "/account",
|
|
9353
|
-
"pathParams": [],
|
|
9354
|
-
"queryParams": [],
|
|
9355
|
-
"requestSchema": null,
|
|
9356
|
-
"responseSchema": {
|
|
9357
|
-
"type": "object",
|
|
9358
|
-
"properties": {
|
|
9359
|
-
"id": {
|
|
9360
|
-
"type": "string",
|
|
9361
|
-
"format": "uuid"
|
|
9362
|
-
},
|
|
9363
|
-
"email": { "type": "string" },
|
|
9364
|
-
"plan": { "type": "string" },
|
|
9365
|
-
"limits": {
|
|
9366
|
-
"type": "object",
|
|
9367
|
-
"description": "Plan-derived quota limits for an account.",
|
|
9368
|
-
"properties": {
|
|
9369
|
-
"storage_mb": { "type": "number" },
|
|
9370
|
-
"send_per_hour": { "type": "number" },
|
|
9371
|
-
"send_per_day": { "type": "number" },
|
|
9372
|
-
"api_per_minute": { "type": "number" },
|
|
9373
|
-
"webhooks_max_global": { "type": ["number", "null"] },
|
|
9374
|
-
"webhooks_per_domain": { "type": "boolean" },
|
|
9375
|
-
"filters_per_domain": { "type": "boolean" },
|
|
9376
|
-
"spam_thresholds_per_domain": { "type": "boolean" }
|
|
9552
|
+
},
|
|
9553
|
+
"TemplateAuthor": {
|
|
9554
|
+
"type": "object",
|
|
9555
|
+
"additionalProperties": false,
|
|
9556
|
+
"properties": {
|
|
9557
|
+
"id": {
|
|
9558
|
+
"type": "string",
|
|
9559
|
+
"minLength": 1
|
|
9377
9560
|
},
|
|
9378
|
-
"
|
|
9379
|
-
"
|
|
9380
|
-
"
|
|
9381
|
-
|
|
9382
|
-
|
|
9383
|
-
"
|
|
9384
|
-
"
|
|
9385
|
-
|
|
9386
|
-
"spam_thresholds_per_domain"
|
|
9387
|
-
]
|
|
9561
|
+
"name": {
|
|
9562
|
+
"type": "string",
|
|
9563
|
+
"minLength": 1
|
|
9564
|
+
},
|
|
9565
|
+
"url": {
|
|
9566
|
+
"type": "string",
|
|
9567
|
+
"format": "uri"
|
|
9568
|
+
}
|
|
9388
9569
|
},
|
|
9389
|
-
"
|
|
9390
|
-
|
|
9391
|
-
|
|
9392
|
-
|
|
9570
|
+
"required": ["id", "name"]
|
|
9571
|
+
},
|
|
9572
|
+
"TemplateSource": { "oneOf": [{
|
|
9573
|
+
"type": "object",
|
|
9574
|
+
"additionalProperties": false,
|
|
9575
|
+
"properties": {
|
|
9576
|
+
"mode": {
|
|
9577
|
+
"type": "string",
|
|
9578
|
+
"const": "managed-build"
|
|
9579
|
+
},
|
|
9580
|
+
"dir": {
|
|
9581
|
+
"type": "string",
|
|
9582
|
+
"minLength": 1,
|
|
9583
|
+
"default": "."
|
|
9584
|
+
}
|
|
9393
9585
|
},
|
|
9394
|
-
"
|
|
9395
|
-
|
|
9396
|
-
|
|
9586
|
+
"required": ["mode", "dir"]
|
|
9587
|
+
}, {
|
|
9588
|
+
"type": "object",
|
|
9589
|
+
"additionalProperties": false,
|
|
9590
|
+
"properties": {
|
|
9591
|
+
"mode": {
|
|
9592
|
+
"type": "string",
|
|
9593
|
+
"const": "bundle"
|
|
9594
|
+
},
|
|
9595
|
+
"file": {
|
|
9596
|
+
"type": "string",
|
|
9597
|
+
"minLength": 1
|
|
9598
|
+
}
|
|
9397
9599
|
},
|
|
9398
|
-
"
|
|
9399
|
-
|
|
9400
|
-
|
|
9600
|
+
"required": ["mode", "file"]
|
|
9601
|
+
}] },
|
|
9602
|
+
"TemplateInstall": {
|
|
9603
|
+
"type": "object",
|
|
9604
|
+
"additionalProperties": false,
|
|
9605
|
+
"properties": {
|
|
9606
|
+
"mode": {
|
|
9607
|
+
"type": "string",
|
|
9608
|
+
"enum": ["deploy", "scaffold"]
|
|
9609
|
+
},
|
|
9610
|
+
"editFiles": {
|
|
9611
|
+
"type": "array",
|
|
9612
|
+
"items": {
|
|
9613
|
+
"type": "string",
|
|
9614
|
+
"minLength": 1
|
|
9615
|
+
}
|
|
9616
|
+
},
|
|
9617
|
+
"reason": {
|
|
9618
|
+
"type": "string",
|
|
9619
|
+
"default": ""
|
|
9620
|
+
}
|
|
9401
9621
|
},
|
|
9402
|
-
"
|
|
9622
|
+
"required": [
|
|
9623
|
+
"mode",
|
|
9624
|
+
"editFiles",
|
|
9625
|
+
"reason"
|
|
9626
|
+
]
|
|
9627
|
+
},
|
|
9628
|
+
"TemplateSecret": {
|
|
9629
|
+
"type": "object",
|
|
9630
|
+
"additionalProperties": false,
|
|
9631
|
+
"properties": {
|
|
9632
|
+
"key": {
|
|
9633
|
+
"type": "string",
|
|
9634
|
+
"pattern": "^[A-Z_][A-Z0-9_]*$"
|
|
9635
|
+
},
|
|
9636
|
+
"required": {
|
|
9637
|
+
"type": "boolean",
|
|
9638
|
+
"default": true
|
|
9639
|
+
},
|
|
9640
|
+
"description": { "type": "string" }
|
|
9641
|
+
},
|
|
9642
|
+
"required": ["key", "required"]
|
|
9643
|
+
},
|
|
9644
|
+
"TemplateSecretGroup": {
|
|
9645
|
+
"type": "object",
|
|
9646
|
+
"additionalProperties": false,
|
|
9647
|
+
"properties": {
|
|
9648
|
+
"keys": {
|
|
9649
|
+
"type": "array",
|
|
9650
|
+
"minItems": 2,
|
|
9651
|
+
"items": {
|
|
9652
|
+
"type": "string",
|
|
9653
|
+
"pattern": "^[A-Z_][A-Z0-9_]*$"
|
|
9654
|
+
}
|
|
9655
|
+
},
|
|
9656
|
+
"min": {
|
|
9657
|
+
"type": "integer",
|
|
9658
|
+
"minimum": 1,
|
|
9659
|
+
"default": 1
|
|
9660
|
+
},
|
|
9661
|
+
"description": { "type": "string" }
|
|
9662
|
+
},
|
|
9663
|
+
"required": ["keys", "min"]
|
|
9664
|
+
},
|
|
9665
|
+
"TemplateVariableValidation": {
|
|
9666
|
+
"type": "object",
|
|
9667
|
+
"additionalProperties": false,
|
|
9668
|
+
"properties": {
|
|
9669
|
+
"pattern": {
|
|
9670
|
+
"type": "string",
|
|
9671
|
+
"minLength": 1
|
|
9672
|
+
},
|
|
9673
|
+
"maxLength": {
|
|
9674
|
+
"type": "integer",
|
|
9675
|
+
"minimum": 1
|
|
9676
|
+
}
|
|
9677
|
+
}
|
|
9678
|
+
},
|
|
9679
|
+
"TemplateVariable": {
|
|
9680
|
+
"type": "object",
|
|
9681
|
+
"additionalProperties": false,
|
|
9682
|
+
"properties": {
|
|
9683
|
+
"key": {
|
|
9684
|
+
"type": "string",
|
|
9685
|
+
"minLength": 1
|
|
9686
|
+
},
|
|
9687
|
+
"prompt": {
|
|
9688
|
+
"type": "string",
|
|
9689
|
+
"minLength": 1
|
|
9690
|
+
},
|
|
9691
|
+
"default": { "type": "string" },
|
|
9692
|
+
"file": {
|
|
9693
|
+
"type": "string",
|
|
9694
|
+
"minLength": 1
|
|
9695
|
+
},
|
|
9696
|
+
"type": {
|
|
9697
|
+
"type": "string",
|
|
9698
|
+
"enum": [
|
|
9699
|
+
"string",
|
|
9700
|
+
"select",
|
|
9701
|
+
"url",
|
|
9702
|
+
"email"
|
|
9703
|
+
],
|
|
9704
|
+
"default": "string"
|
|
9705
|
+
},
|
|
9706
|
+
"options": {
|
|
9707
|
+
"type": "array",
|
|
9708
|
+
"items": {
|
|
9709
|
+
"type": "string",
|
|
9710
|
+
"minLength": 1
|
|
9711
|
+
}
|
|
9712
|
+
},
|
|
9713
|
+
"validation": { "$ref": "#/components/schemas/TemplateVariableValidation" }
|
|
9714
|
+
},
|
|
9715
|
+
"required": [
|
|
9716
|
+
"key",
|
|
9717
|
+
"prompt",
|
|
9718
|
+
"type"
|
|
9719
|
+
]
|
|
9720
|
+
},
|
|
9721
|
+
"TemplateSetup": {
|
|
9722
|
+
"type": "object",
|
|
9723
|
+
"additionalProperties": false,
|
|
9724
|
+
"properties": {
|
|
9725
|
+
"agent": {
|
|
9726
|
+
"type": "string",
|
|
9727
|
+
"minLength": 1
|
|
9728
|
+
},
|
|
9729
|
+
"prompt": {
|
|
9730
|
+
"type": "string",
|
|
9731
|
+
"minLength": 1
|
|
9732
|
+
},
|
|
9733
|
+
"produces": {
|
|
9734
|
+
"type": "array",
|
|
9735
|
+
"items": {
|
|
9736
|
+
"type": "string",
|
|
9737
|
+
"minLength": 1
|
|
9738
|
+
}
|
|
9739
|
+
}
|
|
9740
|
+
},
|
|
9741
|
+
"required": [
|
|
9742
|
+
"agent",
|
|
9743
|
+
"prompt",
|
|
9744
|
+
"produces"
|
|
9745
|
+
]
|
|
9746
|
+
},
|
|
9747
|
+
"TemplateManifest": {
|
|
9748
|
+
"type": "object",
|
|
9749
|
+
"additionalProperties": false,
|
|
9750
|
+
"properties": {
|
|
9751
|
+
"schemaVersion": {
|
|
9752
|
+
"type": "integer",
|
|
9753
|
+
"const": 1
|
|
9754
|
+
},
|
|
9755
|
+
"id": {
|
|
9756
|
+
"type": "string",
|
|
9757
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
9758
|
+
"description": "Stable template slug from the manifest."
|
|
9759
|
+
},
|
|
9760
|
+
"title": {
|
|
9761
|
+
"type": "string",
|
|
9762
|
+
"minLength": 1
|
|
9763
|
+
},
|
|
9764
|
+
"summary": {
|
|
9765
|
+
"type": "string",
|
|
9766
|
+
"minLength": 1
|
|
9767
|
+
},
|
|
9768
|
+
"description": { "type": "string" },
|
|
9769
|
+
"author": { "$ref": "#/components/schemas/TemplateAuthor" },
|
|
9770
|
+
"tags": {
|
|
9771
|
+
"type": "array",
|
|
9772
|
+
"items": {
|
|
9773
|
+
"type": "string",
|
|
9774
|
+
"minLength": 1
|
|
9775
|
+
}
|
|
9776
|
+
},
|
|
9777
|
+
"source": { "$ref": "#/components/schemas/TemplateSource" },
|
|
9778
|
+
"install": { "$ref": "#/components/schemas/TemplateInstall" },
|
|
9779
|
+
"secrets": {
|
|
9780
|
+
"type": "array",
|
|
9781
|
+
"items": { "$ref": "#/components/schemas/TemplateSecret" }
|
|
9782
|
+
},
|
|
9783
|
+
"secretGroups": {
|
|
9784
|
+
"type": "array",
|
|
9785
|
+
"items": { "$ref": "#/components/schemas/TemplateSecretGroup" }
|
|
9786
|
+
},
|
|
9787
|
+
"variables": {
|
|
9788
|
+
"type": "array",
|
|
9789
|
+
"items": { "$ref": "#/components/schemas/TemplateVariable" }
|
|
9790
|
+
},
|
|
9791
|
+
"setup": { "$ref": "#/components/schemas/TemplateSetup" },
|
|
9792
|
+
"postInstall": { "type": "string" }
|
|
9793
|
+
},
|
|
9794
|
+
"required": [
|
|
9795
|
+
"schemaVersion",
|
|
9796
|
+
"id",
|
|
9797
|
+
"title",
|
|
9798
|
+
"summary",
|
|
9799
|
+
"author",
|
|
9800
|
+
"tags",
|
|
9801
|
+
"source",
|
|
9802
|
+
"install",
|
|
9803
|
+
"secrets",
|
|
9804
|
+
"secretGroups",
|
|
9805
|
+
"variables"
|
|
9806
|
+
]
|
|
9807
|
+
},
|
|
9808
|
+
"TemplateRegistryStatus": {
|
|
9809
|
+
"type": "string",
|
|
9810
|
+
"enum": [
|
|
9811
|
+
"pending",
|
|
9812
|
+
"approved",
|
|
9813
|
+
"rejected"
|
|
9814
|
+
]
|
|
9815
|
+
},
|
|
9816
|
+
"TemplateRegistrySummary": {
|
|
9817
|
+
"type": "object",
|
|
9818
|
+
"properties": {
|
|
9819
|
+
"id": {
|
|
9820
|
+
"type": "string",
|
|
9821
|
+
"format": "uuid"
|
|
9822
|
+
},
|
|
9823
|
+
"slug": {
|
|
9824
|
+
"type": "string",
|
|
9825
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
9826
|
+
"description": "Stable template slug used in template URLs and install commands."
|
|
9827
|
+
},
|
|
9828
|
+
"title": { "type": "string" },
|
|
9829
|
+
"summary": { "type": "string" },
|
|
9830
|
+
"author": { "$ref": "#/components/schemas/TemplateAuthor" },
|
|
9831
|
+
"tags": {
|
|
9832
|
+
"type": "array",
|
|
9833
|
+
"items": { "type": "string" }
|
|
9834
|
+
},
|
|
9835
|
+
"verified": { "type": "boolean" },
|
|
9836
|
+
"install_count": {
|
|
9837
|
+
"type": "integer",
|
|
9838
|
+
"minimum": 0
|
|
9839
|
+
},
|
|
9840
|
+
"github_repo": {
|
|
9841
|
+
"type": "string",
|
|
9842
|
+
"pattern": "^[A-Za-z0-9-]+/[A-Za-z0-9_.-]+$",
|
|
9843
|
+
"description": "GitHub repository in owner/repo form."
|
|
9844
|
+
},
|
|
9845
|
+
"created_at": {
|
|
9846
|
+
"type": "string",
|
|
9847
|
+
"format": "date-time"
|
|
9848
|
+
},
|
|
9849
|
+
"updated_at": {
|
|
9850
|
+
"type": "string",
|
|
9851
|
+
"format": "date-time"
|
|
9852
|
+
}
|
|
9853
|
+
},
|
|
9854
|
+
"required": [
|
|
9855
|
+
"id",
|
|
9856
|
+
"slug",
|
|
9857
|
+
"title",
|
|
9858
|
+
"summary",
|
|
9859
|
+
"author",
|
|
9860
|
+
"tags",
|
|
9861
|
+
"verified",
|
|
9862
|
+
"install_count",
|
|
9863
|
+
"github_repo",
|
|
9864
|
+
"created_at",
|
|
9865
|
+
"updated_at"
|
|
9866
|
+
]
|
|
9867
|
+
},
|
|
9868
|
+
"TemplateRegistryDetail": {
|
|
9869
|
+
"type": "object",
|
|
9870
|
+
"properties": {
|
|
9871
|
+
"id": {
|
|
9872
|
+
"type": "string",
|
|
9873
|
+
"format": "uuid"
|
|
9874
|
+
},
|
|
9875
|
+
"slug": {
|
|
9876
|
+
"type": "string",
|
|
9877
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
9878
|
+
"description": "Stable template slug used in template URLs and install commands."
|
|
9879
|
+
},
|
|
9880
|
+
"title": { "type": "string" },
|
|
9881
|
+
"summary": { "type": "string" },
|
|
9882
|
+
"author": { "$ref": "#/components/schemas/TemplateAuthor" },
|
|
9883
|
+
"tags": {
|
|
9884
|
+
"type": "array",
|
|
9885
|
+
"items": { "type": "string" }
|
|
9886
|
+
},
|
|
9887
|
+
"verified": { "type": "boolean" },
|
|
9888
|
+
"install_count": {
|
|
9889
|
+
"type": "integer",
|
|
9890
|
+
"minimum": 0
|
|
9891
|
+
},
|
|
9892
|
+
"github_repo": {
|
|
9893
|
+
"type": "string",
|
|
9894
|
+
"pattern": "^[A-Za-z0-9-]+/[A-Za-z0-9_.-]+$",
|
|
9895
|
+
"description": "GitHub repository in owner/repo form."
|
|
9896
|
+
},
|
|
9897
|
+
"created_at": {
|
|
9898
|
+
"type": "string",
|
|
9899
|
+
"format": "date-time"
|
|
9900
|
+
},
|
|
9901
|
+
"updated_at": {
|
|
9902
|
+
"type": "string",
|
|
9903
|
+
"format": "date-time"
|
|
9904
|
+
},
|
|
9905
|
+
"description": { "type": ["string", "null"] },
|
|
9906
|
+
"github_sha": { "type": "string" },
|
|
9907
|
+
"github_path": { "type": ["string", "null"] },
|
|
9908
|
+
"manifest": { "$ref": "#/components/schemas/TemplateManifest" },
|
|
9909
|
+
"readme": { "type": ["string", "null"] },
|
|
9910
|
+
"status": { "$ref": "#/components/schemas/TemplateRegistryStatus" }
|
|
9911
|
+
},
|
|
9912
|
+
"required": [
|
|
9913
|
+
"id",
|
|
9914
|
+
"slug",
|
|
9915
|
+
"title",
|
|
9916
|
+
"summary",
|
|
9917
|
+
"author",
|
|
9918
|
+
"tags",
|
|
9919
|
+
"verified",
|
|
9920
|
+
"install_count",
|
|
9921
|
+
"github_repo",
|
|
9922
|
+
"created_at",
|
|
9923
|
+
"updated_at",
|
|
9924
|
+
"description",
|
|
9925
|
+
"github_sha",
|
|
9926
|
+
"github_path",
|
|
9927
|
+
"manifest",
|
|
9928
|
+
"readme",
|
|
9929
|
+
"status"
|
|
9930
|
+
]
|
|
9931
|
+
},
|
|
9932
|
+
"TemplateRegistryPage": {
|
|
9933
|
+
"type": "object",
|
|
9934
|
+
"properties": {
|
|
9935
|
+
"items": {
|
|
9936
|
+
"type": "array",
|
|
9937
|
+
"items": { "$ref": "#/components/schemas/TemplateRegistrySummary" }
|
|
9938
|
+
},
|
|
9939
|
+
"next_cursor": {
|
|
9940
|
+
"type": ["string", "null"],
|
|
9941
|
+
"description": "Cursor to pass as the next `cursor` query value, or null when there are no more templates."
|
|
9942
|
+
}
|
|
9943
|
+
},
|
|
9944
|
+
"required": ["items", "next_cursor"]
|
|
9945
|
+
},
|
|
9946
|
+
"InstallTemplateBody": {
|
|
9947
|
+
"type": "object",
|
|
9948
|
+
"additionalProperties": false,
|
|
9949
|
+
"properties": {
|
|
9950
|
+
"address": {
|
|
9951
|
+
"type": "string",
|
|
9952
|
+
"pattern": "^[a-z0-9][a-z0-9._-]{0,63}$",
|
|
9953
|
+
"description": "Localpart to claim on the selected inbound domain. Defaults to the template slug."
|
|
9954
|
+
},
|
|
9955
|
+
"domain": {
|
|
9956
|
+
"type": "string",
|
|
9957
|
+
"minLength": 3,
|
|
9958
|
+
"description": "Org domain name to claim the address on. Defaults to the org's newest active domain."
|
|
9959
|
+
},
|
|
9960
|
+
"variables": {
|
|
9961
|
+
"type": "object",
|
|
9962
|
+
"additionalProperties": { "type": "string" },
|
|
9963
|
+
"description": "Template variable values keyed by manifest variable key."
|
|
9964
|
+
},
|
|
9965
|
+
"secrets": {
|
|
9966
|
+
"type": "object",
|
|
9967
|
+
"additionalProperties": { "type": "string" },
|
|
9968
|
+
"description": "Secret values keyed by manifest secret key."
|
|
9969
|
+
}
|
|
9970
|
+
}
|
|
9971
|
+
},
|
|
9972
|
+
"TemplateInstallState": {
|
|
9973
|
+
"type": "string",
|
|
9974
|
+
"enum": [
|
|
9975
|
+
"deploying",
|
|
9976
|
+
"connecting",
|
|
9977
|
+
"bound",
|
|
9978
|
+
"tested",
|
|
9979
|
+
"deploy_failed",
|
|
9980
|
+
"bind_failed",
|
|
9981
|
+
"test_failed"
|
|
9982
|
+
]
|
|
9983
|
+
},
|
|
9984
|
+
"TemplateInstallStatus": {
|
|
9985
|
+
"type": "object",
|
|
9986
|
+
"properties": {
|
|
9987
|
+
"id": {
|
|
9988
|
+
"type": "string",
|
|
9989
|
+
"format": "uuid"
|
|
9990
|
+
},
|
|
9991
|
+
"template_slug": {
|
|
9992
|
+
"type": "string",
|
|
9993
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
9994
|
+
"description": "Template slug for this install."
|
|
9995
|
+
},
|
|
9996
|
+
"state": { "$ref": "#/components/schemas/TemplateInstallState" },
|
|
9997
|
+
"address": { "type": ["string", "null"] },
|
|
9998
|
+
"function_id": {
|
|
9999
|
+
"type": ["string", "null"],
|
|
10000
|
+
"format": "uuid"
|
|
10001
|
+
},
|
|
10002
|
+
"error": { "type": ["string", "null"] },
|
|
10003
|
+
"created_at": {
|
|
10004
|
+
"type": "string",
|
|
10005
|
+
"format": "date-time"
|
|
10006
|
+
},
|
|
10007
|
+
"updated_at": {
|
|
10008
|
+
"type": "string",
|
|
10009
|
+
"format": "date-time"
|
|
10010
|
+
}
|
|
10011
|
+
},
|
|
10012
|
+
"required": [
|
|
10013
|
+
"id",
|
|
10014
|
+
"template_slug",
|
|
10015
|
+
"state",
|
|
10016
|
+
"address",
|
|
10017
|
+
"function_id",
|
|
10018
|
+
"error",
|
|
10019
|
+
"created_at",
|
|
10020
|
+
"updated_at"
|
|
10021
|
+
]
|
|
10022
|
+
}
|
|
10023
|
+
}
|
|
10024
|
+
}
|
|
10025
|
+
};
|
|
10026
|
+
//#endregion
|
|
10027
|
+
//#region ../packages/api-core/src/openapi/operations.generated.ts
|
|
10028
|
+
const operationManifest = [
|
|
10029
|
+
{
|
|
10030
|
+
"binaryResponse": false,
|
|
10031
|
+
"bodyRequired": false,
|
|
10032
|
+
"command": "get-account",
|
|
10033
|
+
"description": null,
|
|
10034
|
+
"hasJsonBody": false,
|
|
10035
|
+
"method": "GET",
|
|
10036
|
+
"operationId": "getAccount",
|
|
10037
|
+
"path": "/account",
|
|
10038
|
+
"pathParams": [],
|
|
10039
|
+
"queryParams": [],
|
|
10040
|
+
"requestSchema": null,
|
|
10041
|
+
"responseSchema": {
|
|
10042
|
+
"type": "object",
|
|
10043
|
+
"properties": {
|
|
10044
|
+
"id": {
|
|
10045
|
+
"type": "string",
|
|
10046
|
+
"format": "uuid"
|
|
10047
|
+
},
|
|
10048
|
+
"email": { "type": "string" },
|
|
10049
|
+
"plan": { "type": "string" },
|
|
10050
|
+
"limits": {
|
|
10051
|
+
"type": "object",
|
|
10052
|
+
"description": "Plan-derived quota limits for an account.",
|
|
10053
|
+
"properties": {
|
|
10054
|
+
"storage_mb": { "type": "number" },
|
|
10055
|
+
"send_per_hour": { "type": "number" },
|
|
10056
|
+
"send_per_day": { "type": "number" },
|
|
10057
|
+
"api_per_minute": { "type": "number" },
|
|
10058
|
+
"webhooks_max_global": { "type": ["number", "null"] },
|
|
10059
|
+
"webhooks_per_domain": { "type": "boolean" },
|
|
10060
|
+
"filters_per_domain": { "type": "boolean" },
|
|
10061
|
+
"spam_thresholds_per_domain": { "type": "boolean" }
|
|
10062
|
+
},
|
|
10063
|
+
"required": [
|
|
10064
|
+
"storage_mb",
|
|
10065
|
+
"send_per_hour",
|
|
10066
|
+
"send_per_day",
|
|
10067
|
+
"api_per_minute",
|
|
10068
|
+
"webhooks_max_global",
|
|
10069
|
+
"webhooks_per_domain",
|
|
10070
|
+
"filters_per_domain",
|
|
10071
|
+
"spam_thresholds_per_domain"
|
|
10072
|
+
]
|
|
10073
|
+
},
|
|
10074
|
+
"entitlements": {
|
|
10075
|
+
"type": "array",
|
|
10076
|
+
"items": { "type": "string" },
|
|
10077
|
+
"description": "Granted org entitlement keys (sorted). A headless caller reads its\ncapabilities here — e.g. an emailless agent seeing only\n[\"send_mail\", \"send_to_known_addresses\"] knows it is reply-only.\n"
|
|
10078
|
+
},
|
|
10079
|
+
"managed_inbox_address": {
|
|
10080
|
+
"type": ["string", "null"],
|
|
10081
|
+
"description": "The managed inbox FQDN to reply as, or null if the org has no managed inbox."
|
|
10082
|
+
},
|
|
10083
|
+
"created_at": {
|
|
10084
|
+
"type": "string",
|
|
10085
|
+
"format": "date-time"
|
|
10086
|
+
},
|
|
10087
|
+
"onboarding_completed": { "type": "boolean" },
|
|
9403
10088
|
"onboarding_step": { "type": ["string", "null"] },
|
|
9404
10089
|
"stripe_subscription_status": { "type": ["string", "null"] },
|
|
9405
10090
|
"subscription_current_period_end": {
|
|
@@ -18577,7 +19262,245 @@ const operationManifest = [
|
|
|
18577
19262
|
"required": ["filename", "content_base64"]
|
|
18578
19263
|
}
|
|
18579
19264
|
}
|
|
18580
|
-
}
|
|
19265
|
+
}
|
|
19266
|
+
},
|
|
19267
|
+
"responseSchema": {
|
|
19268
|
+
"type": "object",
|
|
19269
|
+
"properties": {
|
|
19270
|
+
"id": {
|
|
19271
|
+
"type": "string",
|
|
19272
|
+
"description": "Persisted sent-email attempt ID."
|
|
19273
|
+
},
|
|
19274
|
+
"status": {
|
|
19275
|
+
"type": "string",
|
|
19276
|
+
"description": "Lifecycle status of a sent_emails row. Possible values:\n\n - `queued`: pre-call INSERT; the outbound agent has not\n yet replied.\n - `submitted_to_agent`: agent accepted; `queue_id` is set.\n - `agent_failed`: agent rejected; `error_code` and\n `error_message` carry the reason.\n - `gate_denied`: a recipient-scope gate denied the send;\n the agent was never called. The `gates` array carries\n the denial detail. /send-mail returns 403 in this case\n so callers see the denial synchronously; /sent-emails\n additionally records the row for historical lookup,\n which is when this status appears in a listing.\n - `unknown`: terminal indeterminate; the on-box log\n poller couldn't classify the receiver's response.\n - `delivered` / `bounced` / `deferred` / `wait_timeout`:\n terminal delivery outcomes (see DeliveryStatus).\n",
|
|
19277
|
+
"enum": [
|
|
19278
|
+
"queued",
|
|
19279
|
+
"submitted_to_agent",
|
|
19280
|
+
"agent_failed",
|
|
19281
|
+
"gate_denied",
|
|
19282
|
+
"unknown",
|
|
19283
|
+
"delivered",
|
|
19284
|
+
"bounced",
|
|
19285
|
+
"deferred",
|
|
19286
|
+
"wait_timeout"
|
|
19287
|
+
]
|
|
19288
|
+
},
|
|
19289
|
+
"from": {
|
|
19290
|
+
"type": "string",
|
|
19291
|
+
"description": "Bare from-address actually written on the wire. Echoed\non every success branch so callers can confirm what\nwent out, particularly useful for the /emails/{id}/reply\npath where `from` is server-derived from the inbound's\nrecipient when the caller doesn't override.\n\nFor sends where the caller passed a from-header that\nincluded a display name (e.g. `\"Acme Support\" <support@acme.test>`),\nthis field is the parsed bare address (`support@acme.test`).\nThe display name was sent on the wire intact; this field\njust makes the address easy to compare against allowlists.\n"
|
|
19292
|
+
},
|
|
19293
|
+
"queue_id": {
|
|
19294
|
+
"type": ["string", "null"],
|
|
19295
|
+
"description": "Message identifier assigned by Primitive's OUTBOUND relay\n(the box that signs your mail and submits it to the\nreceiving MTA). NOT the receiver's queue id.\n\nThe receiver may also report its own queue id in\n`smtp_response_text` (e.g. `\"250 2.0.0 Ok: queued as\n99D111927CDA\"` from a Postfix receiver). Those two ids\nrefer to different mail systems and are NOT comparable.\nTreat `queue_id` as Primitive-internal and the\nreceiver's id as remote-system-internal.\n\nNull on rows that never reached the relay (queued,\ngate_denied, agent_failed before signing).\n"
|
|
19296
|
+
},
|
|
19297
|
+
"accepted": {
|
|
19298
|
+
"type": "array",
|
|
19299
|
+
"items": { "type": "string" },
|
|
19300
|
+
"description": "Recipient addresses accepted by the relay."
|
|
19301
|
+
},
|
|
19302
|
+
"rejected": {
|
|
19303
|
+
"type": "array",
|
|
19304
|
+
"items": { "type": "string" },
|
|
19305
|
+
"description": "Recipient addresses rejected by the relay."
|
|
19306
|
+
},
|
|
19307
|
+
"client_idempotency_key": {
|
|
19308
|
+
"type": "string",
|
|
19309
|
+
"description": "Effective idempotency key used for this send."
|
|
19310
|
+
},
|
|
19311
|
+
"request_id": {
|
|
19312
|
+
"type": "string",
|
|
19313
|
+
"description": "Server-issued request identifier for support and tracing."
|
|
19314
|
+
},
|
|
19315
|
+
"content_hash": {
|
|
19316
|
+
"type": "string",
|
|
19317
|
+
"description": "Stable hash of the canonical send payload."
|
|
19318
|
+
},
|
|
19319
|
+
"delivery_status": {
|
|
19320
|
+
"type": "string",
|
|
19321
|
+
"description": "Narrower enum covering only the four terminal delivery\noutcomes returned to a synchronous `wait: true` send.\n\nOn the SendMailResult shape, `delivery_status` is always\nequal to `status` whenever both are present (i.e. on\nterminal-state replays and live wait=true responses).\nThe two fields exist so callers that want to type-narrow\non \"this is a delivery outcome\" can pattern-match against\nthe four-value enum without handling the broader\nSentEmailStatus value set (which also covers `queued`,\n`submitted_to_agent`, `agent_failed`, `gate_denied`,\n`unknown`).\n\nOn async-mode and pre-terminal responses, `delivery_status`\nis absent and only `status` is populated. Use `status` if\nyou want a single field that's always present.\n",
|
|
19322
|
+
"enum": [
|
|
19323
|
+
"delivered",
|
|
19324
|
+
"bounced",
|
|
19325
|
+
"deferred",
|
|
19326
|
+
"wait_timeout"
|
|
19327
|
+
]
|
|
19328
|
+
},
|
|
19329
|
+
"smtp_response_code": {
|
|
19330
|
+
"type": ["integer", "null"],
|
|
19331
|
+
"description": "SMTP response code from the first downstream delivery outcome when wait is true."
|
|
19332
|
+
},
|
|
19333
|
+
"smtp_response_text": {
|
|
19334
|
+
"type": "string",
|
|
19335
|
+
"description": "SMTP response text from the first downstream delivery outcome when wait is true."
|
|
19336
|
+
},
|
|
19337
|
+
"idempotent_replay": {
|
|
19338
|
+
"type": "boolean",
|
|
19339
|
+
"description": "True when the response replays a previously-recorded send\nkeyed by `client_idempotency_key` (same key, same canonical\npayload). False on a fresh send and on gate-denied\nresponses. Lets callers branch on cache state without\ndiffing fields.\n"
|
|
19340
|
+
}
|
|
19341
|
+
},
|
|
19342
|
+
"required": [
|
|
19343
|
+
"id",
|
|
19344
|
+
"status",
|
|
19345
|
+
"from",
|
|
19346
|
+
"queue_id",
|
|
19347
|
+
"accepted",
|
|
19348
|
+
"rejected",
|
|
19349
|
+
"client_idempotency_key",
|
|
19350
|
+
"request_id",
|
|
19351
|
+
"content_hash",
|
|
19352
|
+
"idempotent_replay"
|
|
19353
|
+
]
|
|
19354
|
+
},
|
|
19355
|
+
"sdkName": "replyToEmail",
|
|
19356
|
+
"summary": "Reply to an inbound email",
|
|
19357
|
+
"tag": "Sending",
|
|
19358
|
+
"tagCommand": "sending"
|
|
19359
|
+
},
|
|
19360
|
+
{
|
|
19361
|
+
"binaryResponse": false,
|
|
19362
|
+
"bodyRequired": true,
|
|
19363
|
+
"command": "send-email",
|
|
19364
|
+
"description": "Sends an outbound email through Primitive's outbound relay. By default\nthe request returns once the relay accepts the message for delivery.\nSet `wait: true` to wait for the first downstream SMTP delivery outcome.\n\n**Host routing.** /send-mail is served by the canonical API host\n(`https://api.primitive.dev/v1`) so the request body can carry\ninline attachments up to ~30 MiB raw. The legacy dashboard\ncompatibility host (`https://www.primitive.dev/api/v1`) also accepts\n/send-mail, but Vercel request body limits apply before proxying.\nThe typed SDKs route /send-mail to the canonical API host\nautomatically.\n",
|
|
19365
|
+
"hasJsonBody": true,
|
|
19366
|
+
"method": "POST",
|
|
19367
|
+
"operationId": "sendEmail",
|
|
19368
|
+
"path": "/send-mail",
|
|
19369
|
+
"pathParams": [],
|
|
19370
|
+
"queryParams": [],
|
|
19371
|
+
"requestSchema": {
|
|
19372
|
+
"type": "object",
|
|
19373
|
+
"additionalProperties": false,
|
|
19374
|
+
"properties": {
|
|
19375
|
+
"from": {
|
|
19376
|
+
"type": "string",
|
|
19377
|
+
"minLength": 3,
|
|
19378
|
+
"maxLength": 998,
|
|
19379
|
+
"description": "RFC 5322 From header. The sender domain must be a verified outbound domain for your organization."
|
|
19380
|
+
},
|
|
19381
|
+
"to": {
|
|
19382
|
+
"type": "string",
|
|
19383
|
+
"minLength": 3,
|
|
19384
|
+
"maxLength": 320,
|
|
19385
|
+
"description": "Recipient address. Recipient eligibility depends on your account's outbound entitlements."
|
|
19386
|
+
},
|
|
19387
|
+
"subject": {
|
|
19388
|
+
"type": "string",
|
|
19389
|
+
"minLength": 1,
|
|
19390
|
+
"maxLength": 998,
|
|
19391
|
+
"description": "Subject line for the outbound message"
|
|
19392
|
+
},
|
|
19393
|
+
"body_text": {
|
|
19394
|
+
"type": "string",
|
|
19395
|
+
"description": "Plain-text message body. At least one of body_text or body_html is required. The combined UTF-8 byte length of body_text and body_html must be at most 262144 bytes."
|
|
19396
|
+
},
|
|
19397
|
+
"body_html": {
|
|
19398
|
+
"type": "string",
|
|
19399
|
+
"description": "HTML message body. At least one of body_text or body_html is required. The combined UTF-8 byte length of body_text and body_html must be at most 262144 bytes."
|
|
19400
|
+
},
|
|
19401
|
+
"in_reply_to": {
|
|
19402
|
+
"type": "string",
|
|
19403
|
+
"minLength": 1,
|
|
19404
|
+
"maxLength": 998,
|
|
19405
|
+
"pattern": "^[^\\x00-\\x1F\\x7F]+$",
|
|
19406
|
+
"description": "Message-ID of the direct parent email when sending a threaded reply."
|
|
19407
|
+
},
|
|
19408
|
+
"references": {
|
|
19409
|
+
"type": "array",
|
|
19410
|
+
"maxItems": 100,
|
|
19411
|
+
"description": "Full ordered message-id chain for the thread.",
|
|
19412
|
+
"items": {
|
|
19413
|
+
"type": "string",
|
|
19414
|
+
"minLength": 1,
|
|
19415
|
+
"maxLength": 998,
|
|
19416
|
+
"pattern": "^[^\\x00-\\x1F\\x7F]+$"
|
|
19417
|
+
}
|
|
19418
|
+
},
|
|
19419
|
+
"attachments": {
|
|
19420
|
+
"type": "array",
|
|
19421
|
+
"maxItems": 100,
|
|
19422
|
+
"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.",
|
|
19423
|
+
"items": {
|
|
19424
|
+
"type": "object",
|
|
19425
|
+
"additionalProperties": false,
|
|
19426
|
+
"properties": {
|
|
19427
|
+
"filename": {
|
|
19428
|
+
"type": "string",
|
|
19429
|
+
"minLength": 1,
|
|
19430
|
+
"maxLength": 255,
|
|
19431
|
+
"description": "Attachment filename. Control characters are rejected."
|
|
19432
|
+
},
|
|
19433
|
+
"content_type": {
|
|
19434
|
+
"type": "string",
|
|
19435
|
+
"minLength": 1,
|
|
19436
|
+
"maxLength": 255,
|
|
19437
|
+
"description": "Optional MIME content type. Control characters are rejected."
|
|
19438
|
+
},
|
|
19439
|
+
"content_base64": {
|
|
19440
|
+
"type": "string",
|
|
19441
|
+
"minLength": 1,
|
|
19442
|
+
"maxLength": 44040192,
|
|
19443
|
+
"description": "Base64-encoded attachment bytes."
|
|
19444
|
+
}
|
|
19445
|
+
},
|
|
19446
|
+
"required": ["filename", "content_base64"]
|
|
19447
|
+
}
|
|
19448
|
+
},
|
|
19449
|
+
"payload_attachments": {
|
|
19450
|
+
"type": "array",
|
|
19451
|
+
"maxItems": 1,
|
|
19452
|
+
"description": "Deliver an already-uploaded Primitive Payloads object as an attachment by reference, without inlining the bytes — the way to send attachments larger than the inline cap. Upload the object via /v1/payloads (client-held CEK), then reference it here. v1 supports at most one.",
|
|
19453
|
+
"items": {
|
|
19454
|
+
"type": "object",
|
|
19455
|
+
"additionalProperties": false,
|
|
19456
|
+
"description": "A reference to an already-uploaded Primitive Payloads object, delivered as an attachment without inlining the bytes — the way to send an attachment larger than the inline cap. Upload the object via /v1/payloads (with a client-held CEK the server never sees), then reference it here.",
|
|
19457
|
+
"properties": {
|
|
19458
|
+
"root": {
|
|
19459
|
+
"type": "string",
|
|
19460
|
+
"pattern": "^[0-9a-f]{64}$",
|
|
19461
|
+
"description": "The 64-char lowercase-hex Merkle root of a finalized payloads object."
|
|
19462
|
+
},
|
|
19463
|
+
"filename": {
|
|
19464
|
+
"type": "string",
|
|
19465
|
+
"minLength": 1,
|
|
19466
|
+
"maxLength": 255,
|
|
19467
|
+
"description": "Attachment filename presented to the recipient."
|
|
19468
|
+
},
|
|
19469
|
+
"content_type": {
|
|
19470
|
+
"type": "string",
|
|
19471
|
+
"minLength": 1,
|
|
19472
|
+
"maxLength": 255,
|
|
19473
|
+
"description": "Optional MIME content type."
|
|
19474
|
+
},
|
|
19475
|
+
"cek": {
|
|
19476
|
+
"type": "string",
|
|
19477
|
+
"pattern": "^[A-Za-z0-9_-]{1,128}$",
|
|
19478
|
+
"description": "Base64url-encoded (unpadded) content-encryption key the recipient uses to decrypt. Travels with the email; the object store only ever holds ciphertext."
|
|
19479
|
+
}
|
|
19480
|
+
},
|
|
19481
|
+
"required": [
|
|
19482
|
+
"root",
|
|
19483
|
+
"filename",
|
|
19484
|
+
"cek"
|
|
19485
|
+
]
|
|
19486
|
+
}
|
|
19487
|
+
},
|
|
19488
|
+
"wait": {
|
|
19489
|
+
"type": "boolean",
|
|
19490
|
+
"description": "When true, wait for the first downstream SMTP delivery outcome before returning."
|
|
19491
|
+
},
|
|
19492
|
+
"wait_timeout_ms": {
|
|
19493
|
+
"type": "integer",
|
|
19494
|
+
"minimum": 1e3,
|
|
19495
|
+
"maximum": 3e4,
|
|
19496
|
+
"description": "Maximum time to wait for a delivery outcome when wait is true. Defaults to 30000."
|
|
19497
|
+
}
|
|
19498
|
+
},
|
|
19499
|
+
"required": [
|
|
19500
|
+
"from",
|
|
19501
|
+
"to",
|
|
19502
|
+
"subject"
|
|
19503
|
+
]
|
|
18581
19504
|
},
|
|
18582
19505
|
"responseSchema": {
|
|
18583
19506
|
"type": "object",
|
|
@@ -18667,209 +19590,671 @@ const operationManifest = [
|
|
|
18667
19590
|
"idempotent_replay"
|
|
18668
19591
|
]
|
|
18669
19592
|
},
|
|
18670
|
-
"sdkName": "
|
|
18671
|
-
"summary": "
|
|
19593
|
+
"sdkName": "sendEmail",
|
|
19594
|
+
"summary": "Send outbound email",
|
|
18672
19595
|
"tag": "Sending",
|
|
18673
19596
|
"tagCommand": "sending"
|
|
18674
19597
|
},
|
|
18675
19598
|
{
|
|
18676
19599
|
"binaryResponse": false,
|
|
18677
|
-
"bodyRequired":
|
|
18678
|
-
"command": "
|
|
18679
|
-
"description": "
|
|
18680
|
-
"hasJsonBody":
|
|
18681
|
-
"method": "
|
|
18682
|
-
"operationId": "
|
|
18683
|
-
"path": "/
|
|
18684
|
-
"pathParams": [
|
|
19600
|
+
"bodyRequired": false,
|
|
19601
|
+
"command": "get-template",
|
|
19602
|
+
"description": "Fetch one approved Function template by slug, including its manifest\nsnapshot and README. The stored source files used for install are not\nreturned.\n",
|
|
19603
|
+
"hasJsonBody": false,
|
|
19604
|
+
"method": "GET",
|
|
19605
|
+
"operationId": "getTemplate",
|
|
19606
|
+
"path": "/templates/{id}",
|
|
19607
|
+
"pathParams": [{
|
|
19608
|
+
"description": "Template slug from the template manifest.",
|
|
19609
|
+
"enum": null,
|
|
19610
|
+
"name": "id",
|
|
19611
|
+
"required": true,
|
|
19612
|
+
"type": "string"
|
|
19613
|
+
}],
|
|
18685
19614
|
"queryParams": [],
|
|
18686
|
-
"requestSchema":
|
|
19615
|
+
"requestSchema": null,
|
|
19616
|
+
"responseSchema": {
|
|
18687
19617
|
"type": "object",
|
|
18688
|
-
"additionalProperties": false,
|
|
18689
19618
|
"properties": {
|
|
18690
|
-
"
|
|
19619
|
+
"id": {
|
|
18691
19620
|
"type": "string",
|
|
18692
|
-
"
|
|
18693
|
-
"maxLength": 998,
|
|
18694
|
-
"description": "RFC 5322 From header. The sender domain must be a verified outbound domain for your organization."
|
|
19621
|
+
"format": "uuid"
|
|
18695
19622
|
},
|
|
18696
|
-
"
|
|
19623
|
+
"slug": {
|
|
18697
19624
|
"type": "string",
|
|
18698
|
-
"
|
|
18699
|
-
"
|
|
18700
|
-
"description": "Recipient address. Recipient eligibility depends on your account's outbound entitlements."
|
|
19625
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
19626
|
+
"description": "Stable template slug used in template URLs and install commands."
|
|
18701
19627
|
},
|
|
18702
|
-
"
|
|
18703
|
-
|
|
18704
|
-
|
|
18705
|
-
"
|
|
18706
|
-
"
|
|
19628
|
+
"title": { "type": "string" },
|
|
19629
|
+
"summary": { "type": "string" },
|
|
19630
|
+
"author": {
|
|
19631
|
+
"type": "object",
|
|
19632
|
+
"additionalProperties": false,
|
|
19633
|
+
"properties": {
|
|
19634
|
+
"id": {
|
|
19635
|
+
"type": "string",
|
|
19636
|
+
"minLength": 1
|
|
19637
|
+
},
|
|
19638
|
+
"name": {
|
|
19639
|
+
"type": "string",
|
|
19640
|
+
"minLength": 1
|
|
19641
|
+
},
|
|
19642
|
+
"url": {
|
|
19643
|
+
"type": "string",
|
|
19644
|
+
"format": "uri"
|
|
19645
|
+
}
|
|
19646
|
+
},
|
|
19647
|
+
"required": ["id", "name"]
|
|
18707
19648
|
},
|
|
18708
|
-
"
|
|
18709
|
-
"type": "
|
|
18710
|
-
"
|
|
19649
|
+
"tags": {
|
|
19650
|
+
"type": "array",
|
|
19651
|
+
"items": { "type": "string" }
|
|
18711
19652
|
},
|
|
18712
|
-
"
|
|
19653
|
+
"verified": { "type": "boolean" },
|
|
19654
|
+
"install_count": {
|
|
19655
|
+
"type": "integer",
|
|
19656
|
+
"minimum": 0
|
|
19657
|
+
},
|
|
19658
|
+
"github_repo": {
|
|
18713
19659
|
"type": "string",
|
|
18714
|
-
"
|
|
19660
|
+
"pattern": "^[A-Za-z0-9-]+/[A-Za-z0-9_.-]+$",
|
|
19661
|
+
"description": "GitHub repository in owner/repo form."
|
|
18715
19662
|
},
|
|
18716
|
-
"
|
|
19663
|
+
"created_at": {
|
|
18717
19664
|
"type": "string",
|
|
18718
|
-
"
|
|
18719
|
-
"maxLength": 998,
|
|
18720
|
-
"pattern": "^[^\\x00-\\x1F\\x7F]+$",
|
|
18721
|
-
"description": "Message-ID of the direct parent email when sending a threaded reply."
|
|
19665
|
+
"format": "date-time"
|
|
18722
19666
|
},
|
|
18723
|
-
"
|
|
18724
|
-
"type": "
|
|
18725
|
-
"
|
|
18726
|
-
"description": "Full ordered message-id chain for the thread.",
|
|
18727
|
-
"items": {
|
|
18728
|
-
"type": "string",
|
|
18729
|
-
"minLength": 1,
|
|
18730
|
-
"maxLength": 998,
|
|
18731
|
-
"pattern": "^[^\\x00-\\x1F\\x7F]+$"
|
|
18732
|
-
}
|
|
19667
|
+
"updated_at": {
|
|
19668
|
+
"type": "string",
|
|
19669
|
+
"format": "date-time"
|
|
18733
19670
|
},
|
|
18734
|
-
"
|
|
18735
|
-
|
|
18736
|
-
|
|
18737
|
-
|
|
18738
|
-
"
|
|
18739
|
-
|
|
18740
|
-
|
|
18741
|
-
"
|
|
18742
|
-
"
|
|
18743
|
-
|
|
18744
|
-
|
|
18745
|
-
|
|
18746
|
-
|
|
19671
|
+
"description": { "type": ["string", "null"] },
|
|
19672
|
+
"github_sha": { "type": "string" },
|
|
19673
|
+
"github_path": { "type": ["string", "null"] },
|
|
19674
|
+
"manifest": {
|
|
19675
|
+
"type": "object",
|
|
19676
|
+
"additionalProperties": false,
|
|
19677
|
+
"properties": {
|
|
19678
|
+
"schemaVersion": {
|
|
19679
|
+
"type": "integer",
|
|
19680
|
+
"const": 1
|
|
19681
|
+
},
|
|
19682
|
+
"id": {
|
|
19683
|
+
"type": "string",
|
|
19684
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
19685
|
+
"description": "Stable template slug from the manifest."
|
|
19686
|
+
},
|
|
19687
|
+
"title": {
|
|
19688
|
+
"type": "string",
|
|
19689
|
+
"minLength": 1
|
|
19690
|
+
},
|
|
19691
|
+
"summary": {
|
|
19692
|
+
"type": "string",
|
|
19693
|
+
"minLength": 1
|
|
19694
|
+
},
|
|
19695
|
+
"description": { "type": "string" },
|
|
19696
|
+
"author": {
|
|
19697
|
+
"type": "object",
|
|
19698
|
+
"additionalProperties": false,
|
|
19699
|
+
"properties": {
|
|
19700
|
+
"id": {
|
|
19701
|
+
"type": "string",
|
|
19702
|
+
"minLength": 1
|
|
19703
|
+
},
|
|
19704
|
+
"name": {
|
|
19705
|
+
"type": "string",
|
|
19706
|
+
"minLength": 1
|
|
19707
|
+
},
|
|
19708
|
+
"url": {
|
|
19709
|
+
"type": "string",
|
|
19710
|
+
"format": "uri"
|
|
19711
|
+
}
|
|
18747
19712
|
},
|
|
18748
|
-
"
|
|
19713
|
+
"required": ["id", "name"]
|
|
19714
|
+
},
|
|
19715
|
+
"tags": {
|
|
19716
|
+
"type": "array",
|
|
19717
|
+
"items": {
|
|
18749
19718
|
"type": "string",
|
|
18750
|
-
"minLength": 1
|
|
18751
|
-
|
|
18752
|
-
|
|
19719
|
+
"minLength": 1
|
|
19720
|
+
}
|
|
19721
|
+
},
|
|
19722
|
+
"source": { "oneOf": [{
|
|
19723
|
+
"type": "object",
|
|
19724
|
+
"additionalProperties": false,
|
|
19725
|
+
"properties": {
|
|
19726
|
+
"mode": {
|
|
19727
|
+
"type": "string",
|
|
19728
|
+
"const": "managed-build"
|
|
19729
|
+
},
|
|
19730
|
+
"dir": {
|
|
19731
|
+
"type": "string",
|
|
19732
|
+
"minLength": 1,
|
|
19733
|
+
"default": "."
|
|
19734
|
+
}
|
|
18753
19735
|
},
|
|
18754
|
-
"
|
|
18755
|
-
|
|
18756
|
-
|
|
18757
|
-
|
|
18758
|
-
|
|
19736
|
+
"required": ["mode", "dir"]
|
|
19737
|
+
}, {
|
|
19738
|
+
"type": "object",
|
|
19739
|
+
"additionalProperties": false,
|
|
19740
|
+
"properties": {
|
|
19741
|
+
"mode": {
|
|
19742
|
+
"type": "string",
|
|
19743
|
+
"const": "bundle"
|
|
19744
|
+
},
|
|
19745
|
+
"file": {
|
|
19746
|
+
"type": "string",
|
|
19747
|
+
"minLength": 1
|
|
19748
|
+
}
|
|
19749
|
+
},
|
|
19750
|
+
"required": ["mode", "file"]
|
|
19751
|
+
}] },
|
|
19752
|
+
"install": {
|
|
19753
|
+
"type": "object",
|
|
19754
|
+
"additionalProperties": false,
|
|
19755
|
+
"properties": {
|
|
19756
|
+
"mode": {
|
|
19757
|
+
"type": "string",
|
|
19758
|
+
"enum": ["deploy", "scaffold"]
|
|
19759
|
+
},
|
|
19760
|
+
"editFiles": {
|
|
19761
|
+
"type": "array",
|
|
19762
|
+
"items": {
|
|
19763
|
+
"type": "string",
|
|
19764
|
+
"minLength": 1
|
|
19765
|
+
}
|
|
19766
|
+
},
|
|
19767
|
+
"reason": {
|
|
19768
|
+
"type": "string",
|
|
19769
|
+
"default": ""
|
|
19770
|
+
}
|
|
19771
|
+
},
|
|
19772
|
+
"required": [
|
|
19773
|
+
"mode",
|
|
19774
|
+
"editFiles",
|
|
19775
|
+
"reason"
|
|
19776
|
+
]
|
|
19777
|
+
},
|
|
19778
|
+
"secrets": {
|
|
19779
|
+
"type": "array",
|
|
19780
|
+
"items": {
|
|
19781
|
+
"type": "object",
|
|
19782
|
+
"additionalProperties": false,
|
|
19783
|
+
"properties": {
|
|
19784
|
+
"key": {
|
|
19785
|
+
"type": "string",
|
|
19786
|
+
"pattern": "^[A-Z_][A-Z0-9_]*$"
|
|
19787
|
+
},
|
|
19788
|
+
"required": {
|
|
19789
|
+
"type": "boolean",
|
|
19790
|
+
"default": true
|
|
19791
|
+
},
|
|
19792
|
+
"description": { "type": "string" }
|
|
19793
|
+
},
|
|
19794
|
+
"required": ["key", "required"]
|
|
18759
19795
|
}
|
|
18760
19796
|
},
|
|
18761
|
-
"
|
|
18762
|
-
|
|
18763
|
-
|
|
18764
|
-
|
|
18765
|
-
|
|
18766
|
-
|
|
18767
|
-
|
|
18768
|
-
|
|
18769
|
-
|
|
18770
|
-
|
|
18771
|
-
|
|
18772
|
-
|
|
19797
|
+
"secretGroups": {
|
|
19798
|
+
"type": "array",
|
|
19799
|
+
"items": {
|
|
19800
|
+
"type": "object",
|
|
19801
|
+
"additionalProperties": false,
|
|
19802
|
+
"properties": {
|
|
19803
|
+
"keys": {
|
|
19804
|
+
"type": "array",
|
|
19805
|
+
"minItems": 2,
|
|
19806
|
+
"items": {
|
|
19807
|
+
"type": "string",
|
|
19808
|
+
"pattern": "^[A-Z_][A-Z0-9_]*$"
|
|
19809
|
+
}
|
|
19810
|
+
},
|
|
19811
|
+
"min": {
|
|
19812
|
+
"type": "integer",
|
|
19813
|
+
"minimum": 1,
|
|
19814
|
+
"default": 1
|
|
19815
|
+
},
|
|
19816
|
+
"description": { "type": "string" }
|
|
19817
|
+
},
|
|
19818
|
+
"required": ["keys", "min"]
|
|
19819
|
+
}
|
|
19820
|
+
},
|
|
19821
|
+
"variables": {
|
|
19822
|
+
"type": "array",
|
|
19823
|
+
"items": {
|
|
19824
|
+
"type": "object",
|
|
19825
|
+
"additionalProperties": false,
|
|
19826
|
+
"properties": {
|
|
19827
|
+
"key": {
|
|
19828
|
+
"type": "string",
|
|
19829
|
+
"minLength": 1
|
|
19830
|
+
},
|
|
19831
|
+
"prompt": {
|
|
19832
|
+
"type": "string",
|
|
19833
|
+
"minLength": 1
|
|
19834
|
+
},
|
|
19835
|
+
"default": { "type": "string" },
|
|
19836
|
+
"file": {
|
|
19837
|
+
"type": "string",
|
|
19838
|
+
"minLength": 1
|
|
19839
|
+
},
|
|
19840
|
+
"type": {
|
|
19841
|
+
"type": "string",
|
|
19842
|
+
"enum": [
|
|
19843
|
+
"string",
|
|
19844
|
+
"select",
|
|
19845
|
+
"url",
|
|
19846
|
+
"email"
|
|
19847
|
+
],
|
|
19848
|
+
"default": "string"
|
|
19849
|
+
},
|
|
19850
|
+
"options": {
|
|
19851
|
+
"type": "array",
|
|
19852
|
+
"items": {
|
|
19853
|
+
"type": "string",
|
|
19854
|
+
"minLength": 1
|
|
19855
|
+
}
|
|
19856
|
+
},
|
|
19857
|
+
"validation": {
|
|
19858
|
+
"type": "object",
|
|
19859
|
+
"additionalProperties": false,
|
|
19860
|
+
"properties": {
|
|
19861
|
+
"pattern": {
|
|
19862
|
+
"type": "string",
|
|
19863
|
+
"minLength": 1
|
|
19864
|
+
},
|
|
19865
|
+
"maxLength": {
|
|
19866
|
+
"type": "integer",
|
|
19867
|
+
"minimum": 1
|
|
19868
|
+
}
|
|
19869
|
+
}
|
|
19870
|
+
}
|
|
19871
|
+
},
|
|
19872
|
+
"required": [
|
|
19873
|
+
"key",
|
|
19874
|
+
"prompt",
|
|
19875
|
+
"type"
|
|
19876
|
+
]
|
|
19877
|
+
}
|
|
19878
|
+
},
|
|
19879
|
+
"setup": {
|
|
19880
|
+
"type": "object",
|
|
19881
|
+
"additionalProperties": false,
|
|
19882
|
+
"properties": {
|
|
19883
|
+
"agent": {
|
|
19884
|
+
"type": "string",
|
|
19885
|
+
"minLength": 1
|
|
19886
|
+
},
|
|
19887
|
+
"prompt": {
|
|
19888
|
+
"type": "string",
|
|
19889
|
+
"minLength": 1
|
|
19890
|
+
},
|
|
19891
|
+
"produces": {
|
|
19892
|
+
"type": "array",
|
|
19893
|
+
"items": {
|
|
19894
|
+
"type": "string",
|
|
19895
|
+
"minLength": 1
|
|
19896
|
+
}
|
|
19897
|
+
}
|
|
19898
|
+
},
|
|
19899
|
+
"required": [
|
|
19900
|
+
"agent",
|
|
19901
|
+
"prompt",
|
|
19902
|
+
"produces"
|
|
19903
|
+
]
|
|
19904
|
+
},
|
|
19905
|
+
"postInstall": { "type": "string" }
|
|
19906
|
+
},
|
|
19907
|
+
"required": [
|
|
19908
|
+
"schemaVersion",
|
|
19909
|
+
"id",
|
|
19910
|
+
"title",
|
|
19911
|
+
"summary",
|
|
19912
|
+
"author",
|
|
19913
|
+
"tags",
|
|
19914
|
+
"source",
|
|
19915
|
+
"install",
|
|
19916
|
+
"secrets",
|
|
19917
|
+
"secretGroups",
|
|
19918
|
+
"variables"
|
|
19919
|
+
]
|
|
19920
|
+
},
|
|
19921
|
+
"readme": { "type": ["string", "null"] },
|
|
19922
|
+
"status": {
|
|
19923
|
+
"type": "string",
|
|
19924
|
+
"enum": [
|
|
19925
|
+
"pending",
|
|
19926
|
+
"approved",
|
|
19927
|
+
"rejected"
|
|
19928
|
+
]
|
|
18773
19929
|
}
|
|
18774
19930
|
},
|
|
18775
19931
|
"required": [
|
|
18776
|
-
"
|
|
18777
|
-
"
|
|
18778
|
-
"
|
|
19932
|
+
"id",
|
|
19933
|
+
"slug",
|
|
19934
|
+
"title",
|
|
19935
|
+
"summary",
|
|
19936
|
+
"author",
|
|
19937
|
+
"tags",
|
|
19938
|
+
"verified",
|
|
19939
|
+
"install_count",
|
|
19940
|
+
"github_repo",
|
|
19941
|
+
"created_at",
|
|
19942
|
+
"updated_at",
|
|
19943
|
+
"description",
|
|
19944
|
+
"github_sha",
|
|
19945
|
+
"github_path",
|
|
19946
|
+
"manifest",
|
|
19947
|
+
"readme",
|
|
19948
|
+
"status"
|
|
18779
19949
|
]
|
|
18780
19950
|
},
|
|
19951
|
+
"sdkName": "getTemplate",
|
|
19952
|
+
"summary": "Get a function template",
|
|
19953
|
+
"tag": "Templates",
|
|
19954
|
+
"tagCommand": "templates"
|
|
19955
|
+
},
|
|
19956
|
+
{
|
|
19957
|
+
"binaryResponse": false,
|
|
19958
|
+
"bodyRequired": false,
|
|
19959
|
+
"command": "get-template-install",
|
|
19960
|
+
"description": "Fetch the current state of a template install. Reads may advance the\nself-test phase when a reply effect has been observed.\n",
|
|
19961
|
+
"hasJsonBody": false,
|
|
19962
|
+
"method": "GET",
|
|
19963
|
+
"operationId": "getTemplateInstall",
|
|
19964
|
+
"path": "/templates/installs/{id}",
|
|
19965
|
+
"pathParams": [{
|
|
19966
|
+
"description": "Template install UUID.",
|
|
19967
|
+
"enum": null,
|
|
19968
|
+
"name": "id",
|
|
19969
|
+
"required": true,
|
|
19970
|
+
"type": "string"
|
|
19971
|
+
}],
|
|
19972
|
+
"queryParams": [],
|
|
19973
|
+
"requestSchema": null,
|
|
18781
19974
|
"responseSchema": {
|
|
18782
19975
|
"type": "object",
|
|
18783
19976
|
"properties": {
|
|
18784
19977
|
"id": {
|
|
18785
19978
|
"type": "string",
|
|
18786
|
-
"
|
|
19979
|
+
"format": "uuid"
|
|
18787
19980
|
},
|
|
18788
|
-
"
|
|
19981
|
+
"template_slug": {
|
|
18789
19982
|
"type": "string",
|
|
18790
|
-
"
|
|
18791
|
-
"
|
|
18792
|
-
"queued",
|
|
18793
|
-
"submitted_to_agent",
|
|
18794
|
-
"agent_failed",
|
|
18795
|
-
"gate_denied",
|
|
18796
|
-
"unknown",
|
|
18797
|
-
"delivered",
|
|
18798
|
-
"bounced",
|
|
18799
|
-
"deferred",
|
|
18800
|
-
"wait_timeout"
|
|
18801
|
-
]
|
|
19983
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
19984
|
+
"description": "Template slug for this install."
|
|
18802
19985
|
},
|
|
18803
|
-
"
|
|
19986
|
+
"state": {
|
|
18804
19987
|
"type": "string",
|
|
18805
|
-
"
|
|
19988
|
+
"enum": [
|
|
19989
|
+
"deploying",
|
|
19990
|
+
"connecting",
|
|
19991
|
+
"bound",
|
|
19992
|
+
"tested",
|
|
19993
|
+
"deploy_failed",
|
|
19994
|
+
"bind_failed",
|
|
19995
|
+
"test_failed"
|
|
19996
|
+
]
|
|
18806
19997
|
},
|
|
18807
|
-
"
|
|
19998
|
+
"address": { "type": ["string", "null"] },
|
|
19999
|
+
"function_id": {
|
|
18808
20000
|
"type": ["string", "null"],
|
|
18809
|
-
"
|
|
20001
|
+
"format": "uuid"
|
|
18810
20002
|
},
|
|
18811
|
-
"
|
|
18812
|
-
|
|
18813
|
-
"
|
|
18814
|
-
"
|
|
20003
|
+
"error": { "type": ["string", "null"] },
|
|
20004
|
+
"created_at": {
|
|
20005
|
+
"type": "string",
|
|
20006
|
+
"format": "date-time"
|
|
18815
20007
|
},
|
|
18816
|
-
"
|
|
18817
|
-
"type": "
|
|
18818
|
-
"
|
|
18819
|
-
|
|
20008
|
+
"updated_at": {
|
|
20009
|
+
"type": "string",
|
|
20010
|
+
"format": "date-time"
|
|
20011
|
+
}
|
|
20012
|
+
},
|
|
20013
|
+
"required": [
|
|
20014
|
+
"id",
|
|
20015
|
+
"template_slug",
|
|
20016
|
+
"state",
|
|
20017
|
+
"address",
|
|
20018
|
+
"function_id",
|
|
20019
|
+
"error",
|
|
20020
|
+
"created_at",
|
|
20021
|
+
"updated_at"
|
|
20022
|
+
]
|
|
20023
|
+
},
|
|
20024
|
+
"sdkName": "getTemplateInstall",
|
|
20025
|
+
"summary": "Get template install status",
|
|
20026
|
+
"tag": "Templates",
|
|
20027
|
+
"tagCommand": "templates"
|
|
20028
|
+
},
|
|
20029
|
+
{
|
|
20030
|
+
"binaryResponse": false,
|
|
20031
|
+
"bodyRequired": true,
|
|
20032
|
+
"command": "install-template",
|
|
20033
|
+
"description": "Start a one-shot deploy of an approved deploy-mode Function template.\nThe response returns an install record immediately; poll\n`GET /templates/installs/{id}` for progress.\n",
|
|
20034
|
+
"hasJsonBody": true,
|
|
20035
|
+
"method": "POST",
|
|
20036
|
+
"operationId": "installTemplate",
|
|
20037
|
+
"path": "/templates/{id}/install",
|
|
20038
|
+
"pathParams": [{
|
|
20039
|
+
"description": "Template slug from the template manifest.",
|
|
20040
|
+
"enum": null,
|
|
20041
|
+
"name": "id",
|
|
20042
|
+
"required": true,
|
|
20043
|
+
"type": "string"
|
|
20044
|
+
}],
|
|
20045
|
+
"queryParams": [],
|
|
20046
|
+
"requestSchema": {
|
|
20047
|
+
"type": "object",
|
|
20048
|
+
"additionalProperties": false,
|
|
20049
|
+
"properties": {
|
|
20050
|
+
"address": {
|
|
20051
|
+
"type": "string",
|
|
20052
|
+
"pattern": "^[a-z0-9][a-z0-9._-]{0,63}$",
|
|
20053
|
+
"description": "Localpart to claim on the selected inbound domain. Defaults to the template slug."
|
|
18820
20054
|
},
|
|
18821
|
-
"
|
|
20055
|
+
"domain": {
|
|
18822
20056
|
"type": "string",
|
|
18823
|
-
"
|
|
20057
|
+
"minLength": 3,
|
|
20058
|
+
"description": "Org domain name to claim the address on. Defaults to the org's newest active domain."
|
|
18824
20059
|
},
|
|
18825
|
-
"
|
|
20060
|
+
"variables": {
|
|
20061
|
+
"type": "object",
|
|
20062
|
+
"additionalProperties": { "type": "string" },
|
|
20063
|
+
"description": "Template variable values keyed by manifest variable key."
|
|
20064
|
+
},
|
|
20065
|
+
"secrets": {
|
|
20066
|
+
"type": "object",
|
|
20067
|
+
"additionalProperties": { "type": "string" },
|
|
20068
|
+
"description": "Secret values keyed by manifest secret key."
|
|
20069
|
+
}
|
|
20070
|
+
}
|
|
20071
|
+
},
|
|
20072
|
+
"responseSchema": {
|
|
20073
|
+
"type": "object",
|
|
20074
|
+
"properties": {
|
|
20075
|
+
"id": {
|
|
18826
20076
|
"type": "string",
|
|
18827
|
-
"
|
|
20077
|
+
"format": "uuid"
|
|
18828
20078
|
},
|
|
18829
|
-
"
|
|
20079
|
+
"template_slug": {
|
|
18830
20080
|
"type": "string",
|
|
18831
|
-
"
|
|
20081
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
20082
|
+
"description": "Template slug for this install."
|
|
18832
20083
|
},
|
|
18833
|
-
"
|
|
20084
|
+
"state": {
|
|
18834
20085
|
"type": "string",
|
|
18835
|
-
"description": "Narrower enum covering only the four terminal delivery\noutcomes returned to a synchronous `wait: true` send.\n\nOn the SendMailResult shape, `delivery_status` is always\nequal to `status` whenever both are present (i.e. on\nterminal-state replays and live wait=true responses).\nThe two fields exist so callers that want to type-narrow\non \"this is a delivery outcome\" can pattern-match against\nthe four-value enum without handling the broader\nSentEmailStatus value set (which also covers `queued`,\n`submitted_to_agent`, `agent_failed`, `gate_denied`,\n`unknown`).\n\nOn async-mode and pre-terminal responses, `delivery_status`\nis absent and only `status` is populated. Use `status` if\nyou want a single field that's always present.\n",
|
|
18836
20086
|
"enum": [
|
|
18837
|
-
"
|
|
18838
|
-
"
|
|
18839
|
-
"
|
|
18840
|
-
"
|
|
20087
|
+
"deploying",
|
|
20088
|
+
"connecting",
|
|
20089
|
+
"bound",
|
|
20090
|
+
"tested",
|
|
20091
|
+
"deploy_failed",
|
|
20092
|
+
"bind_failed",
|
|
20093
|
+
"test_failed"
|
|
18841
20094
|
]
|
|
18842
20095
|
},
|
|
18843
|
-
"
|
|
18844
|
-
|
|
18845
|
-
"
|
|
20096
|
+
"address": { "type": ["string", "null"] },
|
|
20097
|
+
"function_id": {
|
|
20098
|
+
"type": ["string", "null"],
|
|
20099
|
+
"format": "uuid"
|
|
18846
20100
|
},
|
|
18847
|
-
"
|
|
20101
|
+
"error": { "type": ["string", "null"] },
|
|
20102
|
+
"created_at": {
|
|
18848
20103
|
"type": "string",
|
|
18849
|
-
"
|
|
20104
|
+
"format": "date-time"
|
|
18850
20105
|
},
|
|
18851
|
-
"
|
|
18852
|
-
"type": "
|
|
18853
|
-
"
|
|
20106
|
+
"updated_at": {
|
|
20107
|
+
"type": "string",
|
|
20108
|
+
"format": "date-time"
|
|
18854
20109
|
}
|
|
18855
20110
|
},
|
|
18856
20111
|
"required": [
|
|
18857
20112
|
"id",
|
|
18858
|
-
"
|
|
18859
|
-
"
|
|
18860
|
-
"
|
|
18861
|
-
"
|
|
18862
|
-
"
|
|
18863
|
-
"
|
|
18864
|
-
"
|
|
18865
|
-
"content_hash",
|
|
18866
|
-
"idempotent_replay"
|
|
20113
|
+
"template_slug",
|
|
20114
|
+
"state",
|
|
20115
|
+
"address",
|
|
20116
|
+
"function_id",
|
|
20117
|
+
"error",
|
|
20118
|
+
"created_at",
|
|
20119
|
+
"updated_at"
|
|
18867
20120
|
]
|
|
18868
20121
|
},
|
|
18869
|
-
"sdkName": "
|
|
18870
|
-
"summary": "
|
|
18871
|
-
"tag": "
|
|
18872
|
-
"tagCommand": "
|
|
20122
|
+
"sdkName": "installTemplate",
|
|
20123
|
+
"summary": "Install a function template",
|
|
20124
|
+
"tag": "Templates",
|
|
20125
|
+
"tagCommand": "templates"
|
|
20126
|
+
},
|
|
20127
|
+
{
|
|
20128
|
+
"binaryResponse": false,
|
|
20129
|
+
"bodyRequired": false,
|
|
20130
|
+
"command": "list-templates",
|
|
20131
|
+
"description": "List approved Function templates available for browsing and\ninstallation. Results are cacheable and paginated with\n`data.next_cursor`.\n",
|
|
20132
|
+
"hasJsonBody": false,
|
|
20133
|
+
"method": "GET",
|
|
20134
|
+
"operationId": "listTemplates",
|
|
20135
|
+
"path": "/templates",
|
|
20136
|
+
"pathParams": [],
|
|
20137
|
+
"queryParams": [
|
|
20138
|
+
{
|
|
20139
|
+
"description": "Search templates by title, summary, or slug.",
|
|
20140
|
+
"enum": null,
|
|
20141
|
+
"name": "q",
|
|
20142
|
+
"required": false,
|
|
20143
|
+
"type": "string"
|
|
20144
|
+
},
|
|
20145
|
+
{
|
|
20146
|
+
"description": "Filter templates by an exact tag.",
|
|
20147
|
+
"enum": null,
|
|
20148
|
+
"name": "tag",
|
|
20149
|
+
"required": false,
|
|
20150
|
+
"type": "string"
|
|
20151
|
+
},
|
|
20152
|
+
{
|
|
20153
|
+
"description": "Cursor from a previous response `data.next_cursor` value.",
|
|
20154
|
+
"enum": null,
|
|
20155
|
+
"name": "cursor",
|
|
20156
|
+
"required": false,
|
|
20157
|
+
"type": "string"
|
|
20158
|
+
},
|
|
20159
|
+
{
|
|
20160
|
+
"default": 50,
|
|
20161
|
+
"description": "Maximum number of templates to return. The server caps this at 100.",
|
|
20162
|
+
"enum": null,
|
|
20163
|
+
"maximum": 100,
|
|
20164
|
+
"minimum": 1,
|
|
20165
|
+
"name": "limit",
|
|
20166
|
+
"required": false,
|
|
20167
|
+
"type": "integer"
|
|
20168
|
+
}
|
|
20169
|
+
],
|
|
20170
|
+
"requestSchema": null,
|
|
20171
|
+
"responseSchema": {
|
|
20172
|
+
"type": "object",
|
|
20173
|
+
"properties": {
|
|
20174
|
+
"items": {
|
|
20175
|
+
"type": "array",
|
|
20176
|
+
"items": {
|
|
20177
|
+
"type": "object",
|
|
20178
|
+
"properties": {
|
|
20179
|
+
"id": {
|
|
20180
|
+
"type": "string",
|
|
20181
|
+
"format": "uuid"
|
|
20182
|
+
},
|
|
20183
|
+
"slug": {
|
|
20184
|
+
"type": "string",
|
|
20185
|
+
"pattern": "^[a-z0-9][a-z0-9_-]{0,62}$",
|
|
20186
|
+
"description": "Stable template slug used in template URLs and install commands."
|
|
20187
|
+
},
|
|
20188
|
+
"title": { "type": "string" },
|
|
20189
|
+
"summary": { "type": "string" },
|
|
20190
|
+
"author": {
|
|
20191
|
+
"type": "object",
|
|
20192
|
+
"additionalProperties": false,
|
|
20193
|
+
"properties": {
|
|
20194
|
+
"id": {
|
|
20195
|
+
"type": "string",
|
|
20196
|
+
"minLength": 1
|
|
20197
|
+
},
|
|
20198
|
+
"name": {
|
|
20199
|
+
"type": "string",
|
|
20200
|
+
"minLength": 1
|
|
20201
|
+
},
|
|
20202
|
+
"url": {
|
|
20203
|
+
"type": "string",
|
|
20204
|
+
"format": "uri"
|
|
20205
|
+
}
|
|
20206
|
+
},
|
|
20207
|
+
"required": ["id", "name"]
|
|
20208
|
+
},
|
|
20209
|
+
"tags": {
|
|
20210
|
+
"type": "array",
|
|
20211
|
+
"items": { "type": "string" }
|
|
20212
|
+
},
|
|
20213
|
+
"verified": { "type": "boolean" },
|
|
20214
|
+
"install_count": {
|
|
20215
|
+
"type": "integer",
|
|
20216
|
+
"minimum": 0
|
|
20217
|
+
},
|
|
20218
|
+
"github_repo": {
|
|
20219
|
+
"type": "string",
|
|
20220
|
+
"pattern": "^[A-Za-z0-9-]+/[A-Za-z0-9_.-]+$",
|
|
20221
|
+
"description": "GitHub repository in owner/repo form."
|
|
20222
|
+
},
|
|
20223
|
+
"created_at": {
|
|
20224
|
+
"type": "string",
|
|
20225
|
+
"format": "date-time"
|
|
20226
|
+
},
|
|
20227
|
+
"updated_at": {
|
|
20228
|
+
"type": "string",
|
|
20229
|
+
"format": "date-time"
|
|
20230
|
+
}
|
|
20231
|
+
},
|
|
20232
|
+
"required": [
|
|
20233
|
+
"id",
|
|
20234
|
+
"slug",
|
|
20235
|
+
"title",
|
|
20236
|
+
"summary",
|
|
20237
|
+
"author",
|
|
20238
|
+
"tags",
|
|
20239
|
+
"verified",
|
|
20240
|
+
"install_count",
|
|
20241
|
+
"github_repo",
|
|
20242
|
+
"created_at",
|
|
20243
|
+
"updated_at"
|
|
20244
|
+
]
|
|
20245
|
+
}
|
|
20246
|
+
},
|
|
20247
|
+
"next_cursor": {
|
|
20248
|
+
"type": ["string", "null"],
|
|
20249
|
+
"description": "Cursor to pass as the next `cursor` query value, or null when there are no more templates."
|
|
20250
|
+
}
|
|
20251
|
+
},
|
|
20252
|
+
"required": ["items", "next_cursor"]
|
|
20253
|
+
},
|
|
20254
|
+
"sdkName": "listTemplates",
|
|
20255
|
+
"summary": "List function templates",
|
|
20256
|
+
"tag": "Templates",
|
|
20257
|
+
"tagCommand": "templates"
|
|
18873
20258
|
},
|
|
18874
20259
|
{
|
|
18875
20260
|
"binaryResponse": false,
|