Skip to content
Start here

Accounts

List Accounts
client.accounts.list(AccountListParams { direction, name, page, per_page } query?, RequestOptionsoptions?): V4PagePaginationArray<Account { id, name, type, 3 more } >
GET/accounts
Account Details
client.accounts.get(AccountGetParams { account_id } params, RequestOptionsoptions?): Account { id, name, type, 3 more }
GET/accounts/{account_id}
Create an account
client.accounts.create(AccountCreateParams { name, type, unit } body, RequestOptionsoptions?): Account { id, name, type, 3 more }
POST/accounts
Update Account
client.accounts.update(AccountUpdateParams { account_id, id, name, 3 more } params, RequestOptionsoptions?): Account { id, name, type, 3 more }
PUT/accounts/{account_id}
Delete a specific account
client.accounts.delete(AccountDeleteParams { account_id } params, RequestOptionsoptions?): AccountDeleteResponse { id } | null
DELETE/accounts/{account_id}
ModelsExpand Collapse
Account { id, name, type, 3 more }
id: string

Identifier

maxLength32
minLength32
name: string

Account name

maxLength100
type: "standard" | "enterprise"
One of the following:
"standard"
"enterprise"
created_on?: string

Timestamp for the creation of the account

formatdate-time
managed_by?: ManagedBy { parent_org_id, parent_org_name }

Parent container details

parent_org_id?: string

ID of the parent Organization, if one exists

maxLength32
parent_org_name?: string

Name of the parent Organization, if one exists

settings?: Settings { abuse_contact_email, enforce_twofactor }

Account settings

abuse_contact_email?: string

Sets an abuse contact email to notify for abuse reports.

enforce_twofactor?: boolean

Indicates whether membership in this account requires that Two-Factor Authentication is enabled

AccountDeleteResponse { id }
id: string

Identifier

maxLength32
minLength32

AccountsAccount Organizations

AccountsAccount Profile

AccountsMembers

List Members
client.accounts.members.list(MemberListParams { account_id, direction, order, 3 more } params, RequestOptionsoptions?): V4PagePaginationArray<Member { id, email, policies, 3 more } >
GET/accounts/{account_id}/members
Member Details
client.accounts.members.get(stringmemberID, MemberGetParams { account_id } params, RequestOptionsoptions?): Member { id, email, policies, 3 more }
GET/accounts/{account_id}/members/{member_id}
Add Member
client.accounts.members.create(MemberCreateParamsparams, RequestOptionsoptions?): Member { id, email, policies, 3 more }
POST/accounts/{account_id}/members
Update Member
client.accounts.members.update(stringmemberID, MemberUpdateParamsparams, RequestOptionsoptions?): Member { id, email, policies, 3 more }
PUT/accounts/{account_id}/members/{member_id}
Remove Member
client.accounts.members.delete(stringmemberID, MemberDeleteParams { account_id } params, RequestOptionsoptions?): MemberDeleteResponse { id } | null
DELETE/accounts/{account_id}/members/{member_id}
ModelsExpand Collapse
Status = "member" | "invited"

Whether the user is a member of the organization or has an invitation pending.

One of the following:
"member"
"invited"
MemberDeleteResponse { id }
id: string

Identifier

maxLength32
minLength32

AccountsRoles

List Roles
Deprecated
client.accounts.roles.list(RoleListParams { account_id, page, per_page } params, RequestOptionsoptions?): V4PagePaginationArray<Role { id, description, name, permissions } >
GET/accounts/{account_id}/roles
Role Details
Deprecated
client.accounts.roles.get(stringroleID, RoleGetParams { account_id } params, RequestOptionsoptions?): Role { id, description, name, permissions }
GET/accounts/{account_id}/roles/{role_id}

AccountsSubscriptions

