Brex: List Webhooks
Brex webhooks.webhooksListWebhookSubscriptions: arguments, response, policy and SDK examples.
← Webhooks operations · Get started
Operation brex.webhooks_listwebhooksubscriptions
Provider route: GET /v1/webhooks. Alter supplies the connection’s credentials and routing.
Call through Alter
Section titled “Call through Alter”Install @alter-ai/sdk @alter-ai/brex with npm, or alter-sdk-brex with pip. Supply your connected customer’s grant ID and the arguments described below.
import { App } from "@alter-ai/sdk";import { BrexIntegration } from "@alter-ai/brex";
async function execute(input: Parameters<BrexIntegration["webhooks"]["webhooksListWebhookSubscriptions"]>[0]) { const app = new App({ apiKey: process.env.ALTER_API_KEY! }); try { const provider = new BrexIntegration(app, { grantId: process.env.PROVIDER_GRANT_ID! }); const call = await provider.webhooks.webhooksListWebhookSubscriptions(input); const result = await call.wait(); return result.bodyJson(); } finally { await app.close(); }}import osfrom alter_sdk import Appfrom alter_sdk_brex import BrexIntegration
async def execute(arguments): async with App(api_key=os.environ["ALTER_API_KEY"]) as app: provider = BrexIntegration(app, {"grant_id": os.environ["PROVIDER_GRANT_ID"]}) call = await provider.webhooks.webhooks_list_webhook_subscriptions(arguments) result = await call.wait() return result.body_json()| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | Additional keys: not allowed |
query | object | Optional | Additional keys: not allowed |
query.cursor | JSON | Optional | |
query.cursor (anyOf 1) | string | Alternative | |
query.cursor (anyOf 2) | null | Alternative | |
query.limit | JSON | Optional | |
query.limit (anyOf 1) | integer | Alternative | Format: int32 |
query.limit (anyOf 2) | null | Alternative |
Response
Section titled “Response”Response media type: application/json. The table describes the pinned successful response. Referenced models link to their complete fields.
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | Model | Root | Expand List Webhooks — response body |
Referenced models: List Webhooks — response body
Schemas
Section titled “Schemas”List Webhooks — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | |
items | array | Required within parent | |
items[] | Model | Each item | Expand Get Webhook — response body |
next_cursor | JSON | Optional | |
next_cursor (anyOf 1) | string | Alternative | |
next_cursor (anyOf 2) | null | Alternative |
Referenced models: Get Webhook — response body
Get Webhook — response body
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | object | Root | A webhook subscription. When events of the specified event types occur, they will be sent to the given URL. If the subscription applies to a webhook group, then only events that apply to the members of that group will be sent. If it does not apply to any group, then only events that don't apply to any specific group will be sent. Webhook groups are only available for partners. |
event_types | array | Required within parent | List of event types that this webhook subscription listens to. |
event_types[] | Model | Each item | Expand Get Webhook — response body — event types item |
group_id | JSON | Optional | |
group_id (anyOf 1) | string | Alternative | ID of the webhook group to which this subscription applies, if any. |
group_id (anyOf 2) | null | Alternative | |
id | string | Required within parent | ID of the webhook subscription. Minimum length: 1 |
status | JSON | Required within parent | |
status (allOf 1) | string | All variants apply | The status of a webhook subscription. Known values: ACTIVE, INACTIVE |
status (allOf 2) | JSON | All variants apply | The status of this webhook subscription. |
url | string | Required within parent | The URL to which webhook events will be sent. Must be a valid HTTPS URL. |
Referenced models: Get Webhook — response body — event types item
Get Webhook — response body — event types item
| Field | Type | Presence | Description and constraints |
|---|---|---|---|
$ | string | Root | Known values: REFERRAL_CREATED, REFERRAL_ACTIVATED, REFERRAL_APPLICATION_STATUS_CHANGED, TRANSFER_PROCESSED, TRANSFER_FAILED, EXPENSE_PAYMENT_UPDATED, USER_UPDATED, EMBEDDED_CARD_TRANSACTION_UPDATED, EMBEDDED_CARD_UPDATED, EMBEDDED_ACCOUNT_UPDATED, EMBEDDED_CARD_SHIPPING_UPDATED, EMBEDDED_DISPUTE_UPDATED, PARTNERSHIP_INTEGRATION_CONNECTION_UPDATED, EMBEDDED_CARD_AUTHORIZATION, EMBEDDED_FRAUD_ALERT, EMBEDDED_BILLING_GROUP_UPDATED, EMBEDDED_LEGAL_ENTITY_UPDATED, EMBEDDED_BILLING_STATEMENT_UPDATED, EMBEDDED_USER_STATUS_UPDATED, ACCOUNTING_RECORD_READY_FOR_EXPORT |
Policy, approvals and errors
Section titled “Policy, approvals and errors”SDK function policy ID: brex.webhooks_listwebhooksubscriptions. Catalog operation: webhooks:listWebhookSubscriptions. Rules can name either ID; function rules distinguish managed calls and conservatively cover raw calls sharing the route. Existing grant permissions and policy rules apply. wait() returns an immediate result or waits for a required approval; it never approves the request itself. Persist the approval ID to resume after a restart.
Provider errors retain their response; JSON decoding raises ProviderAPIError for provider failures. ManagedOperationError identifies contract/input/retention errors. See error handling and provider-specific behavior. Sensitive input may be refused before approval storage. A decoding error never resubmits a write.