> For clean Markdown of any page, append .md to the page URL. > For a complete documentation index, see https://docs.wisboo.com/wisboo-api/purchases/list-purchases/llms.txt. > For AI client integration (Claude Code, Cursor, etc.), connect to the MCP server at https://docs.wisboo.com/_mcp/server. # List purchases GET https://api.wisboo.com/v1/stores/{store_id}/purchases Devuelve una lista paginada de compras de la tienda. Todos los filtros son opcionales y pueden combinarse entre sí. Reference: https://docs.wisboo.com/wisboo-api/purchases/list-purchases ## Authentication - `Authorization` header (bearer token, required) — Bearer authentication of the form `Bearer `, where token is your auth token. ## Request ### Path parameters - `store_id` (string, required) ### Query parameters - `page` (integer, optional) - `size` (integer, optional) - `email` (string, optional) — Email del usuario comprador - `product_id` (string, optional) — ID de los productos asociados a la compra - `user_id` (string, optional) — ID de los usuarios asociados a la compra ## Response ### 200 Successful request - `object` (string, optional) - `url` (string, optional) - `data` (list of V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItems, optional) - `metadata` (V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaMetadata, optional) ## Types ### V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItems - `id` (string, optional) - `status` (string, optional) - `payment_id` (string, optional) - `payment_gateway` (string, optional) - `base_price` (string, optional) - `promotion_percentage_off` (string, optional) - `promotion_amount_off` (string, optional) - `promotional_price` (string, optional) - `discounted_amount` (string, optional) - `extra_charge` (string, optional) - `extra_charge_percentage` (string, optional) - `extra_charge_name` (any, optional, nullable) - `taxes_amount` (string, optional) - `installment_plan_interval` (string, optional, nullable) - `installments` (integer, optional) - `installment_amount` (string, optional) - `installment_interest_rate` (string, optional) - `installment_interest_rate_amount` (string, optional) - `amount_due` (string, optional) - `amount_paid` (string, optional) - `charged_installments` (integer, optional) - `installment_plan_end_date` (datetime, optional, nullable) - `next_charge_at` (datetime, optional, nullable) - `total_amount` (string, optional) - `currency` (string, optional) - `gift_recipient_id` (string, optional, nullable) - `gift_recipient_email` (string, optional, nullable) - `custom_fields` (V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsCustomFields, optional) - `promotion_type` (string, optional, nullable) - `checkout_session` (V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsCheckoutSession, optional) - `discount` (V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsDiscount, optional, nullable) - `product` (V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsProduct, optional) - `user` (V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsUser, optional) - `created_at` (datetime, optional) - `paid_at` (datetime, optional) ### V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaMetadata - `page_number` (integer, optional) - `total_record_count` (integer, optional) - `page_size` (integer, optional) ### V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsCustomFields ### V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsCheckoutSession - `id` (string, optional) - `started_at` (datetime, optional) - `ip` (string, optional) - `device_type` (string, optional) - `user_agent` (string, optional) - `utm_medium` (string, optional, nullable) - `utm_source` (string, optional, nullable) - `utm_campaign` (string, optional, nullable) - `utm_term` (string, optional, nullable) - `utm_content` (string, optional, nullable) ### V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsDiscount - `percentage` (string, optional) - `code` (string, optional) - `id` (string, optional) ### V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsProduct - `id` (string, optional) - `name` (string, optional) - `type` (string, optional) - `slug` (string, optional) ### V1StoresStoreIdPurchasesGetResponsesContentApplicationJsonSchemaDataItemsUser - `id` (string, optional) - `name` (string, optional) - `last_name` (string, optional) - `email` (string, optional) - `external_id` (string, optional) ## Examples **Response** ```json { "object": "string", "url": "string", "data": [ { "id": "string", "status": "string", "payment_id": "string", "payment_gateway": "string", "base_price": "string", "promotion_percentage_off": "string", "promotion_amount_off": "string", "promotional_price": "string", "discounted_amount": "string", "extra_charge": "string", "extra_charge_percentage": "string", "extra_charge_name": null, "taxes_amount": "string", "installment_plan_interval": "string", "installments": 1, "installment_amount": "string", "installment_interest_rate": "string", "installment_interest_rate_amount": "string", "amount_due": "string", "amount_paid": "string", "charged_installments": 1, "installment_plan_end_date": "2024-01-15T09:30:00Z", "next_charge_at": "2024-01-15T09:30:00Z", "total_amount": "string", "currency": "string", "gift_recipient_id": "string", "gift_recipient_email": "string", "custom_fields": {}, "promotion_type": "string", "checkout_session": { "id": "string", "started_at": "2024-01-15T09:30:00Z", "ip": "string", "device_type": "string", "user_agent": "string", "utm_medium": "string", "utm_source": "string", "utm_campaign": "string", "utm_term": "string", "utm_content": "string" }, "discount": { "percentage": "string", "code": "string", "id": "string" }, "product": { "id": "string", "name": "string", "type": "string", "slug": "string" }, "user": { "id": "string", "name": "string", "last_name": "string", "email": "string", "external_id": "string" }, "created_at": "2024-01-15T09:30:00Z", "paid_at": "2024-01-15T09:30:00Z" } ], "metadata": { "page_number": 1, "total_record_count": 1, "page_size": 1 } } ``` **SDK Code** ```python import requests url = "https://api.wisboo.com/v1/stores/store_id/purchases" headers = {"Authorization": "Bearer "} response = requests.get(url, headers=headers) print(response.json()) ``` ```javascript const url = 'https://api.wisboo.com/v1/stores/store_id/purchases'; const options = {method: 'GET', headers: {Authorization: 'Bearer '}}; try { const response = await fetch(url, options); const data = await response.json(); console.log(data); } catch (error) { console.error(error); } ``` ```go package main import ( "fmt" "net/http" "io" ) func main() { url := "https://api.wisboo.com/v1/stores/store_id/purchases" req, _ := http.NewRequest("GET", url, nil) req.Header.Add("Authorization", "Bearer ") res, _ := http.DefaultClient.Do(req) defer res.Body.Close() body, _ := io.ReadAll(res.Body) fmt.Println(res) fmt.Println(string(body)) } ``` ```ruby require 'uri' require 'net/http' url = URI("https://api.wisboo.com/v1/stores/store_id/purchases") http = Net::HTTP.new(url.host, url.port) http.use_ssl = true request = Net::HTTP::Get.new(url) request["Authorization"] = 'Bearer ' response = http.request(request) puts response.read_body ``` ```java import com.mashape.unirest.http.HttpResponse; import com.mashape.unirest.http.Unirest; HttpResponse response = Unirest.get("https://api.wisboo.com/v1/stores/store_id/purchases") .header("Authorization", "Bearer ") .asString(); ``` ```php request('GET', 'https://api.wisboo.com/v1/stores/store_id/purchases', [ 'headers' => [ 'Authorization' => 'Bearer ', ], ]); echo $response->getBody(); ``` ```csharp using RestSharp; var client = new RestClient("https://api.wisboo.com/v1/stores/store_id/purchases"); var request = new RestRequest(Method.GET); request.AddHeader("Authorization", "Bearer "); IRestResponse response = client.Execute(request); ``` ```swift import Foundation let headers = ["Authorization": "Bearer "] let request = NSMutableURLRequest(url: NSURL(string: "https://api.wisboo.com/v1/stores/store_id/purchases")! as URL, cachePolicy: .useProtocolCachePolicy, timeoutInterval: 10.0) request.httpMethod = "GET" request.allHTTPHeaderFields = headers let session = URLSession.shared let dataTask = session.dataTask(with: request as URLRequest, completionHandler: { (data, response, error) -> Void in if (error != nil) { print(error as Any) } else { let httpResponse = response as? HTTPURLResponse print(httpResponse) } }) dataTask.resume() ```