List Subscriptions
client.accounts.subscriptions.get(SubscriptionGetParams { account_id, zone_id } params?, RequestOptionsoptions?): SinglePage<Subscription { id, currency, current_period_end, 5 more } >
GET/{accounts_or_zones}/{account_or_zone_id}/subscriptions
Get Subscription
client.accounts.subscriptions.getByIdentifier(stringsubscriptionIdentifier, SubscriptionGetByIdentifierParams { account_id } params, RequestOptionsoptions?): Subscription { id, currency, current_period_end, 5 more }
GET/accounts/{account_id}/subscriptions/{subscription_identifier}
Create Subscription
client.accounts.subscriptions.create(SubscriptionCreateParams { account_id, zone_id, frequency, rate_plan } params, RequestOptionsoptions?): Subscription { id, currency, current_period_end, 5 more }
POST/{accounts_or_zones}/{account_or_zone_id}/subscriptions
Update Subscription
client.accounts.subscriptions.update(stringsubscriptionIdentifier, SubscriptionUpdateParams { account_id, frequency, rate_plan } params, RequestOptionsoptions?): Subscription { id, currency, current_period_end, 5 more }
PUT/accounts/{account_id}/subscriptions/{subscription_identifier}
Delete Subscription
client.accounts.subscriptions.delete(stringsubscriptionIdentifier, SubscriptionDeleteParams { account_id } params, RequestOptionsoptions?): SubscriptionDeleteResponse { subscription_id }
DELETE/accounts/{account_id}/subscriptions/{subscription_identifier}
Cancel Delayed Downgrade
client.accounts.subscriptions.cancelDowngrade(SubscriptionCancelDowngradeParams { account_id, subscription_ids } params, RequestOptionsoptions?): SubscriptionCancelDowngradeResponse
POST/accounts/{account_id}/subscriptions/cancel-downgrade
ModelsExpand Collapse
SubscriptionDeleteResponse { subscription_id }
subscription_id?: string

Subscription identifier tag.

maxLength32
SubscriptionCancelDowngradeResponse = unknown | string | null
One of the following:
unknown
string | null

AccountsSubscriptionsCancel Reason

Create Cancel Reason
client.accounts.subscriptions.cancelReason.create(stringsubscriptionIdentifier, CancelReasonCreateParams { account_id, other, reason_code } params, RequestOptionsoptions?): CancelReasonCreateResponse { id, other, reason_code, 2 more }
POST/accounts/{account_id}/subscriptions/{subscription_identifier}/cancel-reason
Get Cancel Reason
client.accounts.subscriptions.cancelReason.get(stringsubscriptionIdentifier, CancelReasonGetParams { account_id } params, RequestOptionsoptions?): CancelReasonGetResponse { id, other, reason_code, 2 more }
GET/accounts/{account_id}/subscriptions/{subscription_identifier}/cancel-reason
ModelsExpand Collapse
CancelReasonCreateResponse { id, other, reason_code, 2 more }
id?: string

The cancel reason identifier.

other?: string

Additional cancellation details.

reason_code?: Array<string>

The cancellation reason codes.

submitted?: string

When the cancel reason was submitted.

formatdate-time
subscription_id?: string

The subscription identifier.

CancelReasonGetResponse { id, other, reason_code, 2 more }
id?: string

The cancel reason identifier.

other?: string

Additional cancellation details.

reason_code?: Array<string>

The cancellation reason codes.

submitted?: string

When the cancel reason was submitted.

formatdate-time
subscription_id?: string

The subscription identifier.

AccountsSubscriptionsActions

Append Subscription Action
client.accounts.subscriptions.actions.append(stringsubscriptionIdentifier, ActionAppendParams { account_id, frequency, rate_plan } params, RequestOptionsoptions?): Subscription { id, currency, current_period_end, 5 more }
POST/accounts/{account_id}/subscriptions/{subscription_identifier}/action/append

AccountsSubscriptionsBulk

