@primitivedotdev/sdk 0.31.0 → 0.31.1
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 +1 -1
- package/dist/api/index.js +2 -2
- package/dist/{api-CMPC1ByD.js → api-CMzxyIqH.js} +17 -17
- package/dist/{index-Cbsl8j7G.d.ts → index-BwDgniCA.d.ts} +19 -27
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/dist/openapi/index.js +1 -1
- package/dist/{operations.generated-DsbeO3l-.js → operations.generated-BOlpIYkQ.js} +12 -49
- package/package.json +1 -1
package/dist/api/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as listSentEmails, $a as SearchEmailsData, $i as ListFunctionLogsError, $n as DownloadAttachmentsData, $o as UpdateAccountData, $r as GetFunctionResponses, $t as CreateFunctionData, A as deleteEndpoint, Aa as ReplayEmailWebhooksData, Ai as ListDeliveriesResponses, An as DeleteFilterErrors, Ao as StartCliLoginResponse, Ar as FunctionTestRunDeliveryEndpoint, As as VerifyCliSignupData, At as CliLoginStartResult, B as getFunctionTestRunTrace, Ba as ReplyToEmailResponses, Bi as ListEmailsResponses, Bn as DeleteFunctionSecretErrors, Bo as TestEndpointData, Br as GetAccountError, Bs as VerifyDomainResponses, Bt as CliSignupVerifyResult, C as cliLogout, Ca as PollCliLoginResponse, Ci as GetWebhookSecretResponse, Cn as DeleteEndpointData, Co as SetFunctionSecretInput, Cr as FunctionDetail, Cs as UpdateFunctionData, Ct as AddDomainData, D as createFunctionSecret, Da as ReplayDeliveryErrors, Di as ListDeliveriesError, Dn as DeleteEndpointResponses, Do as StartCliLoginError, Dr as FunctionSecretWriteResult, Ds as UpdateFunctionResponse, Dt as AddDomainResponse, E as createFunction, Ea as ReplayDeliveryError, Ei as ListDeliveriesData, En as DeleteEndpointResponse, Eo as StartCliLoginData, Er as FunctionSecretListItem, Es as UpdateFunctionInput, Et as AddDomainInput, F as downloadAttachments, Fa as ReplayResult, Fi as ListDomainsResponses, Fn as DeleteFunctionErrors, Fo as StartCliSignupInput, Fr as FunctionTestRunState, Fs as VerifyCliSignupResponses, Ft as CliLogoutResponse, G as listDeliveries, Ga as ResendCliSignupVerificationResponse, Gi as ListEndpointsResponses, Gn as DiscardContentResult, Go as TestFunctionData, Gr as GetEmailError, Gs as Config, Gt as CreateEndpointResponse, H as getSentEmail, Ha as ResendCliSignupVerificationError, Hi as ListEndpointsError, Hn as DeleteFunctionSecretResponses, Ho as TestEndpointErrors, Hr as GetAccountResponse, Hs as createClient, Ht as CreateEndpointError, I as downloadRawEmail, Ia as ReplyToEmailData, Ii as ListEmailsData, In as DeleteFunctionResponse, Io as StartCliSignupResponse, Ir as FunctionTestRunTrace, Is as VerifyDomainData, It as CliLogoutResponses, J as listEndpoints, Ja as RotateWebhookSecretData, Ji as ListFiltersError, Jn as DiscardEmailContentErrors, Jo as TestFunctionResponse, Jr as GetEmailResponses, Js as RequestOptions, Jt as CreateFilterError, K as listDomains, Ka as ResendCliSignupVerificationResponses, Ki as ListEnvelope, Kn as DiscardEmailContentData, Ko as TestFunctionError, Kr as GetEmailErrors, Ks as CreateClientConfig, Kt as CreateEndpointResponses, L as getAccount, La as ReplyToEmailError, Li as ListEmailsError, Ln as DeleteFunctionResponses, Lo as StartCliSignupResponses, Lr as GateDenial, Ls as VerifyDomainError, Lt as CliLogoutResult, M as deleteFunction, Ma as ReplayEmailWebhooksErrors, Mi as ListDomainsError, Mn as DeleteFilterResponses, Mo as StartCliSignupData, Mr as FunctionTestRunOutboundRequest, Ms as VerifyCliSignupErrors, Mt as CliLogoutError, N as deleteFunctionSecret, Na as ReplayEmailWebhooksResponse, Ni as ListDomainsErrors, Nn as DeleteFunctionData, No as StartCliSignupError, Nr as FunctionTestRunReply, Ns as VerifyCliSignupInput, Nt as CliLogoutErrors, O as deleteDomain, Oa as ReplayDeliveryResponse, Oi as ListDeliveriesErrors, On as DeleteFilterData, Oo as StartCliLoginErrors, Or as FunctionTestRun, Os as UpdateFunctionResponses, Ot as AddDomainResponses, P as discardEmailContent, Pa as ReplayEmailWebhooksResponses, Pi as ListDomainsResponse, Pn as DeleteFunctionError, Po as StartCliSignupErrors, Pr as FunctionTestRunSend, Ps as VerifyCliSignupResponse, Pt as CliLogoutInput, Q as listFunctions, Qa as RotateWebhookSecretResponses, Qi as ListFunctionLogsData, Qn as DomainVerifyResult, Qo as UnverifiedDomain, Qr as GetFunctionResponse, Qs as Auth, Qt as CreateFilterResponses, R as getEmail, Ra as ReplyToEmailErrors, Ri as ListEmailsErrors, Rn as DeleteFunctionSecretData, Ro as StorageStats, Rr as GateFix, Rs as VerifyDomainErrors, Rt as CliSignupResendResult, S as addDomain, Sa as PollCliLoginInput, Si as GetWebhookSecretErrors, Sn as DeleteEmailResponses, So as SetFunctionSecretErrors, Sr as FunctionDeployStatus, Ss as UpdateFilterResponses, St as AccountUpdated, T as createFilter, Ta as ReplayDeliveryData, Ti as Limit, Tn as DeleteEndpointErrors, To as SetFunctionSecretResponses, Tr as FunctionLogRow, Ts as UpdateFunctionErrors, Tt as AddDomainErrors, U as getStorageStats, Ua as ResendCliSignupVerificationErrors, Ui as ListEndpointsErrors, Un as DeliveryStatus, Uo as TestEndpointResponse, Ur as GetAccountResponses, Us as Client, Ut as CreateEndpointErrors, V as getSendPermissions, Va as ResendCliSignupVerificationData, Vi as ListEndpointsData, Vn as DeleteFunctionSecretResponse, Vo as TestEndpointError, Vr as GetAccountErrors, Vs as WebhookSecret, Vt as CreateEndpointData, W as getWebhookSecret, Wa as ResendCliSignupVerificationInput, Wi as ListEndpointsResponse, Wn as DeliverySummary, Wo as TestEndpointResponses, Wr as GetEmailData, Ws as ClientOptions, Wt as CreateEndpointInput, X as listFunctionLogs, Xa as RotateWebhookSecretErrors, Xi as ListFiltersResponse, Xn as DiscardEmailContentResponses, Xo as TestInvocationResult, Xr as GetFunctionError, Xs as ResponseStyle, Xt as CreateFilterInput, Y as listFilters, Ya as RotateWebhookSecretError, Yi as ListFiltersErrors, Yn as DiscardEmailContentResponse, Yo as TestFunctionResponses, Yr as GetFunctionData, Ys as RequestResult, Yt as CreateFilterErrors, Z as listFunctionSecrets, Za as RotateWebhookSecretResponse, Zi as ListFiltersResponses, Zn as Domain, Zo as TestResult, Zr as GetFunctionErrors, Zs as createConfig, Zt as CreateFilterResponse, _ as PrimitiveApiClientOptions, _a as ListSentEmailsResponses, _i as GetStorageStatsErrors, _n as DeleteDomainResponses, _o as SentEmailDetail, _r as EmailSummary, _s as UpdateFilterData, _t as updateFilter, a as RequestOptions$2, aa as ListFunctionSecretsErrors, ai as GetSendPermissionsData, an as CreateFunctionResult, ao as SendEmailError, ar as DownloadRawEmailError, as as UpdateDomainData, at as rotateWebhookSecret, b as RequestOptions$1, ba as PollCliLoginError, bi as GetWebhookSecretData, bn as DeleteEmailErrors, bo as SetFunctionSecretData, br as ErrorResponse, bs as UpdateFilterInput, bt as verifyDomain, c as SendThreadInput, ca as ListFunctionsData, ci as GetSendPermissionsResponse, cn as CreateFunctionSecretErrors, co as SendEmailResponses, cr as DownloadRawEmailResponses, cs as UpdateDomainInput, ct as sendEmail, d as PRIMITIVE_SIGNATURE_HEADER, da as ListFunctionsResponse, di as GetSentEmailError, dn as CreateFunctionSecretResponses, do as SendPermissionAddress, dr as EmailSearchFacetBucket, ds as UpdateEndpointData, dt as startCliSignup, ea as ListFunctionLogsErrors, ei as GetFunctionTestRunTraceData, en as CreateFunctionError, eo as SearchEmailsError, er as DownloadAttachmentsError, es as UpdateAccountError, et as pollCliLogin, f as VerifyOptions, fa as ListFunctionsResponses, fi as GetSentEmailErrors, fn as Cursor, fo as SendPermissionAnyRecipient, fr as EmailSearchFacets, fs as UpdateEndpointError, ft as testEndpoint, g as PrimitiveApiClient, ga as ListSentEmailsResponse, gi as GetStorageStatsError, gn as DeleteDomainResponse, go as SendPermissionsMeta, gr as EmailStatus, gs as UpdateEndpointResponses, gt as updateEndpoint, h as DEFAULT_API_BASE_URL_2, ha as ListSentEmailsErrors, hi as GetStorageStatsData, hn as DeleteDomainErrors, ho as SendPermissionYourDomain, hr as EmailSearchResult, hs as UpdateEndpointResponse, ht as updateDomain, i as ReplyInput, ia as ListFunctionSecretsError, ii as GetFunctionTestRunTraceResponses, in as CreateFunctionResponses, io as SendEmailData, ir as DownloadRawEmailData, is as UpdateAccountResponses, it as resendCliSignupVerification, j as deleteFilter, ja as ReplayEmailWebhooksError, ji as ListDomainsData, jn as DeleteFilterResponse, jo as StartCliLoginResponses, jr as FunctionTestRunInboundEmail, js as VerifyCliSignupError, jt as CliLogoutData, k as deleteEmail, ka as ReplayDeliveryResponses, ki as ListDeliveriesResponse, kn as DeleteFilterError, ko as StartCliLoginInput, kr as FunctionTestRunDelivery, ks as VerifiedDomain, kt as CliLoginPollResult, l as client, la as ListFunctionsError, li as GetSendPermissionsResponses, ln as CreateFunctionSecretInput, lo as SendMailInput, lr as EmailDetail, ls as UpdateDomainResponse, lt as setFunctionSecret, m as DEFAULT_API_BASE_URL_1, ma as ListSentEmailsError, mi as GetSentEmailResponses, mn as DeleteDomainError, mo as SendPermissionRule, mr as EmailSearchMeta, ms as UpdateEndpointInput, mt as updateAccount, n as PrimitiveClient, na as ListFunctionLogsResponses, ni as GetFunctionTestRunTraceErrors, nn as CreateFunctionInput, no as SearchEmailsResponse, nr as DownloadAttachmentsResponse, ns as UpdateAccountInput, nt as replayEmailWebhooks, o as SendInput, oa as ListFunctionSecretsResponse, oi as GetSendPermissionsError, on as CreateFunctionSecretData, oo as SendEmailErrors, or as DownloadRawEmailErrors, os as UpdateDomainError, ot as sdk_gen_d_exports, p as verifyWebhookSignature, pa as ListSentEmailsData, pi as GetSentEmailResponse, pn as DeleteDomainData, po as SendPermissionManagedZone, pr as EmailSearchHighlights, ps as UpdateEndpointErrors, pt as testFunction, q as listEmails, qa as ResourceId, qi as ListFiltersData, qn as DiscardEmailContentError, qo as TestFunctionErrors, qr as GetEmailResponse, qs as Options, qt as CreateFilterData, r as PrimitiveClientOptions, ra as ListFunctionSecretsData, ri as GetFunctionTestRunTraceResponse, rn as CreateFunctionResponse, ro as SearchEmailsResponses, rr as DownloadAttachmentsResponses, rs as UpdateAccountResponse, rt as replyToEmail, s as SendResult, sa as ListFunctionSecretsResponses, si as GetSendPermissionsErrors, sn as CreateFunctionSecretError, so as SendEmailResponse, sr as DownloadRawEmailResponse, ss as UpdateDomainErrors, st as searchEmails, t as ForwardInput, ta as ListFunctionLogsResponse, ti as GetFunctionTestRunTraceError, tn as CreateFunctionErrors, to as SearchEmailsErrors, tr as DownloadAttachmentsErrors, ts as UpdateAccountErrors, tt as replayDelivery, u as createPrimitiveClient, ua as ListFunctionsErrors, ui as GetSentEmailData, un as CreateFunctionSecretResponse, uo as SendMailResult, ur as EmailDetailReply, us as UpdateDomainResponses, ut as startCliLogin, v as PrimitiveApiError, va as PaginationMeta, vi as GetStorageStatsResponse, vn as DeleteEmailData, vo as SentEmailStatus, vr as EmailWebhookStatus, vs as UpdateFilterError, vt as updateFunction, w as createEndpoint, wa as PollCliLoginResponses, wi as GetWebhookSecretResponses, wn as DeleteEndpointError, wo as SetFunctionSecretResponse, wr as FunctionListItem, ws as UpdateFunctionError, wt as AddDomainError, x as createPrimitiveApiClient, xa as PollCliLoginErrors, xi as GetWebhookSecretError, xn as DeleteEmailResponse, xo as SetFunctionSecretError, xr as Filter, xs as UpdateFilterResponse, xt as Account, y as PrimitiveApiErrorDetails, ya as PollCliLoginData, yi as GetStorageStatsResponses, yn as DeleteEmailError, yo as SentEmailSummary, yr as Endpoint, ys as UpdateFilterErrors, yt as verifyCliSignup, z as getFunction, za as ReplyToEmailResponse, zi as ListEmailsResponse, zn as DeleteFunctionSecretError, zo as SuccessEnvelope, zr as GetAccountData, zs as VerifyDomainResponse, zt as CliSignupStartResult } from "../index-Cbsl8j7G.js";
|
|
1
|
+
import { $ as listSentEmails, $a as SearchEmailsData, $i as ListFunctionLogsError, $n as DownloadAttachmentsData, $o as UpdateAccountData, $r as GetFunctionResponses, $t as CreateFunctionData, A as deleteEndpoint, Aa as ReplayEmailWebhooksData, Ai as ListDeliveriesResponses, An as DeleteFilterErrors, Ao as StartCliLoginResponse, Ar as FunctionTestRunDeliveryEndpoint, As as VerifyCliSignupData, At as CliLoginStartResult, B as getFunctionTestRunTrace, Ba as ReplyToEmailResponses, Bi as ListEmailsResponses, Bn as DeleteFunctionSecretErrors, Bo as TestEndpointData, Br as GetAccountError, Bs as VerifyDomainResponses, Bt as CliSignupVerifyResult, C as cliLogout, Ca as PollCliLoginResponse, Ci as GetWebhookSecretResponse, Cn as DeleteEndpointData, Co as SetFunctionSecretInput, Cr as FunctionDetail, Cs as UpdateFunctionData, Ct as AddDomainData, D as createFunctionSecret, Da as ReplayDeliveryErrors, Di as ListDeliveriesError, Dn as DeleteEndpointResponses, Do as StartCliLoginError, Dr as FunctionSecretWriteResult, Ds as UpdateFunctionResponse, Dt as AddDomainResponse, E as createFunction, Ea as ReplayDeliveryError, Ei as ListDeliveriesData, En as DeleteEndpointResponse, Eo as StartCliLoginData, Er as FunctionSecretListItem, Es as UpdateFunctionInput, Et as AddDomainInput, F as downloadAttachments, Fa as ReplayResult, Fi as ListDomainsResponses, Fn as DeleteFunctionErrors, Fo as StartCliSignupInput, Fr as FunctionTestRunState, Fs as VerifyCliSignupResponses, Ft as CliLogoutResponse, G as listDeliveries, Ga as ResendCliSignupVerificationResponse, Gi as ListEndpointsResponses, Gn as DiscardContentResult, Go as TestFunctionData, Gr as GetEmailError, Gs as Config, Gt as CreateEndpointResponse, H as getSentEmail, Ha as ResendCliSignupVerificationError, Hi as ListEndpointsError, Hn as DeleteFunctionSecretResponses, Ho as TestEndpointErrors, Hr as GetAccountResponse, Hs as createClient, Ht as CreateEndpointError, I as downloadRawEmail, Ia as ReplyToEmailData, Ii as ListEmailsData, In as DeleteFunctionResponse, Io as StartCliSignupResponse, Ir as FunctionTestRunTrace, Is as VerifyDomainData, It as CliLogoutResponses, J as listEndpoints, Ja as RotateWebhookSecretData, Ji as ListFiltersError, Jn as DiscardEmailContentErrors, Jo as TestFunctionResponse, Jr as GetEmailResponses, Js as RequestOptions, Jt as CreateFilterError, K as listDomains, Ka as ResendCliSignupVerificationResponses, Ki as ListEnvelope, Kn as DiscardEmailContentData, Ko as TestFunctionError, Kr as GetEmailErrors, Ks as CreateClientConfig, Kt as CreateEndpointResponses, L as getAccount, La as ReplyToEmailError, Li as ListEmailsError, Ln as DeleteFunctionResponses, Lo as StartCliSignupResponses, Lr as GateDenial, Ls as VerifyDomainError, Lt as CliLogoutResult, M as deleteFunction, Ma as ReplayEmailWebhooksErrors, Mi as ListDomainsError, Mn as DeleteFilterResponses, Mo as StartCliSignupData, Mr as FunctionTestRunOutboundRequest, Ms as VerifyCliSignupErrors, Mt as CliLogoutError, N as deleteFunctionSecret, Na as ReplayEmailWebhooksResponse, Ni as ListDomainsErrors, Nn as DeleteFunctionData, No as StartCliSignupError, Nr as FunctionTestRunReply, Ns as VerifyCliSignupInput, Nt as CliLogoutErrors, O as deleteDomain, Oa as ReplayDeliveryResponse, Oi as ListDeliveriesErrors, On as DeleteFilterData, Oo as StartCliLoginErrors, Or as FunctionTestRun, Os as UpdateFunctionResponses, Ot as AddDomainResponses, P as discardEmailContent, Pa as ReplayEmailWebhooksResponses, Pi as ListDomainsResponse, Pn as DeleteFunctionError, Po as StartCliSignupErrors, Pr as FunctionTestRunSend, Ps as VerifyCliSignupResponse, Pt as CliLogoutInput, Q as listFunctions, Qa as RotateWebhookSecretResponses, Qi as ListFunctionLogsData, Qn as DomainVerifyResult, Qo as UnverifiedDomain, Qr as GetFunctionResponse, Qs as Auth, Qt as CreateFilterResponses, R as getEmail, Ra as ReplyToEmailErrors, Ri as ListEmailsErrors, Rn as DeleteFunctionSecretData, Ro as StorageStats, Rr as GateFix, Rs as VerifyDomainErrors, Rt as CliSignupResendResult, S as addDomain, Sa as PollCliLoginInput, Si as GetWebhookSecretErrors, Sn as DeleteEmailResponses, So as SetFunctionSecretErrors, Sr as FunctionDeployStatus, Ss as UpdateFilterResponses, St as AccountUpdated, T as createFilter, Ta as ReplayDeliveryData, Ti as Limit, Tn as DeleteEndpointErrors, To as SetFunctionSecretResponses, Tr as FunctionLogRow, Ts as UpdateFunctionErrors, Tt as AddDomainErrors, U as getStorageStats, Ua as ResendCliSignupVerificationErrors, Ui as ListEndpointsErrors, Un as DeliveryStatus, Uo as TestEndpointResponse, Ur as GetAccountResponses, Us as Client, Ut as CreateEndpointErrors, V as getSendPermissions, Va as ResendCliSignupVerificationData, Vi as ListEndpointsData, Vn as DeleteFunctionSecretResponse, Vo as TestEndpointError, Vr as GetAccountErrors, Vs as WebhookSecret, Vt as CreateEndpointData, W as getWebhookSecret, Wa as ResendCliSignupVerificationInput, Wi as ListEndpointsResponse, Wn as DeliverySummary, Wo as TestEndpointResponses, Wr as GetEmailData, Ws as ClientOptions, Wt as CreateEndpointInput, X as listFunctionLogs, Xa as RotateWebhookSecretErrors, Xi as ListFiltersResponse, Xn as DiscardEmailContentResponses, Xo as TestInvocationResult, Xr as GetFunctionError, Xs as ResponseStyle, Xt as CreateFilterInput, Y as listFilters, Ya as RotateWebhookSecretError, Yi as ListFiltersErrors, Yn as DiscardEmailContentResponse, Yo as TestFunctionResponses, Yr as GetFunctionData, Ys as RequestResult, Yt as CreateFilterErrors, Z as listFunctionSecrets, Za as RotateWebhookSecretResponse, Zi as ListFiltersResponses, Zn as Domain, Zo as TestResult, Zr as GetFunctionErrors, Zs as createConfig, Zt as CreateFilterResponse, _ as PrimitiveApiClientOptions, _a as ListSentEmailsResponses, _i as GetStorageStatsErrors, _n as DeleteDomainResponses, _o as SentEmailDetail, _r as EmailSummary, _s as UpdateFilterData, _t as updateFilter, a as RequestOptions$2, aa as ListFunctionSecretsErrors, ai as GetSendPermissionsData, an as CreateFunctionResult, ao as SendEmailError, ar as DownloadRawEmailError, as as UpdateDomainData, at as rotateWebhookSecret, b as RequestOptions$1, ba as PollCliLoginError, bi as GetWebhookSecretData, bn as DeleteEmailErrors, bo as SetFunctionSecretData, br as ErrorResponse, bs as UpdateFilterInput, bt as verifyDomain, c as SendThreadInput, ca as ListFunctionsData, ci as GetSendPermissionsResponse, cn as CreateFunctionSecretErrors, co as SendEmailResponses, cr as DownloadRawEmailResponses, cs as UpdateDomainInput, ct as sendEmail, d as PRIMITIVE_SIGNATURE_HEADER, da as ListFunctionsResponse, di as GetSentEmailError, dn as CreateFunctionSecretResponses, do as SendPermissionAddress, dr as EmailSearchFacetBucket, ds as UpdateEndpointData, dt as startCliSignup, ea as ListFunctionLogsErrors, ei as GetFunctionTestRunTraceData, en as CreateFunctionError, eo as SearchEmailsError, er as DownloadAttachmentsError, es as UpdateAccountError, et as pollCliLogin, f as VerifyOptions, fa as ListFunctionsResponses, fi as GetSentEmailErrors, fn as Cursor, fo as SendPermissionAnyRecipient, fr as EmailSearchFacets, fs as UpdateEndpointError, ft as testEndpoint, g as PrimitiveApiClient, ga as ListSentEmailsResponse, gi as GetStorageStatsError, gn as DeleteDomainResponse, go as SendPermissionsMeta, gr as EmailStatus, gs as UpdateEndpointResponses, gt as updateEndpoint, h as DEFAULT_API_BASE_URL_2, ha as ListSentEmailsErrors, hi as GetStorageStatsData, hn as DeleteDomainErrors, ho as SendPermissionYourDomain, hr as EmailSearchResult, hs as UpdateEndpointResponse, ht as updateDomain, i as ReplyInput, ia as ListFunctionSecretsError, ii as GetFunctionTestRunTraceResponses, in as CreateFunctionResponses, io as SendEmailData, ir as DownloadRawEmailData, is as UpdateAccountResponses, it as resendCliSignupVerification, j as deleteFilter, ja as ReplayEmailWebhooksError, ji as ListDomainsData, jn as DeleteFilterResponse, jo as StartCliLoginResponses, jr as FunctionTestRunInboundEmail, js as VerifyCliSignupError, jt as CliLogoutData, k as deleteEmail, ka as ReplayDeliveryResponses, ki as ListDeliveriesResponse, kn as DeleteFilterError, ko as StartCliLoginInput, kr as FunctionTestRunDelivery, ks as VerifiedDomain, kt as CliLoginPollResult, l as client, la as ListFunctionsError, li as GetSendPermissionsResponses, ln as CreateFunctionSecretInput, lo as SendMailInput, lr as EmailDetail, ls as UpdateDomainResponse, lt as setFunctionSecret, m as DEFAULT_API_BASE_URL_1, ma as ListSentEmailsError, mi as GetSentEmailResponses, mn as DeleteDomainError, mo as SendPermissionRule, mr as EmailSearchMeta, ms as UpdateEndpointInput, mt as updateAccount, n as PrimitiveClient, na as ListFunctionLogsResponses, ni as GetFunctionTestRunTraceErrors, nn as CreateFunctionInput, no as SearchEmailsResponse, nr as DownloadAttachmentsResponse, ns as UpdateAccountInput, nt as replayEmailWebhooks, o as SendInput, oa as ListFunctionSecretsResponse, oi as GetSendPermissionsError, on as CreateFunctionSecretData, oo as SendEmailErrors, or as DownloadRawEmailErrors, os as UpdateDomainError, ot as sdk_gen_d_exports, p as verifyWebhookSignature, pa as ListSentEmailsData, pi as GetSentEmailResponse, pn as DeleteDomainData, po as SendPermissionManagedZone, pr as EmailSearchHighlights, ps as UpdateEndpointErrors, pt as testFunction, q as listEmails, qa as ResourceId, qi as ListFiltersData, qn as DiscardEmailContentError, qo as TestFunctionErrors, qr as GetEmailResponse, qs as Options, qt as CreateFilterData, r as PrimitiveClientOptions, ra as ListFunctionSecretsData, ri as GetFunctionTestRunTraceResponse, rn as CreateFunctionResponse, ro as SearchEmailsResponses, rr as DownloadAttachmentsResponses, rs as UpdateAccountResponse, rt as replyToEmail, s as SendResult, sa as ListFunctionSecretsResponses, si as GetSendPermissionsErrors, sn as CreateFunctionSecretError, so as SendEmailResponse, sr as DownloadRawEmailResponse, ss as UpdateDomainErrors, st as searchEmails, t as ForwardInput, ta as ListFunctionLogsResponse, ti as GetFunctionTestRunTraceError, tn as CreateFunctionErrors, to as SearchEmailsErrors, tr as DownloadAttachmentsErrors, ts as UpdateAccountErrors, tt as replayDelivery, u as createPrimitiveClient, ua as ListFunctionsErrors, ui as GetSentEmailData, un as CreateFunctionSecretResponse, uo as SendMailResult, ur as EmailDetailReply, us as UpdateDomainResponses, ut as startCliLogin, v as PrimitiveApiError, va as PaginationMeta, vi as GetStorageStatsResponse, vn as DeleteEmailData, vo as SentEmailStatus, vr as EmailWebhookStatus, vs as UpdateFilterError, vt as updateFunction, w as createEndpoint, wa as PollCliLoginResponses, wi as GetWebhookSecretResponses, wn as DeleteEndpointError, wo as SetFunctionSecretResponse, wr as FunctionListItem, ws as UpdateFunctionError, wt as AddDomainError, x as createPrimitiveApiClient, xa as PollCliLoginErrors, xi as GetWebhookSecretError, xn as DeleteEmailResponse, xo as SetFunctionSecretError, xr as Filter, xs as UpdateFilterResponse, xt as Account, y as PrimitiveApiErrorDetails, ya as PollCliLoginData, yi as GetStorageStatsResponses, yn as DeleteEmailError, yo as SentEmailSummary, yr as Endpoint, ys as UpdateFilterErrors, yt as verifyCliSignup, z as getFunction, za as ReplyToEmailResponse, zi as ListEmailsResponse, zn as DeleteFunctionSecretError, zo as SuccessEnvelope, zr as GetAccountData, zs as VerifyDomainResponse, zt as CliSignupStartResult } from "../index-BwDgniCA.js";
|
|
2
2
|
import { i as openapiDocument, n as PrimitiveParameterManifest, r as operationManifest, t as PrimitiveOperationManifest } from "../operations.generated-BAniFZK9.js";
|
|
3
3
|
import { u as EmailReceivedEvent } from "../types-BRWDMD7H.js";
|
|
4
4
|
import { b as normalizeReceivedEmail, f as WebhookVerificationError, g as ReceivedEmailThread, h as ReceivedEmailAddress, m as ReceivedEmail, p as WebhookVerificationErrorCode } from "../errors-CO-rv_nK.js";
|
package/dist/api/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { $ as startCliLogin, A as getSendPermissions, B as listFunctionSecrets, C as discardEmailContent, D as getEmail, E as getAccount, F as listDomains, G as replayEmailWebhooks, H as listSentEmails, I as listEmails, J as rotateWebhookSecret, K as replyToEmail, L as listEndpoints, M as getStorageStats, N as getWebhookSecret, O as getFunction, P as listDeliveries, Q as setFunctionSecret, R as listFilters, S as deleteFunctionSecret, T as downloadRawEmail, U as pollCliLogin, V as listFunctions, W as replayDelivery, X as searchEmails, Y as sdk_gen_exports, Z as sendEmail, _ as deleteDomain, a as verifyWebhookSignature, at as updateEndpoint, b as deleteFilter, c as PrimitiveApiClient, ct as verifyCliSignup, d as addDomain, dt as createConfig, et as startCliSignup, f as cliLogout, g as createFunctionSecret, h as createFunction, i as PRIMITIVE_SIGNATURE_HEADER, it as updateDomain, j as getSentEmail, k as getFunctionTestRunTrace, l as PrimitiveApiError, lt as verifyDomain, m as createFilter, n as client, nt as testFunction, o as DEFAULT_API_BASE_URL_1, ot as updateFilter, p as createEndpoint, q as resendCliSignupVerification, r as createPrimitiveClient, rt as updateAccount, s as DEFAULT_API_BASE_URL_2, st as updateFunction, t as PrimitiveClient, tt as testEndpoint, u as createPrimitiveApiClient, ut as createClient, v as deleteEmail, w as downloadAttachments, x as deleteFunction, y as deleteEndpoint, z as listFunctionLogs } from "../api-
|
|
2
|
-
import { n as openapiDocument, t as operationManifest } from "../operations.generated-
|
|
1
|
+
import { $ as startCliLogin, A as getSendPermissions, B as listFunctionSecrets, C as discardEmailContent, D as getEmail, E as getAccount, F as listDomains, G as replayEmailWebhooks, H as listSentEmails, I as listEmails, J as rotateWebhookSecret, K as replyToEmail, L as listEndpoints, M as getStorageStats, N as getWebhookSecret, O as getFunction, P as listDeliveries, Q as setFunctionSecret, R as listFilters, S as deleteFunctionSecret, T as downloadRawEmail, U as pollCliLogin, V as listFunctions, W as replayDelivery, X as searchEmails, Y as sdk_gen_exports, Z as sendEmail, _ as deleteDomain, a as verifyWebhookSignature, at as updateEndpoint, b as deleteFilter, c as PrimitiveApiClient, ct as verifyCliSignup, d as addDomain, dt as createConfig, et as startCliSignup, f as cliLogout, g as createFunctionSecret, h as createFunction, i as PRIMITIVE_SIGNATURE_HEADER, it as updateDomain, j as getSentEmail, k as getFunctionTestRunTrace, l as PrimitiveApiError, lt as verifyDomain, m as createFilter, n as client, nt as testFunction, o as DEFAULT_API_BASE_URL_1, ot as updateFilter, p as createEndpoint, q as resendCliSignupVerification, r as createPrimitiveClient, rt as updateAccount, s as DEFAULT_API_BASE_URL_2, st as updateFunction, t as PrimitiveClient, tt as testEndpoint, u as createPrimitiveApiClient, ut as createClient, v as deleteEmail, w as downloadAttachments, x as deleteFunction, y as deleteEndpoint, z as listFunctionLogs } from "../api-CMzxyIqH.js";
|
|
2
|
+
import { n as openapiDocument, t as operationManifest } from "../operations.generated-BOlpIYkQ.js";
|
|
3
3
|
import { c as WebhookVerificationError, f as normalizeReceivedEmail } from "../errors-BPJGp9I6.js";
|
|
4
4
|
export { DEFAULT_API_BASE_URL_1, DEFAULT_API_BASE_URL_2, PRIMITIVE_SIGNATURE_HEADER, PrimitiveApiClient, PrimitiveApiError, PrimitiveClient, WebhookVerificationError, addDomain, cliLogout, client, createClient, createConfig, createEndpoint, createFilter, createFunction, createFunctionSecret, createPrimitiveApiClient, createPrimitiveClient, deleteDomain, deleteEmail, deleteEndpoint, deleteFilter, deleteFunction, deleteFunctionSecret, discardEmailContent, downloadAttachments, downloadRawEmail, getAccount, getEmail, getFunction, getFunctionTestRunTrace, getSendPermissions, getSentEmail, getStorageStats, getWebhookSecret, listDeliveries, listDomains, listEmails, listEndpoints, listFilters, listFunctionLogs, listFunctionSecrets, listFunctions, listSentEmails, normalizeReceivedEmail, openapiDocument, operationManifest, sdk_gen_exports as operations, pollCliLogin, replayDelivery, replayEmailWebhooks, replyToEmail, resendCliSignupVerification, rotateWebhookSecret, searchEmails, sendEmail, setFunctionSecret, startCliLogin, startCliSignup, testEndpoint, testFunction, updateAccount, updateDomain, updateEndpoint, updateFilter, updateFunction, verifyCliSignup, verifyDomain, verifyWebhookSignature };
|
|
@@ -1460,9 +1460,8 @@ const getSentEmail = (options) => (options.client ?? client$1).get({
|
|
|
1460
1460
|
* List functions
|
|
1461
1461
|
*
|
|
1462
1462
|
* Returns every active (non-deleted) function in the org, newest
|
|
1463
|
-
* first. Each entry carries
|
|
1464
|
-
*
|
|
1465
|
-
* the source code or deploy errors, use `GET /functions/{id}`.
|
|
1463
|
+
* first. Each entry carries deploy status and timestamps. To
|
|
1464
|
+
* inspect the source code or deploy errors, use `GET /functions/{id}`.
|
|
1466
1465
|
*
|
|
1467
1466
|
*/
|
|
1468
1467
|
const listFunctions = (options) => (options?.client ?? client$1).get({
|
|
@@ -1478,13 +1477,14 @@ const listFunctions = (options) => (options?.client ?? client$1).get({
|
|
|
1478
1477
|
*
|
|
1479
1478
|
* Creates and deploys a new function. The handler must be a single
|
|
1480
1479
|
* ESM module whose default export is an object with an async
|
|
1481
|
-
* `fetch(request, env)` method (Workers-style).
|
|
1482
|
-
*
|
|
1483
|
-
*
|
|
1484
|
-
* `
|
|
1485
|
-
*
|
|
1486
|
-
*
|
|
1487
|
-
*
|
|
1480
|
+
* `fetch(request, env)` method (Workers-style). Primitive signs
|
|
1481
|
+
* each delivery and forwards the `Primitive-Signature` header to
|
|
1482
|
+
* the handler. Verify the raw request body with
|
|
1483
|
+
* `PRIMITIVE_WEBHOOK_SECRET` before parsing JSON; after verification
|
|
1484
|
+
* the request body parses to an `email.received` event (see
|
|
1485
|
+
* `EmailReceivedEvent` and the Webhook payload section for the full
|
|
1486
|
+
* schema). Code is bundled before being uploaded; ship a single
|
|
1487
|
+
* self-contained file rather than relying on external imports.
|
|
1488
1488
|
*
|
|
1489
1489
|
* **Code limits.** `code` is capped at 1 MiB UTF-8. `sourceMap`
|
|
1490
1490
|
* (optional) is capped at 5 MiB UTF-8, stored with each deployment
|
|
@@ -1494,12 +1494,12 @@ const listFunctions = (options) => (options?.client ?? client$1).get({
|
|
|
1494
1494
|
* **Auto-wiring.** On successful deploy, Primitive automatically
|
|
1495
1495
|
* creates a webhook endpoint that delivers inbound mail to the
|
|
1496
1496
|
* function. There is nothing to configure on the Endpoints API
|
|
1497
|
-
* for this to work; the
|
|
1498
|
-
*
|
|
1497
|
+
* for this to work; the internal runtime URL is not returned by
|
|
1498
|
+
* the API and is not a customer-facing integration surface.
|
|
1499
1499
|
*
|
|
1500
1500
|
* **Secrets.** New functions ship with the managed secrets
|
|
1501
|
-
* (`PRIMITIVE_WEBHOOK_SECRET`, `PRIMITIVE_API_KEY
|
|
1502
|
-
* bound. Add user-set secrets via
|
|
1501
|
+
* (`PRIMITIVE_WEBHOOK_SECRET`, `PRIMITIVE_API_KEY`,
|
|
1502
|
+
* `PRIMITIVE_API_BASE_URL`) already bound. Add user-set secrets via
|
|
1503
1503
|
* `POST /functions/{id}/secrets`; secret writes only land in the
|
|
1504
1504
|
* running handler on the next redeploy.
|
|
1505
1505
|
*
|
|
@@ -1645,9 +1645,9 @@ const getFunctionTestRunTrace = (options) => (options.client ?? client$1).get({
|
|
|
1645
1645
|
* never returned.** Secret writes are write-only.
|
|
1646
1646
|
*
|
|
1647
1647
|
* Managed entries (e.g. `PRIMITIVE_WEBHOOK_SECRET`,
|
|
1648
|
-
* `PRIMITIVE_API_KEY`) carry a
|
|
1649
|
-
* `created_at` / `updated_at`. They
|
|
1650
|
-
* or deleted via this API.
|
|
1648
|
+
* `PRIMITIVE_API_KEY`, `PRIMITIVE_API_BASE_URL`) carry a
|
|
1649
|
+
* `description` instead of `created_at` / `updated_at`. They
|
|
1650
|
+
* cannot be created, updated, or deleted via this API.
|
|
1651
1651
|
*
|
|
1652
1652
|
*/
|
|
1653
1653
|
const listFunctionSecrets = (options) => (options.client ?? client$1).get({
|
|
@@ -1672,13 +1672,6 @@ type FunctionListItem = {
|
|
|
1672
1672
|
* Timestamp of the most recent successful deploy. Null until the first deploy succeeds.
|
|
1673
1673
|
*/
|
|
1674
1674
|
deployed_at?: string | null;
|
|
1675
|
-
/**
|
|
1676
|
-
* URL the platform's webhook delivery loop posts to in order
|
|
1677
|
-
* to invoke the function. Reference only; not directly
|
|
1678
|
-
* callable from outside.
|
|
1679
|
-
*
|
|
1680
|
-
*/
|
|
1681
|
-
gateway_url: string;
|
|
1682
1675
|
created_at: string;
|
|
1683
1676
|
updated_at: string;
|
|
1684
1677
|
};
|
|
@@ -1703,7 +1696,6 @@ type FunctionDetail = {
|
|
|
1703
1696
|
*/
|
|
1704
1697
|
deploy_error?: string | null;
|
|
1705
1698
|
deployed_at?: string | null;
|
|
1706
|
-
gateway_url: string;
|
|
1707
1699
|
created_at: string;
|
|
1708
1700
|
updated_at: string;
|
|
1709
1701
|
};
|
|
@@ -1737,7 +1729,6 @@ type CreateFunctionResult = {
|
|
|
1737
1729
|
id: string;
|
|
1738
1730
|
name: string;
|
|
1739
1731
|
deploy_status: FunctionDeployStatus;
|
|
1740
|
-
gateway_url: string;
|
|
1741
1732
|
};
|
|
1742
1733
|
type UpdateFunctionInput = {
|
|
1743
1734
|
/**
|
|
@@ -1994,7 +1985,8 @@ type CreateFunctionSecretInput = {
|
|
|
1994
1985
|
/**
|
|
1995
1986
|
* Uppercase letters, digits, and underscores. Must start with
|
|
1996
1987
|
* a letter or underscore. System-managed keys (e.g.
|
|
1997
|
-
* PRIMITIVE_WEBHOOK_SECRET
|
|
1988
|
+
* PRIMITIVE_WEBHOOK_SECRET, PRIMITIVE_API_KEY, and
|
|
1989
|
+
* PRIMITIVE_API_BASE_URL) are reserved.
|
|
1998
1990
|
*
|
|
1999
1991
|
*/
|
|
2000
1992
|
key: string;
|
|
@@ -4525,9 +4517,8 @@ declare const getSentEmail: <ThrowOnError extends boolean = false>(options: Opti
|
|
|
4525
4517
|
* List functions
|
|
4526
4518
|
*
|
|
4527
4519
|
* Returns every active (non-deleted) function in the org, newest
|
|
4528
|
-
* first. Each entry carries
|
|
4529
|
-
*
|
|
4530
|
-
* the source code or deploy errors, use `GET /functions/{id}`.
|
|
4520
|
+
* first. Each entry carries deploy status and timestamps. To
|
|
4521
|
+
* inspect the source code or deploy errors, use `GET /functions/{id}`.
|
|
4531
4522
|
*
|
|
4532
4523
|
*/
|
|
4533
4524
|
declare const listFunctions: <ThrowOnError extends boolean = false>(options?: Options<ListFunctionsData, ThrowOnError>) => RequestResult<ListFunctionsResponses, ListFunctionsErrors, ThrowOnError, "fields">;
|
|
@@ -4536,13 +4527,14 @@ declare const listFunctions: <ThrowOnError extends boolean = false>(options?: Op
|
|
|
4536
4527
|
*
|
|
4537
4528
|
* Creates and deploys a new function. The handler must be a single
|
|
4538
4529
|
* ESM module whose default export is an object with an async
|
|
4539
|
-
* `fetch(request, env)` method (Workers-style).
|
|
4540
|
-
*
|
|
4541
|
-
*
|
|
4542
|
-
* `
|
|
4543
|
-
*
|
|
4544
|
-
*
|
|
4545
|
-
*
|
|
4530
|
+
* `fetch(request, env)` method (Workers-style). Primitive signs
|
|
4531
|
+
* each delivery and forwards the `Primitive-Signature` header to
|
|
4532
|
+
* the handler. Verify the raw request body with
|
|
4533
|
+
* `PRIMITIVE_WEBHOOK_SECRET` before parsing JSON; after verification
|
|
4534
|
+
* the request body parses to an `email.received` event (see
|
|
4535
|
+
* `EmailReceivedEvent` and the Webhook payload section for the full
|
|
4536
|
+
* schema). Code is bundled before being uploaded; ship a single
|
|
4537
|
+
* self-contained file rather than relying on external imports.
|
|
4546
4538
|
*
|
|
4547
4539
|
* **Code limits.** `code` is capped at 1 MiB UTF-8. `sourceMap`
|
|
4548
4540
|
* (optional) is capped at 5 MiB UTF-8, stored with each deployment
|
|
@@ -4552,12 +4544,12 @@ declare const listFunctions: <ThrowOnError extends boolean = false>(options?: Op
|
|
|
4552
4544
|
* **Auto-wiring.** On successful deploy, Primitive automatically
|
|
4553
4545
|
* creates a webhook endpoint that delivers inbound mail to the
|
|
4554
4546
|
* function. There is nothing to configure on the Endpoints API
|
|
4555
|
-
* for this to work; the
|
|
4556
|
-
*
|
|
4547
|
+
* for this to work; the internal runtime URL is not returned by
|
|
4548
|
+
* the API and is not a customer-facing integration surface.
|
|
4557
4549
|
*
|
|
4558
4550
|
* **Secrets.** New functions ship with the managed secrets
|
|
4559
|
-
* (`PRIMITIVE_WEBHOOK_SECRET`, `PRIMITIVE_API_KEY
|
|
4560
|
-
* bound. Add user-set secrets via
|
|
4551
|
+
* (`PRIMITIVE_WEBHOOK_SECRET`, `PRIMITIVE_API_KEY`,
|
|
4552
|
+
* `PRIMITIVE_API_BASE_URL`) already bound. Add user-set secrets via
|
|
4561
4553
|
* `POST /functions/{id}/secrets`; secret writes only land in the
|
|
4562
4554
|
* running handler on the next redeploy.
|
|
4563
4555
|
*
|
|
@@ -4649,9 +4641,9 @@ declare const getFunctionTestRunTrace: <ThrowOnError extends boolean = false>(op
|
|
|
4649
4641
|
* never returned.** Secret writes are write-only.
|
|
4650
4642
|
*
|
|
4651
4643
|
* Managed entries (e.g. `PRIMITIVE_WEBHOOK_SECRET`,
|
|
4652
|
-
* `PRIMITIVE_API_KEY`) carry a
|
|
4653
|
-
* `created_at` / `updated_at`. They
|
|
4654
|
-
* or deleted via this API.
|
|
4644
|
+
* `PRIMITIVE_API_KEY`, `PRIMITIVE_API_BASE_URL`) carry a
|
|
4645
|
+
* `description` instead of `created_at` / `updated_at`. They
|
|
4646
|
+
* cannot be created, updated, or deleted via this API.
|
|
4655
4647
|
*
|
|
4656
4648
|
*/
|
|
4657
4649
|
declare const listFunctionSecrets: <ThrowOnError extends boolean = false>(options: Options<ListFunctionSecretsData, ThrowOnError>) => RequestResult<ListFunctionSecretsResponses, ListFunctionSecretsErrors, ThrowOnError, "fields">;
|
package/dist/index.d.ts
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as SendThreadInput, i as ReplyInput, l as client, n as PrimitiveClient, o as SendInput, r as PrimitiveClientOptions, s as SendResult, t as ForwardInput, u as createPrimitiveClient, v as PrimitiveApiError } from "./index-
|
|
1
|
+
import { c as SendThreadInput, i as ReplyInput, l as client, n as PrimitiveClient, o as SendInput, r as PrimitiveClientOptions, s as SendResult, t as ForwardInput, u as createPrimitiveClient, v as PrimitiveApiError } from "./index-BwDgniCA.js";
|
|
2
2
|
import { A as UnknownEvent, C as ParsedDataFailed, D as RawContentDownloadOnly, E as RawContent, M as WebhookAttachment, N as WebhookEvent, O as RawContentInline, S as ParsedDataComplete, T as ParsedStatus, _ as ForwardResultInline, a as DmarcPolicy, b as KnownWebhookEvent, c as EmailAnalysis, d as EventType, f as ForwardAnalysis, g as ForwardResultAttachmentSkipped, h as ForwardResultAttachmentAnalyzed, i as DkimSignature, j as ValidateEmailAuthResult, k as SpfResult, l as EmailAuth, m as ForwardResult, n as AuthVerdict, o as DmarcResult, p as ForwardOriginalSender, r as DkimResult, s as EmailAddress, t as AuthConfidence, u as EmailReceivedEvent, v as ForwardVerdict, w as ParsedError, x as ParsedData, y as ForwardVerification } from "./types-BRWDMD7H.js";
|
|
3
3
|
import { _ as buildForwardSubject, a as RawEmailDecodeErrorCode, b as normalizeReceivedEmail, c as WebhookPayloadError, d as WebhookValidationErrorCode, f as WebhookVerificationError, g as ReceivedEmailThread, h as ReceivedEmailAddress, i as RawEmailDecodeError, l as WebhookPayloadErrorCode, m as ReceivedEmail, n as PrimitiveWebhookError, o as VERIFICATION_ERRORS, p as WebhookVerificationErrorCode, r as RAW_EMAIL_ERRORS, s as WebhookErrorCode, t as PAYLOAD_ERRORS, u as WebhookValidationError, v as buildReplySubject, x as parseHeaderAddress, y as formatAddress } from "./errors-CO-rv_nK.js";
|
|
4
4
|
import { A as VerifyOptions, C as signStandardWebhooksPayload, D as PRIMITIVE_CONFIRMED_HEADER, E as LEGACY_SIGNATURE_HEADER, F as VerifyDownloadTokenResult, I as generateDownloadToken, L as verifyDownloadToken, M as verifyWebhookSignature, N as GenerateDownloadTokenOptions, O as PRIMITIVE_SIGNATURE_HEADER, P as VerifyDownloadTokenOptions, R as safeValidateEmailReceivedEvent, S as StandardWebhooksVerifyOptions, T as LEGACY_CONFIRMED_HEADER, _ as emailReceivedEventJsonSchema, a as confirmedHeaders, b as STANDARD_WEBHOOK_TIMESTAMP_HEADER, c as handleWebhook, d as isRawIncluded, f as parseWebhookEvent, g as validateEmailAuth, h as WEBHOOK_VERSION, i as WebhookHeaders, j as signWebhookPayload, k as SignResult, l as isDownloadExpired, m as verifyRawEmailDownload, n as HandleWebhookOptions, o as decodeRawEmail, p as receive, r as ReceiveRequestOptions, s as getDownloadTimeRemaining, t as DecodeRawEmailOptions, u as isEmailReceivedEvent, v as STANDARD_WEBHOOK_ID_HEADER, w as verifyStandardWebhooksSignature, x as StandardWebhooksSignResult, y as STANDARD_WEBHOOK_SIGNATURE_HEADER, z as validateEmailReceivedEvent } from "./index-D_v8-0zX.js";
|
package/dist/index.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { l as PrimitiveApiError, n as client, r as createPrimitiveClient, t as PrimitiveClient } from "./api-
|
|
1
|
+
import { l as PrimitiveApiError, n as client, r as createPrimitiveClient, t as PrimitiveClient } from "./api-CMzxyIqH.js";
|
|
2
2
|
import { a as VERIFICATION_ERRORS, c as WebhookVerificationError, d as formatAddress, f as normalizeReceivedEmail, i as RawEmailDecodeError, l as buildForwardSubject, n as PrimitiveWebhookError, o as WebhookPayloadError, p as parseHeaderAddress, r as RAW_EMAIL_ERRORS, s as WebhookValidationError, t as PAYLOAD_ERRORS, u as buildReplySubject } from "./errors-BPJGp9I6.js";
|
|
3
3
|
import { A as PRIMITIVE_CONFIRMED_HEADER, C as STANDARD_WEBHOOK_ID_HEADER, D as verifyStandardWebhooksSignature, E as signStandardWebhooksPayload, F as verifyDownloadToken, I as safeValidateEmailReceivedEvent, L as validateEmailReceivedEvent, M as signWebhookPayload, N as verifyWebhookSignature, O as LEGACY_CONFIRMED_HEADER, P as generateDownloadToken, S as emailReceivedEventJsonSchema, T as STANDARD_WEBHOOK_TIMESTAMP_HEADER, _ as DmarcResult, a as isDownloadExpired, b as ParsedStatus, c as parseWebhookEvent, d as WEBHOOK_VERSION, f as validateEmailAuth, g as DmarcPolicy, h as DkimResult, i as handleWebhook, j as PRIMITIVE_SIGNATURE_HEADER, k as LEGACY_SIGNATURE_HEADER, l as receive, m as AuthVerdict, n as decodeRawEmail, o as isEmailReceivedEvent, p as AuthConfidence, r as getDownloadTimeRemaining, s as isRawIncluded, t as confirmedHeaders, u as verifyRawEmailDownload, v as EventType, w as STANDARD_WEBHOOK_SIGNATURE_HEADER, x as SpfResult, y as ForwardVerdict } from "./webhook-D4FTpj38.js";
|
|
4
4
|
//#region src/index.ts
|
package/dist/openapi/index.js
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
import { n as openapiDocument, t as operationManifest } from "../operations.generated-
|
|
1
|
+
import { n as openapiDocument, t as operationManifest } from "../operations.generated-BOlpIYkQ.js";
|
|
2
2
|
export { openapiDocument, operationManifest };
|
|
@@ -63,7 +63,7 @@ const openapiDocument = {
|
|
|
63
63
|
},
|
|
64
64
|
{
|
|
65
65
|
"name": "Functions",
|
|
66
|
-
"description": "Deploy JavaScript handlers that run on inbound mail. Each function\nis a single ESM module whose default export is an object with an\nasync `fetch(request, env)` method, in the shape of a Workers-style\nhandler.
|
|
66
|
+
"description": "Deploy JavaScript handlers that run on inbound mail. Each function\nis a single ESM module whose default export is an object with an\nasync `fetch(request, env)` method, in the shape of a Workers-style\nhandler. Primitive signs each delivery and forwards the\n`Primitive-Signature` header to the handler; verify the raw request\nbody with `PRIMITIVE_WEBHOOK_SECRET` before trusting the parsed\n`email.received` event (see `EmailReceivedEvent` and the Webhook\npayload section for the full schema). Code runs on\nPrimitive's edge runtime; there is no infrastructure to manage.\nSecrets land in `env` as encrypted bindings and are refreshed on\nevery redeploy.\n"
|
|
67
67
|
}
|
|
68
68
|
],
|
|
69
69
|
"paths": {
|
|
@@ -1403,7 +1403,7 @@ const openapiDocument = {
|
|
|
1403
1403
|
"get": {
|
|
1404
1404
|
"operationId": "listFunctions",
|
|
1405
1405
|
"summary": "List functions",
|
|
1406
|
-
"description": "Returns every active (non-deleted) function in the org, newest\nfirst. Each entry carries
|
|
1406
|
+
"description": "Returns every active (non-deleted) function in the org, newest\nfirst. Each entry carries deploy status and timestamps. To\ninspect the source code or deploy errors, use `GET /functions/{id}`.\n",
|
|
1407
1407
|
"tags": ["Functions"],
|
|
1408
1408
|
"responses": {
|
|
1409
1409
|
"200": {
|
|
@@ -1422,7 +1422,7 @@ const openapiDocument = {
|
|
|
1422
1422
|
"post": {
|
|
1423
1423
|
"operationId": "createFunction",
|
|
1424
1424
|
"summary": "Deploy a function",
|
|
1425
|
-
"description": "Creates and deploys a new function. The handler must be a single\nESM module whose default export is an object with an async\n`fetch(request, env)` method (Workers-style).
|
|
1425
|
+
"description": "Creates and deploys a new function. The handler must be a single\nESM module whose default export is an object with an async\n`fetch(request, env)` method (Workers-style). Primitive signs\neach delivery and forwards the `Primitive-Signature` header to\nthe handler. Verify the raw request body with\n`PRIMITIVE_WEBHOOK_SECRET` before parsing JSON; after verification\nthe request body parses to an `email.received` event (see\n`EmailReceivedEvent` and the Webhook payload section for the full\nschema). Code is bundled before being uploaded; ship a single\nself-contained file rather than relying on external imports.\n\n**Code limits.** `code` is capped at 1 MiB UTF-8. `sourceMap`\n(optional) is capped at 5 MiB UTF-8, stored with each deployment\nattempt, and sent to the runtime so stack traces can resolve to\noriginal source files.\n\n**Auto-wiring.** On successful deploy, Primitive automatically\ncreates a webhook endpoint that delivers inbound mail to the\nfunction. There is nothing to configure on the Endpoints API\nfor this to work; the internal runtime URL is not returned by\nthe API and is not a customer-facing integration surface.\n\n**Secrets.** New functions ship with the managed secrets\n(`PRIMITIVE_WEBHOOK_SECRET`, `PRIMITIVE_API_KEY`,\n`PRIMITIVE_API_BASE_URL`) already bound. Add user-set secrets via\n`POST /functions/{id}/secrets`; secret writes only land in the\nrunning handler on the next redeploy.\n",
|
|
1426
1426
|
"tags": ["Functions"],
|
|
1427
1427
|
"requestBody": {
|
|
1428
1428
|
"required": true,
|
|
@@ -1591,7 +1591,7 @@ const openapiDocument = {
|
|
|
1591
1591
|
"get": {
|
|
1592
1592
|
"operationId": "listFunctionSecrets",
|
|
1593
1593
|
"summary": "List a function's secrets",
|
|
1594
|
-
"description": "Returns metadata for every secret bound to the function, with\nmanaged entries (provisioned by Primitive) listed first and\nuser-set entries listed alphabetically after. **Values are\nnever returned.** Secret writes are write-only.\n\nManaged entries (e.g. `PRIMITIVE_WEBHOOK_SECRET`,\n`PRIMITIVE_API_KEY`) carry a
|
|
1594
|
+
"description": "Returns metadata for every secret bound to the function, with\nmanaged entries (provisioned by Primitive) listed first and\nuser-set entries listed alphabetically after. **Values are\nnever returned.** Secret writes are write-only.\n\nManaged entries (e.g. `PRIMITIVE_WEBHOOK_SECRET`,\n`PRIMITIVE_API_KEY`, `PRIMITIVE_API_BASE_URL`) carry a\n`description` instead of `created_at` / `updated_at`. They\ncannot be created, updated, or deleted via this API.\n",
|
|
1595
1595
|
"tags": ["Functions"],
|
|
1596
1596
|
"responses": {
|
|
1597
1597
|
"200": {
|
|
@@ -3757,11 +3757,6 @@ const openapiDocument = {
|
|
|
3757
3757
|
"format": "date-time",
|
|
3758
3758
|
"description": "Timestamp of the most recent successful deploy. Null until the first deploy succeeds."
|
|
3759
3759
|
},
|
|
3760
|
-
"gateway_url": {
|
|
3761
|
-
"type": "string",
|
|
3762
|
-
"format": "uri",
|
|
3763
|
-
"description": "URL the platform's webhook delivery loop posts to in order\nto invoke the function. Reference only; not directly\ncallable from outside.\n"
|
|
3764
|
-
},
|
|
3765
3760
|
"created_at": {
|
|
3766
3761
|
"type": "string",
|
|
3767
3762
|
"format": "date-time"
|
|
@@ -3775,7 +3770,6 @@ const openapiDocument = {
|
|
|
3775
3770
|
"id",
|
|
3776
3771
|
"name",
|
|
3777
3772
|
"deploy_status",
|
|
3778
|
-
"gateway_url",
|
|
3779
3773
|
"created_at",
|
|
3780
3774
|
"updated_at"
|
|
3781
3775
|
]
|
|
@@ -3802,10 +3796,6 @@ const openapiDocument = {
|
|
|
3802
3796
|
"type": ["string", "null"],
|
|
3803
3797
|
"format": "date-time"
|
|
3804
3798
|
},
|
|
3805
|
-
"gateway_url": {
|
|
3806
|
-
"type": "string",
|
|
3807
|
-
"format": "uri"
|
|
3808
|
-
},
|
|
3809
3799
|
"created_at": {
|
|
3810
3800
|
"type": "string",
|
|
3811
3801
|
"format": "date-time"
|
|
@@ -3820,7 +3810,6 @@ const openapiDocument = {
|
|
|
3820
3810
|
"name",
|
|
3821
3811
|
"code",
|
|
3822
3812
|
"deploy_status",
|
|
3823
|
-
"gateway_url",
|
|
3824
3813
|
"created_at",
|
|
3825
3814
|
"updated_at"
|
|
3826
3815
|
]
|
|
@@ -3858,17 +3847,12 @@ const openapiDocument = {
|
|
|
3858
3847
|
"format": "uuid"
|
|
3859
3848
|
},
|
|
3860
3849
|
"name": { "type": "string" },
|
|
3861
|
-
"deploy_status": { "$ref": "#/components/schemas/FunctionDeployStatus" }
|
|
3862
|
-
"gateway_url": {
|
|
3863
|
-
"type": "string",
|
|
3864
|
-
"format": "uri"
|
|
3865
|
-
}
|
|
3850
|
+
"deploy_status": { "$ref": "#/components/schemas/FunctionDeployStatus" }
|
|
3866
3851
|
},
|
|
3867
3852
|
"required": [
|
|
3868
3853
|
"id",
|
|
3869
3854
|
"name",
|
|
3870
|
-
"deploy_status"
|
|
3871
|
-
"gateway_url"
|
|
3855
|
+
"deploy_status"
|
|
3872
3856
|
]
|
|
3873
3857
|
},
|
|
3874
3858
|
"UpdateFunctionInput": {
|
|
@@ -4344,7 +4328,7 @@ const openapiDocument = {
|
|
|
4344
4328
|
"key": {
|
|
4345
4329
|
"type": "string",
|
|
4346
4330
|
"pattern": "^[A-Z_][A-Z0-9_]*$",
|
|
4347
|
-
"description": "Uppercase letters, digits, and underscores. Must start with\na letter or underscore. System-managed keys (e.g.\nPRIMITIVE_WEBHOOK_SECRET) are reserved.\n"
|
|
4331
|
+
"description": "Uppercase letters, digits, and underscores. Must start with\na letter or underscore. System-managed keys (e.g.\nPRIMITIVE_WEBHOOK_SECRET, PRIMITIVE_API_KEY, and\nPRIMITIVE_API_BASE_URL) are reserved.\n"
|
|
4348
4332
|
},
|
|
4349
4333
|
"value": {
|
|
4350
4334
|
"type": "string",
|
|
@@ -6669,7 +6653,7 @@ const operationManifest = [
|
|
|
6669
6653
|
"binaryResponse": false,
|
|
6670
6654
|
"bodyRequired": true,
|
|
6671
6655
|
"command": "create-function",
|
|
6672
|
-
"description": "Creates and deploys a new function. The handler must be a single\nESM module whose default export is an object with an async\n`fetch(request, env)` method (Workers-style).
|
|
6656
|
+
"description": "Creates and deploys a new function. The handler must be a single\nESM module whose default export is an object with an async\n`fetch(request, env)` method (Workers-style). Primitive signs\neach delivery and forwards the `Primitive-Signature` header to\nthe handler. Verify the raw request body with\n`PRIMITIVE_WEBHOOK_SECRET` before parsing JSON; after verification\nthe request body parses to an `email.received` event (see\n`EmailReceivedEvent` and the Webhook payload section for the full\nschema). Code is bundled before being uploaded; ship a single\nself-contained file rather than relying on external imports.\n\n**Code limits.** `code` is capped at 1 MiB UTF-8. `sourceMap`\n(optional) is capped at 5 MiB UTF-8, stored with each deployment\nattempt, and sent to the runtime so stack traces can resolve to\noriginal source files.\n\n**Auto-wiring.** On successful deploy, Primitive automatically\ncreates a webhook endpoint that delivers inbound mail to the\nfunction. There is nothing to configure on the Endpoints API\nfor this to work; the internal runtime URL is not returned by\nthe API and is not a customer-facing integration surface.\n\n**Secrets.** New functions ship with the managed secrets\n(`PRIMITIVE_WEBHOOK_SECRET`, `PRIMITIVE_API_KEY`,\n`PRIMITIVE_API_BASE_URL`) already bound. Add user-set secrets via\n`POST /functions/{id}/secrets`; secret writes only land in the\nrunning handler on the next redeploy.\n",
|
|
6673
6657
|
"hasJsonBody": true,
|
|
6674
6658
|
"method": "POST",
|
|
6675
6659
|
"operationId": "createFunction",
|
|
@@ -6717,17 +6701,12 @@ const operationManifest = [
|
|
|
6717
6701
|
"failed"
|
|
6718
6702
|
],
|
|
6719
6703
|
"description": "Lifecycle state of the latest deploy attempt:\n * `pending` — deploy in flight; the runtime has not yet\n confirmed the new bundle is live.\n * `deployed` — the running edge handler is the latest code.\n * `failed` — the most recent deploy attempt failed; the\n previously-live code (if any) is still running. The\n `deploy_error` field carries the error message.\n"
|
|
6720
|
-
},
|
|
6721
|
-
"gateway_url": {
|
|
6722
|
-
"type": "string",
|
|
6723
|
-
"format": "uri"
|
|
6724
6704
|
}
|
|
6725
6705
|
},
|
|
6726
6706
|
"required": [
|
|
6727
6707
|
"id",
|
|
6728
6708
|
"name",
|
|
6729
|
-
"deploy_status"
|
|
6730
|
-
"gateway_url"
|
|
6709
|
+
"deploy_status"
|
|
6731
6710
|
]
|
|
6732
6711
|
},
|
|
6733
6712
|
"sdkName": "createFunction",
|
|
@@ -6760,7 +6739,7 @@ const operationManifest = [
|
|
|
6760
6739
|
"key": {
|
|
6761
6740
|
"type": "string",
|
|
6762
6741
|
"pattern": "^[A-Z_][A-Z0-9_]*$",
|
|
6763
|
-
"description": "Uppercase letters, digits, and underscores. Must start with\na letter or underscore. System-managed keys (e.g.\nPRIMITIVE_WEBHOOK_SECRET) are reserved.\n"
|
|
6742
|
+
"description": "Uppercase letters, digits, and underscores. Must start with\na letter or underscore. System-managed keys (e.g.\nPRIMITIVE_WEBHOOK_SECRET, PRIMITIVE_API_KEY, and\nPRIMITIVE_API_BASE_URL) are reserved.\n"
|
|
6764
6743
|
},
|
|
6765
6744
|
"value": {
|
|
6766
6745
|
"type": "string",
|
|
@@ -6903,10 +6882,6 @@ const operationManifest = [
|
|
|
6903
6882
|
"type": ["string", "null"],
|
|
6904
6883
|
"format": "date-time"
|
|
6905
6884
|
},
|
|
6906
|
-
"gateway_url": {
|
|
6907
|
-
"type": "string",
|
|
6908
|
-
"format": "uri"
|
|
6909
|
-
},
|
|
6910
6885
|
"created_at": {
|
|
6911
6886
|
"type": "string",
|
|
6912
6887
|
"format": "date-time"
|
|
@@ -6921,7 +6896,6 @@ const operationManifest = [
|
|
|
6921
6896
|
"name",
|
|
6922
6897
|
"code",
|
|
6923
6898
|
"deploy_status",
|
|
6924
|
-
"gateway_url",
|
|
6925
6899
|
"created_at",
|
|
6926
6900
|
"updated_at"
|
|
6927
6901
|
]
|
|
@@ -7467,7 +7441,7 @@ const operationManifest = [
|
|
|
7467
7441
|
"binaryResponse": false,
|
|
7468
7442
|
"bodyRequired": false,
|
|
7469
7443
|
"command": "list-function-secrets",
|
|
7470
|
-
"description": "Returns metadata for every secret bound to the function, with\nmanaged entries (provisioned by Primitive) listed first and\nuser-set entries listed alphabetically after. **Values are\nnever returned.** Secret writes are write-only.\n\nManaged entries (e.g. `PRIMITIVE_WEBHOOK_SECRET`,\n`PRIMITIVE_API_KEY`) carry a
|
|
7444
|
+
"description": "Returns metadata for every secret bound to the function, with\nmanaged entries (provisioned by Primitive) listed first and\nuser-set entries listed alphabetically after. **Values are\nnever returned.** Secret writes are write-only.\n\nManaged entries (e.g. `PRIMITIVE_WEBHOOK_SECRET`,\n`PRIMITIVE_API_KEY`, `PRIMITIVE_API_BASE_URL`) carry a\n`description` instead of `created_at` / `updated_at`. They\ncannot be created, updated, or deleted via this API.\n",
|
|
7471
7445
|
"hasJsonBody": false,
|
|
7472
7446
|
"method": "GET",
|
|
7473
7447
|
"operationId": "listFunctionSecrets",
|
|
@@ -7523,7 +7497,7 @@ const operationManifest = [
|
|
|
7523
7497
|
"binaryResponse": false,
|
|
7524
7498
|
"bodyRequired": false,
|
|
7525
7499
|
"command": "list-functions",
|
|
7526
|
-
"description": "Returns every active (non-deleted) function in the org, newest\nfirst. Each entry carries
|
|
7500
|
+
"description": "Returns every active (non-deleted) function in the org, newest\nfirst. Each entry carries deploy status and timestamps. To\ninspect the source code or deploy errors, use `GET /functions/{id}`.\n",
|
|
7527
7501
|
"hasJsonBody": false,
|
|
7528
7502
|
"method": "GET",
|
|
7529
7503
|
"operationId": "listFunctions",
|
|
@@ -7560,11 +7534,6 @@ const operationManifest = [
|
|
|
7560
7534
|
"format": "date-time",
|
|
7561
7535
|
"description": "Timestamp of the most recent successful deploy. Null until the first deploy succeeds."
|
|
7562
7536
|
},
|
|
7563
|
-
"gateway_url": {
|
|
7564
|
-
"type": "string",
|
|
7565
|
-
"format": "uri",
|
|
7566
|
-
"description": "URL the platform's webhook delivery loop posts to in order\nto invoke the function. Reference only; not directly\ncallable from outside.\n"
|
|
7567
|
-
},
|
|
7568
7537
|
"created_at": {
|
|
7569
7538
|
"type": "string",
|
|
7570
7539
|
"format": "date-time"
|
|
@@ -7578,7 +7547,6 @@ const operationManifest = [
|
|
|
7578
7547
|
"id",
|
|
7579
7548
|
"name",
|
|
7580
7549
|
"deploy_status",
|
|
7581
|
-
"gateway_url",
|
|
7582
7550
|
"created_at",
|
|
7583
7551
|
"updated_at"
|
|
7584
7552
|
]
|
|
@@ -7807,10 +7775,6 @@ const operationManifest = [
|
|
|
7807
7775
|
"type": ["string", "null"],
|
|
7808
7776
|
"format": "date-time"
|
|
7809
7777
|
},
|
|
7810
|
-
"gateway_url": {
|
|
7811
|
-
"type": "string",
|
|
7812
|
-
"format": "uri"
|
|
7813
|
-
},
|
|
7814
7778
|
"created_at": {
|
|
7815
7779
|
"type": "string",
|
|
7816
7780
|
"format": "date-time"
|
|
@@ -7825,7 +7789,6 @@ const operationManifest = [
|
|
|
7825
7789
|
"name",
|
|
7826
7790
|
"code",
|
|
7827
7791
|
"deploy_status",
|
|
7828
|
-
"gateway_url",
|
|
7829
7792
|
"created_at",
|
|
7830
7793
|
"updated_at"
|
|
7831
7794
|
]
|
package/package.json
CHANGED