Search for charges you’ve previously created using Stripe’s Search Query Language. Don’t use search in read-after-write flows where strict consistency is necessary. Under normal operating conditions, data is searchable in less than a minute. Occasionally, propagation of new or updated data can be up to an hour behind during outages. Search functionality is not available to merchants in India.
Parameters
- querystringRequired
The search query string. See search query language and the list of supported query fields for charges.
- limitinteger
A limit on the number of objects to be returned. Limit can range between 1 and 100, and the default is 10.
- pagestring
A cursor for pagination across multiple pages of results. Don’t include this parameter on the first call. Use the next_page value returned in a previous response to request subsequent results.
Returns
A dictionary with a data
property that contains an array of up to limit
charges. If no objects match the query, the resulting array will be empty. See the related guide on expanding properties in lists.
{ "object": "search_result", "url": "/v1/charges/search", "has_more": false, "data": [ { "id": "ch_3MrVHGLkdIwHu7ix3VP9P8qH", "object": "charge", "amount": 1000, "amount_captured": 1000, "amount_refunded": 0, "application": null, "application_fee": null, "application_fee_amount": null, "balance_transaction": "txn_3MrVHGLkdIwHu7ix33fWgyw1", "billing_details": { "address": { "city": null, "country": null, "line1": null, "line2": null, "postal_code": null, "state": null }, "email": null, "name": null, "phone": null }, "calculated_statement_descriptor": "Stripe", "captured": true, "created": 1680220390, "currency": "usd", "customer": null, "description": null, "disputed": false, "failure_balance_transaction": null, "failure_code": null, "failure_message": null, "fraud_details": {}, "livemode": false, "metadata": { "order_id": "6735" }, "on_behalf_of": null, "outcome": { "network_status": "approved_by_network", "reason": null, "risk_level": "normal", "risk_score": 28, "seller_message": "Payment complete.", "type": "authorized" }, "paid": true, "payment_intent": null, "payment_method": "card_1MrVHGLkdIwHu7ixi93aSYS2", "payment_method_details": { "card": { "brand": "visa", "checks": { "address_line1_check": null, "address_postal_code_check": null, "cvc_check": null }, "country": "US", "exp_month": 3, "exp_year": 2024, "fingerprint": "mToisGZ01V71BCos", "funding": "credit", "installments": null, "last4": "4242", "mandate": null, "network": "visa", "network_token": { "used": false }, "three_d_secure": null, "wallet": null }, "type": "card" }, "receipt_email": null, "receipt_number": null, "receipt_url": "https://pay.stripe.com/receipts/payment/CAcaFwoVYWNjdF8xTTJKVGtMa2RJd0h1N2l4KOfBmKEGMgY6smXCZpA6LBZYyAwZTSPplSpB7KwcptJiKqQfv6nQiL75NRCxebjOIiABDK3odR96wc2r", "refunded": false, "review": null, "shipping": null, "source_transfer": null, "statement_descriptor": null, "statement_descriptor_suffix": null, "status": "succeeded", "transfer_data": null, "transfer_group": null } ]}
This object represents a customer of your business. Use it to create recurring charges, save payment and contact information, and track payments that belong to the same customer.
A Customer Session allows you to grant Stripe’s frontend SDKs (like Stripe.js) client-side access control over a Customer.
Related guides: Customer Session with the Payment Element, Customer Session with the Pricing Table, Customer Session with the Buy Button.
A dispute occurs when a customer questions your charge with their card issuer. When this happens, you have the opportunity to respond to the dispute with evidence that shows that the charge is legitimate.
Related guide: Disputes and fraud
Events are our way of letting you know when something interesting happens in your account. When an interesting event occurs, we create a new Event
object. For example, when a charge succeeds, we create a charge.
event, and when an invoice payment attempt fails, we create an invoice.
event. Certain API requests might create multiple events. For example, if you create a new subscription for a customer, you receive both a customer.
event and a charge.
event.
Events occur when the state of another API resource changes. The event’s data field embeds the resource’s state at the time of the change. For example, a charge.
event contains a charge, and an invoice.
event contains an invoice.
As with other API resources, you can use endpoints to retrieve an individual event or a list of events from the API. We also have a separate webhooks system for sending the Event
objects directly to an endpoint on your server. You can manage webhooks in your account settings. Learn how to listen for events so that your integration can automatically trigger reactions.
When using Connect, you can also receive event notifications that occur in connected accounts. For these events, there’s an additional account
attribute in the received Event
object.
We only guarantee access to events through the Retrieve Event API for 30 days.