Create Subscriptions
client.accounts.subscriptions.bulk.create(BulkCreateParams { account_id, idemp_key, coupon_code, 3 more } params, RequestOptionsoptions?): BulkCreateResponse | null
POST/accounts/{account_id}/bulk/subscriptions
ModelsExpand Collapse
BulkCreateResponse = Array<unknown> | null

AccountsTokens

List Tokens
client.accounts.tokens.list(TokenListParams { account_id, direction, include_expired, 2 more } params, RequestOptionsoptions?): V4PagePaginationArray<Token { id, condition, expires_on, 7 more } >
GET/accounts/{account_id}/tokens
Token Details
client.accounts.tokens.get(stringtokenID, TokenGetParams { account_id } params, RequestOptionsoptions?): Token { id, condition, expires_on, 7 more }
GET/accounts/{account_id}/tokens/{token_id}
Create Token
client.accounts.tokens.create(TokenCreateParams { account_id, name, policies, 3 more } params, RequestOptionsoptions?): TokenCreateResponse { id, condition, expires_on, 8 more }
POST/accounts/{account_id}/tokens
Update Token
client.accounts.tokens.update(stringtokenID, TokenUpdateParams { account_id, name, policies, 4 more } params, RequestOptionsoptions?): Token { id, condition, expires_on, 7 more }
PUT/accounts/{account_id}/tokens/{token_id}
Delete Token
client.accounts.tokens.delete(stringtokenID, TokenDeleteParams { account_id } params, RequestOptionsoptions?): TokenDeleteResponse { id } | null
DELETE/accounts/{account_id}/tokens/{token_id}
Verify Token
client.accounts.tokens.verify(TokenVerifyParams { account_id } params, RequestOptionsoptions?): TokenVerifyResponse { id, status, expires_on, not_before }
GET/accounts/{account_id}/tokens/verify
ModelsExpand Collapse
TokenCreateResponse { id, condition, expires_on, 8 more }
id?: string

Token identifier tag.

maxLength32
condition?: Condition { request_ip }
request_ip?: RequestIP { in, not_in }

Client IP restrictions.

List of IPv4/IPv6 CIDR addresses.

not_in?: Array<TokenConditionCIDRList>

List of IPv4/IPv6 CIDR addresses.

expires_on?: string

The expiration time on or after which the JWT MUST NOT be accepted for processing.

formatdate-time
issued_on?: string

The time on which the token was created.

formatdate-time
last_used_on?: string

Last time the token was used.

formatdate-time
modified_on?: string

Last time the token was modified.

formatdate-time
name?: string

Token name.

maxLength120
not_before?: string

The time before which the token MUST NOT be accepted for processing.

formatdate-time
policies?: Array<TokenPolicy { id, effect, permission_groups, resources } >

List of access policies assigned to the token.

id: string

Policy identifier.

effect: "allow" | "deny"

Allow or deny operations against the resources.

One of the following:
"allow"
"deny"
permission_groups: Array<PermissionGroup>

A set of permission groups that are specified to the policy.

id: string

Identifier of the permission group.

meta?: Meta { key, value }

Attributes associated to the permission group.

key?: string
value?: string
name?: string

Name of the permission group.

resources: Record<string, string> | Record<string, Record<string, string>>

A list of resource names that the policy applies to.

One of the following:
Record<string, string>
Record<string, Record<string, string>>
status?: "active" | "disabled" | "expired"

Status of the token.

One of the following:
"active"
"disabled"
"expired"
value?: TokenValue

The token value.

maxLength80
minLength40
TokenDeleteResponse { id }
id: string

Identifier

maxLength32
minLength32
TokenVerifyResponse { id, status, expires_on, not_before }
id: string

Token identifier tag.

maxLength32
status: "active" | "disabled" | "expired"

Status of the token.

One of the following:
"active"
"disabled"
"expired"
expires_on?: string

The expiration time on or after which the JWT MUST NOT be accepted for processing.

formatdate-time
not_before?: string

The time before which the token MUST NOT be accepted for processing.

