delete-bank-account
Method: DELETE
Path: /customers/{customer_id}/bank-accounts/{account_id}
Tags: Customers
Summary
Delete a bank account
Description
Remove a bank account from a customer.
Storefront SDK Usage
SDK Method: sdk.customer.deleteBankAccount()
Example:
typescript
const { data, error } = await sdk.customer.deleteBankAccount({
account_id: "acct_789"
});
if (error) {
console.error("Failed to delete bank account:", error);
return;
}
console.log("Bank account deleted:", data.message);TypeScript Definition
typescript
"delete-bank-account": {
parameters: {
query?: never;
header?: never;
path: {
/** @description Bank account id */
account_id: string;
/** @description Customer id */
customer_id: string;
};
cookie?: never;
};
requestBody?: never;
responses: {
/** @description OK */
200: {
headers: {
[name: string]: unknown;
};
content: {
"application/json": {
message?: string;
success?: boolean;
};
};
};
401: components["responses"]["Unauthorized"];
404: components["responses"]["NotFound"];
};
};Component References
| Reference | Resolves To |
|---|---|
components["responses"]["Unauthorized"] | Unauthorized |
components["responses"]["NotFound"] | NotFound |
Responses
200
OK
401
Not authorized for given operation on the Resource
404
Requested resource not found
OpenAPI Definition
json
{
"tags": [
"Customers"
],
"operationId": "delete-bank-account",
"summary": "Delete a bank account",
"description": "Remove a bank account from a customer.",
"externalDocs": {
"url": "https://llm-docs.commercengine.io/storefront/operations/delete-bank-account",
"description": "API reference for the delete-bank-account operation"
},
"responses": {
"200": {
"description": "OK",
"content": {
"application/json": {
"schema": {
"type": "object",
"properties": {
"message": {
"type": "string"
},
"success": {
"type": "boolean"
}
}
}
}
}
},
"401": {
"$ref": "#/components/responses/Unauthorized"
},
"404": {
"$ref": "#/components/responses/NotFound"
}
},
"security": [
{
"Authorization": []
}
],
"x-speakeasy-group": "customers",
"x-speakeasy-ignore": false,
"x-speakeasy-name-override": "deleteBankAccount"
}Auto-generated from OpenAPI spec and TypeScript definitions