# Transaction

A transaction is associated to an order and represents the movement of money.

## List all transactions

> Returns a list of transactions. The transactions are returned in descending order by creation date.

```json
{"openapi":"3.1.0","info":{"title":"Glu","version":"1.0.0"},"tags":[{"name":"Transaction","description":"A transaction is associated to an order and represents the movement of money."}],"servers":[{"url":"https://api.glu.io","description":"Production API"}],"security":[{"x_api_key":[]}],"components":{"securitySchemes":{"x_api_key":{"type":"apiKey","description":"Value for the x-api-key header parameter.","name":"x-api-key","in":"header"}},"schemas":{"Transaction-read":{"type":"object","description":"A transaction is associated to an order and represents the movement of money.","properties":{"id":{"readOnly":true,"type":"integer"},"amount":{"type":"integer"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"},"gateway":{"type":"string"},"gatewayReference":{"default":"","type":"string"},"type":{"type":"string","enum":["Payment","Refund","Refund Failure","Chargeback","Chargeback Reversal"]},"currencyCode":{"type":"string"},"card_type":{"default":"","type":["string","null"]},"card_number":{"default":"","type":["string","null"]},"attachedOrder":{"type":"integer"},"refund":{"anyOf":[{"$ref":"#/components/schemas/Refund-read"},{"type":"null"}]},"failedRefund":{"anyOf":[{"$ref":"#/components/schemas/Refund-read"},{"type":"null"}]},"payment":{"anyOf":[{"$ref":"#/components/schemas/Payment-read"},{"type":"null"}]}}},"Refund-read":{"type":"object"},"Payment-read":{"type":"object"},"Error.jsonld":{"type":"object","description":"A representation of common errors.","properties":{"title":{"readOnly":true,"description":"A short, human-readable summary of the problem.","type":["string","null"]},"detail":{"readOnly":true,"description":"A human-readable explanation specific to this occurrence of the problem.","type":["string","null"]},"status":{"type":["number","null"],"default":400},"instance":{"readOnly":true,"description":"A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.","type":["string","null"]},"type":{"readOnly":true,"description":"A URI reference that identifies the problem type","type":"string"},"description":{"readOnly":true,"type":["string","null"]}}},"Error":{"type":"object","description":"A representation of common errors.","properties":{"title":{"readOnly":true,"description":"A short, human-readable summary of the problem.","type":["string","null"]},"detail":{"readOnly":true,"description":"A human-readable explanation specific to this occurrence of the problem.","type":["string","null"]},"status":{"type":["number","null"],"default":400},"instance":{"readOnly":true,"description":"A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.","type":["string","null"]},"type":{"readOnly":true,"description":"A URI reference that identifies the problem type","type":"string"}}}}},"paths":{"/transactions":{"get":{"operationId":"api_transactions_get_collection","tags":["Transaction"],"responses":{"200":{"description":"Transaction collection","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/Transaction-read"}}}}},"403":{"description":"Forbidden","content":{"application/ld+json":{"schema":{"$ref":"#/components/schemas/Error.jsonld"}},"application/problem+json":{"schema":{"$ref":"#/components/schemas/Error"}},"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"links":{}}},"summary":"List all transactions","description":"Returns a list of transactions. The transactions are returned in descending order by creation date.","parameters":[{"name":"page","in":"query","description":"The collection page number","required":false,"deprecated":false,"schema":{"type":"integer","default":1},"style":"form","explode":true},{"name":"createdAt[before]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"createdAt[strictly_before]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"createdAt[after]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"createdAt[strictly_after]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"updatedAt[before]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"updatedAt[strictly_before]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"updatedAt[after]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"updatedAt[strictly_after]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"type","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string","enum":["Payment","Refund","Refund Failure","Chargeback","Chargeback Reversal"]},"style":"form","explode":false},{"name":"type[]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"array","items":{"type":"string","enum":["Payment","Refund","Refund Failure","Chargeback","Chargeback Reversal"]}},"style":"form","explode":true},{"name":"amount[between]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"amount[gt]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"amount[gte]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"amount[lt]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false},{"name":"amount[lte]","in":"query","description":"","required":false,"deprecated":false,"schema":{"type":"string"},"style":"form","explode":false}]}}}}
```