formatdate-time

AccountsTokensPermission Groups

List Permission Groups
client.accounts.tokens.permissionGroups.list(PermissionGroupListParams { account_id, name, scope } params, RequestOptionsoptions?): SinglePage<PermissionGroupListResponse { id, category, name, scopes } >
GET/accounts/{account_id}/tokens/permission_groups
List Permission Groups
client.accounts.tokens.permissionGroups.get(PermissionGroupGetParams { account_id, name, scope } params, RequestOptionsoptions?): PermissionGroupGetResponse { id, category, name, scopes }
GET/accounts/{account_id}/tokens/permission_groups
ModelsExpand Collapse
PermissionGroupListResponse { id, category, name, scopes }
id?: string

Public ID.

category?: "developer_platform" | "ai_and_machine_learning" | "dns_and_zones" | 10 more

Product category that this permission group belongs to.

One of the following:
"developer_platform"
"ai_and_machine_learning"
"dns_and_zones"
"app_security"
"rules_and_configuration"
"cloudflare_one_and_zero_trust"
"analytics_and_logs"
"network_services"
"media"
"email_and_messaging"
"cache_and_performance"
"account_and_billing"
"other"
name?: string

Permission Group Name

scopes?: Array<"com.cloudflare.api.account" | "com.cloudflare.api.account.zone" | "com.cloudflare.api.user" | "com.cloudflare.edge.r2.bucket">

Resources to which the Permission Group is scoped

One of the following:
"com.cloudflare.api.account"
"com.cloudflare.api.account.zone"
"com.cloudflare.api.user"
"com.cloudflare.edge.r2.bucket"
PermissionGroupGetResponse = Array<PermissionGroupGetResponseItem>
id?: string

Public ID.

category?: "developer_platform" | "ai_and_machine_learning" | "dns_and_zones" | 10 more

Product category that this permission group belongs to.

One of the following:
"developer_platform"
"ai_and_machine_learning"
"dns_and_zones"
"app_security"
"rules_and_configuration"
"cloudflare_one_and_zero_trust"
"analytics_and_logs"
"network_services"
"media"
"email_and_messaging"
"cache_and_performance"
"account_and_billing"
"other"
name?: string

Permission Group Name

scopes?: Array<"com.cloudflare.api.account" | "com.cloudflare.api.account.zone" | "com.cloudflare.api.user" | "com.cloudflare.edge.r2.bucket">

Resources to which the Permission Group is scoped

One of the following:
"com.cloudflare.api.account"
"com.cloudflare.api.account.zone"
"com.cloudflare.api.user"
"com.cloudflare.edge.r2.bucket"

AccountsTokensValue

Roll Token
client.accounts.tokens.value.update(stringtokenID, ValueUpdateParams { account_id, body } params, RequestOptionsoptions?): TokenValue
PUT/accounts/{account_id}/tokens/{token_id}/value

AccountsLogs

AccountsLogsAudit

Get account audit logs (Version 2)
client.accounts.logs.audit.list(AuditListParams { account_id, before, since, 26 more } params, RequestOptionsoptions?): CursorPaginationAfter<AuditListResponse { id, account, action, 4 more } >
GET/accounts/{account_id}/logs/audit
Get resource change history from an account audit log entry (Version 2)
client.accounts.logs.audit.history(stringid, AuditHistoryParams { account_id, action_time, before, 4 more } params, RequestOptionsoptions?): AuditHistoryResponse { id, account, action, 4 more }
GET/accounts/{account_id}/logs/audit/{id}/history
List account audit log product categories (Version 2)
client.accounts.logs.audit.productCategories(AuditProductCategoriesParams { account_id } params, RequestOptionsoptions?): SinglePage<AuditProductCategoriesResponse { label, products, value } >
GET/accounts/{account_id}/logs/audit/product_categories
ModelsExpand Collapse
AuditListResponse { id, account, action, 4 more }
id?: string

