Expanding objects

Many objects contain the identifier of a related object in their response properties. For example, a Payout has an associated Employee identifier. Those objects can be expanded inline with the expand request parameter. Objects that can be expanded are noted in this documentation. You can use the expand param on any endpoint which includes expandable fields, including the create endpoints. You can expand multiple objects at once by repeating the expand request parameter.

For example, the following request retrieves a Payout object with the related Employee object expanded.

curl https://api.gigapay.se/v2/payouts/123/?expand=employee \
-H "Authorization: Token 1vjv20ksxwvlpp3peize74ievjmx3e" \
-H "Integration-ID: 650fd73ff5"

The response could look as following:

"id": "123",
"amount": "1000.00",
"currency": "SEK",
"description": "Lön genom Gigapay",
"employee": {
"id": "67",
"name": "Albin Lindskog",
"cellphone_number": "+46703000000",
"email": null,
"metadata": {},
"created_at": "2020-02-11T12:21:27.267591Z",
"verified_at": "2020-02-26T14:52:58.287693Z"
"invoice": "32",
"metadata": {},
"start_at": null,
"end_at": null,
"created_at": "2020-02-11T20:10:45.398264Z",
"notified_at": null,
"accepted_at": null