## Retrieve a transaction

> Retrieve a transaction

```json
{"openapi":"3.1.0","info":{"title":"Glu","version":"1.0.0"},"tags":[{"name":"Transaction","description":"A transaction is associated to an order and represents the movement of money."}],"servers":[{"url":"https://api.glu.io","description":"Production API"}],"security":[{"x_api_key":[]}],"components":{"securitySchemes":{"x_api_key":{"type":"apiKey","description":"Value for the x-api-key header parameter.","name":"x-api-key","in":"header"}},"schemas":{"Transaction-read":{"type":"object","description":"A transaction is associated to an order and represents the movement of money.","properties":{"id":{"readOnly":true,"type":"integer"},"amount":{"type":"integer"},"createdAt":{"type":"string","format":"date-time"},"updatedAt":{"type":"string","format":"date-time"},"gateway":{"type":"string"},"gatewayReference":{"default":"","type":"string"},"type":{"type":"string","enum":["Payment","Refund","Refund Failure","Chargeback","Chargeback Reversal"]},"currencyCode":{"type":"string"},"card_type":{"default":"","type":["string","null"]},"card_number":{"default":"","type":["string","null"]},"attachedOrder":{"type":"integer"},"refund":{"anyOf":[{"$ref":"#/components/schemas/Refund-read"},{"type":"null"}]},"failedRefund":{"anyOf":[{"$ref":"#/components/schemas/Refund-read"},{"type":"null"}]},"payment":{"anyOf":[{"$ref":"#/components/schemas/Payment-read"},{"type":"null"}]}}},"Refund-read":{"type":"object"},"Payment-read":{"type":"object"},"Error.jsonld":{"type":"object","description":"A representation of common errors.","properties":{"title":{"readOnly":true,"description":"A short, human-readable summary of the problem.","type":["string","null"]},"detail":{"readOnly":true,"description":"A human-readable explanation specific to this occurrence of the problem.","type":["string","null"]},"status":{"type":["number","null"],"default":400},"instance":{"readOnly":true,"description":"A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.","type":["string","null"]},"type":{"readOnly":true,"description":"A URI reference that identifies the problem type","type":"string"},"description":{"readOnly":true,"type":["string","null"]}}},"Error":{"type":"object","description":"A representation of common errors.","properties":{"title":{"readOnly":true,"description":"A short, human-readable summary of the problem.","type":["string","null"]},"detail":{"readOnly":true,"description":"A human-readable explanation specific to this occurrence of the problem.","type":["string","null"]},"status":{"type":["number","null"],"default":400},"instance":{"readOnly":true,"description":"A URI reference that identifies the specific occurrence of the problem. It may or may not yield further information if dereferenced.","type":["string","null"]},"type":{"readOnly":true,"description":"A URI reference that identifies the problem type","type":"string"}}}}},"paths":{"/transactions/{id}":{"get":{"operationId":"api_transactions_id_get","tags":["Transaction"],"responses":{"200":{"description":"Transaction resource","content":{"application/json":{"schema":{"$ref":"#/components/schemas/Transaction-read"}}}},"403":{"description":"Forbidden","content":{"application/ld+json":{"schema":{"$ref":"#/components/schemas/Error.jsonld"}},"application/problem+json":{"schema":{"$ref":"#/components/schemas/Error"}},"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"links":{}},"404":{"description":"Not found","content":{"application/ld+json":{"schema":{"$ref":"#/components/schemas/Error.jsonld"}},"application/problem+json":{"schema":{"$ref":"#/components/schemas/Error"}},"application/json":{"schema":{"$ref":"#/components/schemas/Error"}}},"links":{}}},"summary":"Retrieve a transaction","description":"Retrieve a transaction","parameters":[{"name":"id","in":"path","description":"Transaction identifier","required":true,"deprecated":false,"schema":{"type":"string"},"style":"simple","explode":false}]}}}}
```


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://glu.gitbook.io/docs/api-reference/organisation-api/transaction.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