A unique identifier for the audit log entry.

maxLength32
account?: Account { id, name }

Contains account related information.

id?: string

A unique identifier for the account.

name?: string

A string that identifies the account name.

action?: Action { description, result, time, type }

Provides information about the action performed.

description?: string

A short description of the action performed.

result?: string

The result of the action, indicating success or failure.

time?: string

A timestamp indicating when the action was logged.

formatdate-time
type?: string

A short string that describes the action that was performed.

actor?: Actor { id, context, email, 4 more }

Provides details about the actor who performed the action.

id?: string

The ID of the actor who performed the action. If a user performed the action, this will be their User ID.

context?: "api" | "api_key" | "api_token" | 3 more

The context in which the action was initiated.

  • api: The action was performed through the API. The specific credential type was not recorded.
  • api_key: The action was authenticated with a Cloudflare Global API Key.
  • api_token: The action was authenticated with an API token.
  • dash: The action was performed through the Cloudflare dashboard.
  • oauth: The action was authenticated with an OAuth token.
  • origin_ca_key: The action was authenticated with an Origin CA key.
One of the following:
"api"
"api_key"
"api_token"
"dash"
"oauth"
"origin_ca_key"
email?: string

The email of the actor who performed the action.

formatemail
ip_address?: string

The IP address of the request that performed the action.

token_id?: string

The API token ID when the actor context is an api_token or oauth.

token_name?: string

The API token name when the actor context is an api_token or oauth.

type?: "account" | "cloudflare_admin" | "delegated_service" | 2 more

The type of actor.

One of the following:
"account"
"cloudflare_admin"
"delegated_service"
"system"
"user"
raw?: Raw { cf_ray_id, method, status_code, 2 more }

Provides raw information about the request and response.

cf_ray_id?: string

The Cloudflare Ray ID for the request.

method?: string

The HTTP method of the request.

status_code?: number

The HTTP response status code returned by the API.

uri?: string

The URI of the request.

user_agent?: string

The client’s user agent string sent with the request.

resource?: Resource { id, product, request, 3 more }

Provides details about the affected resource.

id?: string

The unique identifier for the affected resource.

product?: string

The Cloudflare product associated with the resource.

request?: unknown
response?: unknown
scope?: unknown

The scope of the resource.

type?: string

The type of the resource.

zone?: Zone { id, name }

Provides details about the zone affected by the action.

id?: string

A string that identifies the zone id.

name?: string

A string that identifies the zone name.

AuditHistoryResponse = Array<AuditHistoryResponseItem>
id?: string

A unique identifier for the audit log entry.

maxLength32
account?: Account { id, name }

Contains account related information.

id?: string

A unique identifier for the account.

name?: string

A string that identifies the account name.

action?: Action { description, result, time, type }

Provides information about the action performed.

description?: string

A short description of the action performed.

result?: string

The result of the action, indicating success or failure.

time?: string

A timestamp indicating when the action was logged.

formatdate-time
type?: string

A short string that describes the action that was performed.

actor?: Actor { id, context, email, 4 more }

Provides details about the actor who performed the action.

id?: string

The ID of the actor who performed the action. If a user performed the action, this will be their User ID.

context?: "api" | "api_key" | "api_token" | 3 more

The context in which the action was initiated.

  • api: The action was performed through the API. The specific credential type was not recorded.
  • api_key: The action was authenticated with a Cloudflare Global API Key.
  • api_token: The action was authenticated with an API token.
  • dash: The action was performed through the Cloudflare dashboard.
  • oauth: The action was authenticated with an OAuth token.
  • origin_ca_key: The action was authenticated with an Origin CA key.
One of the following:
"api"
"api_key"
"api_token"
"dash"
"oauth"
"origin_ca_key"
email?: string

The email of the actor who performed the action.

formatemail
ip_address?: string

The IP address of the request that performed the action.

token_id?: string

The API token ID when the actor context is an api_token or oauth.

token_name?: string

The API token name when the actor context is an api_token or oauth.

type?: "account" | "cloudflare_admin" | "delegated_service" | 2 more

The type of actor.

One of the following:
"account"
"cloudflare_admin"
"delegated_service"
"system"
"user"
raw?: Raw { cf_ray_id, method, status_code, 2 more }

Provides raw information about the request and response.

cf_ray_id?: string

The Cloudflare Ray ID for the request.

method?: string

The HTTP method of the request.

status_code?: number

The HTTP response status code returned by the API.

uri?: string

The URI of the request.

user_agent?: string

The client’s user agent string sent with the request.

resource?: Resource { id, product, request, 3 more }

Provides details about the affected resource.

id?: string

The unique identifier for the affected resource.

product?: string

The Cloudflare product associated with the resource.

request?: unknown
response?: unknown
scope?: unknown

The scope of the resource.

type?: string

The type of the resource.

zone?: Zone { id, name }

Provides details about the zone affected by the action.

id?: string

A string that identifies the zone id.

name?: string

A string that identifies the zone name.

AuditProductCategoriesResponse { label, products, value }

A predefined product category and the resource products it expands to.

label?: string

A human-readable label for the product category.

products?: Array<Product>

The resource products that the product category expands to.

label?: string

A human-readable label for the product.

value?: string

The resource_product value that the product category expands to.

value?: string

The product category identifier used with the product_category filter.

AccountsSpeed Settings

AccountsSpeed SettingsTransformations

List Image Resizing configurations for account
client.accounts.speedSettings.transformations.get(TransformationGetParams { account_id } params, RequestOptionsoptions?): SinglePage<TransformationsConfig { id, cf_zone_tag, editable, 2 more } >
GET/accounts/{account_id}/settings/transformations
ModelsExpand Collapse
TransformationsConfig { id, cf_zone_tag, editable, 2 more }

A configuration item for a specific zone and feature.

id?: string

Feature identifier.

cf_zone_tag?: string

Zone tag identifier.

editable?: boolean

Whether this setting can be modified.

modified_on?: string | null

When this setting was last modified.

formatdate-time
value?: string

Current value of the feature setting.

AccountsPayment Methods

List Payment Methods
client.accounts.paymentMethods.list(PaymentMethodListParams { account_id, page, per_page } params, RequestOptionsoptions?): V4PagePaginationArray<PaymentMethodListResponse { id, address, address2, 22 more } >
GET/accounts/{account_id}/payment-methods
Create Payment Method
client.accounts.paymentMethods.create(PaymentMethodCreateParams { account_id, address, address2, 20 more } params, RequestOptionsoptions?): PaymentMethodCreateResponse { id, address, address2, 22 more }
POST/accounts/{account_id}/payment-methods
Get Payment Method
client.accounts.paymentMethods.get(stringpaymentMethodID, PaymentMethodGetParams { account_id } params, RequestOptionsoptions?): PaymentMethodGetResponse { id, address, address2, 22 more }
GET/accounts/{account_id}/payment-methods/{payment_method_id}
Update Payment Method
client.accounts.paymentMethods.update(stringpaymentMethodID, PaymentMethodUpdateParams { account_id, address, address2, 20 more } params, RequestOptionsoptions?): PaymentMethodUpdateResponse { id, address, address2, 22 more }
PUT/accounts/{account_id}/payment-methods/{payment_method_id}
Delete Payment Method
client.accounts.paymentMethods.delete(stringpaymentMethodID, PaymentMethodDeleteParams { account_id } params, RequestOptionsoptions?): PaymentMethodDeleteResponse
DELETE/accounts/{account_id}/payment-methods/{payment_method_id}
Set Default Payment Method
client.accounts.paymentMethods.setAsDefault(stringpaymentMethodID, PaymentMethodSetAsDefaultParams { account_id } params, RequestOptionsoptions?): PaymentMethodSetAsDefaultResponse
POST/accounts/{account_id}/payment-methods/{payment_method_id}/set-as-default
ModelsExpand Collapse
PaymentMethodListResponse { id, address, address2, 22 more }
id?: string

Payment method identifier.

address?: string

Billing address line 1.

address2?: string

Billing address line 2.

bank_account_type?: string

Bank account type.

bank_code?: string

Bank code.

bank_country?: string

Bank country.

bank_name?: string

Bank name for bank-based payment methods.

bank_routing_number?: string

Bank routing number.

cashapp_cash_tag?: string

Cash App cash tag.

city?: string

Billing city.

country?: string

Billing country.

default?: boolean

Whether this is the default payment method.

device_data?: string

Device data for fraud prevention.

expiration_date?: string

Card expiration date.

first_name?: string

Billing first name.

last_four?: string

Last four digits of the card number.

last_name?: string

Billing last name.

nick_name?: string

A nickname for the payment method.

payment_account_email?: string

Email associated with the payment account.

payment_email?: string

Payment email address.

payment_gateway?: string

The payment gateway used.

payment_nonce?: string

Payment nonce for tokenized payments.

state?: string

Billing state.

type?: "CREDIT_CARD" | "PAYPAL" | "CASHAPP" | 3 more

The payment method type.

One of the following:
"CREDIT_CARD"
"PAYPAL"
"CASHAPP"
"SEPA_DEBIT"
"LINK"
"ACH_DIRECT_DEBIT"
zipcode?: string

Billing zip code.

PaymentMethodCreateResponse { id, address, address2, 22 more }
id?: string

Payment method identifier.

address?: string

Billing address line 1.

address2?: string

Billing address line 2.

bank_account_type?: string

Bank account type.

bank_code?: string

Bank code.

bank_country?: string

Bank country.

bank_name?: string

Bank name for bank-based payment methods.

bank_routing_number?: string

Bank routing number.

cashapp_cash_tag?: string

Cash App cash tag.

city?: string

Billing city.

country?: string

Billing country.

default?: boolean

Whether this is the default payment method.

device_data?: string

Device data for fraud prevention.

expiration_date?: string

Card expiration date.

first_name?: string

Billing first name.

last_four?: string

Last four digits of the card number.

last_name?: string

Billing last name.

nick_name?: string

A nickname for the payment method.

payment_account_email?: string

Email associated with the payment account.

payment_email?: string

Payment email address.

payment_gateway?: string

The payment gateway used.

payment_nonce?: string

Payment nonce for tokenized payments.

state?: string

Billing state.

type?: "CREDIT_CARD" | "PAYPAL" | "CASHAPP" | 3 more

The payment method type.

One of the following:
"CREDIT_CARD"
"PAYPAL"
"CASHAPP"
"SEPA_DEBIT"
"LINK"
"ACH_DIRECT_DEBIT"
zipcode?: string

Billing zip code.

PaymentMethodGetResponse { id, address, address2, 22 more }
id?: string

Payment method identifier.

address?: string

Billing address line 1.

address2?: string

Billing address line 2.

bank_account_type?: string

Bank account type.

bank_code?: string

Bank code.

bank_country?: string

Bank country.

bank_name?: string

Bank name for bank-based payment methods.

bank_routing_number?: string

Bank routing number.

cashapp_cash_tag?: string

Cash App cash tag.

city?: string

Billing city.

country?: string

Billing country.

default?: boolean

Whether this is the default payment method.

device_data?: string

Device data for fraud prevention.

expiration_date?: string

Card expiration date.

first_name?: string

Billing first name.

last_four?: string

Last four digits of the card number.

last_name?: string

Billing last name.

nick_name?: string

A nickname for the payment method.

payment_account_email?: string

Email associated with the payment account.

payment_email?: string

Payment email address.

payment_gateway?: string

The payment gateway used.

payment_nonce?: string

Payment nonce for tokenized payments.

state?: string

Billing state.

type?: "CREDIT_CARD" | "PAYPAL" | "CASHAPP" | 3 more

The payment method type.

One of the following:
"CREDIT_CARD"
"PAYPAL"
"CASHAPP"
"SEPA_DEBIT"
"LINK"
"ACH_DIRECT_DEBIT"
zipcode?: string

Billing zip code.

PaymentMethodUpdateResponse { id, address, address2, 22 more }
id?: string

Payment method identifier.

address?: string

Billing address line 1.

address2?: string

Billing address line 2.

bank_account_type?: string

Bank account type.

bank_code?: string

Bank code.

bank_country?: string

Bank country.

bank_name?: string

Bank name for bank-based payment methods.

bank_routing_number?: string

Bank routing number.

cashapp_cash_tag?: string

Cash App cash tag.

city?: string

Billing city.

country?: string

Billing country.

default?: boolean

Whether this is the default payment method.

device_data?: string

Device data for fraud prevention.

expiration_date?: string

Card expiration date.

first_name?: string

Billing first name.

last_four?: string

Last four digits of the card number.

last_name?: string

Billing last name.

nick_name?: string

A nickname for the payment method.

payment_account_email?: string

Email associated with the payment account.

payment_email?: string

Payment email address.

payment_gateway?: string

The payment gateway used.

payment_nonce?: string

Payment nonce for tokenized payments.

state?: string

Billing state.

type?: "CREDIT_CARD" | "PAYPAL" | "CASHAPP" | 3 more

The payment method type.

One of the following:
"CREDIT_CARD"
"PAYPAL"
"CASHAPP"
"SEPA_DEBIT"
"LINK"
"ACH_DIRECT_DEBIT"
zipcode?: string

Billing zip code.

PaymentMethodDeleteResponse = unknown | string | null
One of the following:
unknown
string | null
PaymentMethodSetAsDefaultResponse = unknown | string | null
One of the following:
unknown
string | null

AccountsPay Invoice

Pay Invoice
client.accounts.payInvoice.create(PayInvoiceCreateParams { account_id, invoice_id, payment_method_id, validate_payment_method } params, RequestOptionsoptions?): PayInvoiceCreateResponse { client_secret }
POST/accounts/{account_id}/pay-invoice
ModelsExpand Collapse
PayInvoiceCreateResponse { client_secret }
client_secret?: string

The Stripe client secret for frontend payment confirmation.

AccountsPay Bad Debt

Pay Bad Debt
client.accounts.payBadDebt.create(PayBadDebtCreateParams { account_id, payment_method_id } params, RequestOptionsoptions?): PayBadDebtCreateResponse { client_secret }
POST/accounts/{account_id}/pay-bad-debt
ModelsExpand Collapse
PayBadDebtCreateResponse { client_secret }
client_secret?: string

The Stripe client secret for frontend payment confirmation.

AccountsReceipts

Get Receipt PDF
client.accounts.receipts.pdf(stringreceiptID, ReceiptPDFParams { account_id, doctype } params, RequestOptionsoptions?): Response
GET/accounts/{account_id}/receipts/{receipt_id}/pdf

AccountsInvoices

Toggle PDF Invoices
client.accounts.invoices.edit(InvoiceEditParams { account_id, toggle } params, RequestOptionsoptions?): InvoiceEditResponse
PATCH/accounts/{account_id}/invoices
ModelsExpand Collapse
InvoiceEditResponse = unknown | string | null
One of the following:
unknown
string | null

AccountsClient Secret

Create Setup Intent
client.accounts.clientSecret.create(ClientSecretCreateParams { account_id } params, RequestOptionsoptions?): ClientSecretCreateResponse { client_secret }
POST/accounts/{account_id}/client-secret
ModelsExpand Collapse
ClientSecretCreateResponse { client_secret }
client_secret?: string

The Stripe client secret for frontend payment confirmation.