text: var tokenString = "[{\"id\":\"tradegecko-api-reference\",\"title\":\"TradeGecko API Reference\",\"body\":\"This website documents the public API for TradeGeckoYou can view code examples in the dark area to the right; switch the programming language of the examples with the tabs in the top right.If anything is missing or seems incorrect, please check the GitHub issues\\nfor existing known issues or create a new issue.\"},{\"id\":\"authentication\",\"title\":\"Authentication\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/products?sku=moko/\\nrequire 'gecko-ruby'\\ngecko = Gecko::Client.new(<CLIENT_ID>, <CLIENT_SECRET>)\\ngecko.authorize_from_existing(<ACCESS_TOKEN>, nil, nil)\\ngecko.Product.where(sku: 'moko')\\nThe TradeGecko API is JSON based. In order to make an authenticated call to the API, you must include your access token with the call. OAuth2 uses a BEARER token that is passed along in an Authorization header.\"},{\"id\":\"registering-an-application\",\"title\":\"Registering an Application\",\"body\":\"In order to use the TradeGecko API, you must have an active TradeGecko account.\\nOnce you're logged in to your account you can register a new API application at \\nhttps://go.tradegecko.com/oauth/applications.After successfully registering a new application, you will be given a set of 2\\nunique keys: \\nAPPLICATION ID\\nAPPLICATION SECRET\\n\\n  Make sure to keep these keys secret.\\nThese two keys are subsequently used to obtain access tokens for making API calls.\"},{\"id\":\"oauth-authentication-flows\",\"title\":\"OAuth Authentication Flows\",\"body\":\"The TradeGecko API is based on version 22 of the OAuth 2.0 specification.If you are familiar with OAuth, then the authentication endpoints are as follows:\\nAuthorization: https://api.tradegecko.com/oauth/authorize \\nToken Request: https://api.tradegecko.com/oauth/token \\n\\n  We very highly recommend using a third-party library in your chosen language rather than trying to implement OAuth flows manually.\\n  \\n  You can find a list of recommended libraries here\\nAvailable Authentication FlowsThe TradeGecko API supports two common OAuth 2.0 flows:\\nAuthorization Code with Refresh Token flow\\nResource Owner Password Credentials flow\\nUnder the majority of circumstances we recommend the Authorization Code with Refresh Token flow as it provides the highest level of security.For prototyping, or one-off integrations you may use the Resource Owner Password Credentials flows.If you plan on building an application that will be used by multiple TradeGecko accounts, you MUST use the Authorization Code with Refresh token flow.\"},{\"id\":\"authorization-code-with-refresh-token\",\"title\":\"Authorization Code with Refresh Token\",\"body\":\"The Authorization Code flow is a redirection-based flow,\\nwhich means the application must be able to redirect the application user\\nand receive authorization codes via a web browser.Phase 1: Authorization Phase\\nTo authorize, use this code:\\nrequire 'gecko-ruby'\\noauth_client = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>).oauth_client\\nauthorization_url = oauth_client.auth_code.authorize_url(redirect_uri: '<REDIRECT_URI>')\\n#=> \\\"https://go.tradegecko.com/oauth/authorize?client_id=<CLIENT_ID>&redirect_uri=<REDIRECT_URI>&response_type=code\\\"\\nredirect_to authorization_url\\nopen https://go.tradegecko.com/oauth/authorize?client_id=<CLIENT_ID>&redirect_uri=<REDIRECT_URI>&response_type=code\\n\\nMake sure to replace <OAUTH_ID>, <OAUTH_SECRET> <REDIRECT_URI> with your details.\\nAn authorization code is the key used to retrieve the access token.\\nIn order to acquire an authorization code, you need to redirect the user's\\nbrowser to the authorization endpoint.https://api.tradegecko.com/oauth/authorize?response_type=code&client_id=<CLIENT_ID>&redirect_uri=<REDIRECT_URI>\\nhttps://api.tradegecko.com/oauth/authorize: indicates the API authorization endpoint.\\nresponse_type=code: specifies that your application is requesting an authorization code grant.\\nclient_id=<CLIENT_ID>: the application's client ID provided when registering your application.\\nredirect_uri=<REDIRECT_URI>: should be set to a URL in your application where\\nthe user will be redirected back to after the request is authorized.\\nPhase 2: User AuthorizationOnce directed to the above link, the user will be asked to log in to their TradeGecko account (if they're not already logged in).\\nThey will then be asked to authorize or deny the authentication request.\\n  \\nPhase 3: Authorization Code responseAfter the user successfully authorizes the application, they will be redirected back to\\nthe provided redirect_uri with the authorization code as a query parameter named code.e.g. https://my.application.com/auth/app/callback?code=12bc6909c57aaa930Phase 4: Requesting an Access Tokencurl -H \\\"Content-type: application/json\\\" -X POST https://api.tradegecko.com/oauth/token -d '{\\\"client_id\\\": \\\"<CLIENT_ID>\\\", \\\"client_secret\\\":\\\"<CLIENT_SECRET>\\\", \\\"redirect_uri\\\": \\\"https://my.application.com/auth/app/callback\\\", \\\"code\\\": \\\"<CODE_FROM_PHASE_3>\\\", \\\"grant_type\\\": \\\"authorization_code\\\"}'\\n{\\n  \\\"access_token\\\": \\\"57ed301af04bf35b40f255feb5ef469ab2f046aff14\\\",\\n  \\\"expires_in\\\": 7200,\\n  \\\"refresh_token\\\": \\\"026b343de07818b3ffebfb3001eff9a00aea43da0a\\\",\\n  \\\"scope\\\": \\\"public\\\",\\n  \\\"token_type\\\": \\\"bearer\\\"\\n}\\nrequire 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\noauth_client = gecko.oauth_client\\naccess_token = oauth_client.auth_code.get_token(params[:code], redirect_uri: '<REDIRECT_URI>')\\ngecko.access_token = access_token\\ngecko.Account.current\\nThe access token is a unique key used to make requests to the API.In order to get an access token, the application must make a POST request to\\nhttps://api.tradegecko.com/oauth/token with the client_id,\\nclient_secret, redirect_uri, code and grant_type as parameters.\\nhttps://api.tradegecko.com/oauth/token: indicates the API token endpoint.\\ngrant_type=authorization_code: specifies that your application is requesting an authorization code.\\nclient_id=<CLIENT_ID>: the application's client ID provided when registering your application.\\nclient_secret=<CLIENT_SECRET>: the application's client secret provided when registering your application.\\nredirect_uri=<REDIRECT_URI>: should be set to a URL in your application where the code will be received.\\ncode=<CODE>  must match the authorization code returned by the authorization endpoint in Phase 3\\naccess_token.to_hash\\n#=> {\\\"token_type\\\"=>\\\"bearer\\\", \\\"scope\\\"=>\\\"public\\\", \\\"created_at\\\"=>1500000000, :access_token=>\\\"<ACCESS_TOKEN>\\\", :refresh_token=>\\\"<REFRESH_TOKEN>\\\", :expires_at=>1500007200}\\nOnce you have generated the access_token, this is the point where you will likely\\nwant to save off the details for future reuse without requiring user interaction.\\nTo reconstruct a refreshable access token you will need to store\\nthe access_token and refresh_token parameters returned.Phase 5: Refreshing an Access Tokencurl -H \\\"Content-type: application/json\\\" -X POST https://api.tradegecko.com/oauth/token -d '{\\\"client_id\\\": \\\"<CLIENT_ID>\\\", \\\"client_secret\\\": \\\"<CLIENT_SECRET>\\\", \\\"redirect_uri\\\": \\\"http://my.application.com/auth/callback\\\", \\\"refresh_token\\\": \\\"<REFRESH_TOKEN>\\\", \\\"grant_type\\\": \\\"refresh_token\\\"}'\\n{\\n  \\\"access_token\\\": \\\"439fc57cf1525e51555\\\",\\n  \\\"expires_in\\\": 7200,\\n  \\\"refresh_token\\\": \\\"ecfa1a22bd612cc1d8\\\",\\n  \\\"scope\\\": \\\"public\\\",\\n  \\\"token_type\\\": \\\"bearer\\\"\\n}\\n# From existing access_token object\\naccess_token.refresh!\\naccess_token.to_hash # For storage\\n\\n# From string\\nrequire 'gecko-ruby'\\ngecko = Gecko::Client.new(\\\"<OAUTH_ID>\\\", \\\"<OAUTH_SECRET>\\\")\\ngecko.authorize_from_refresh_token(\\\"<REFRESH_TOKEN>\\\")\\ngecko.access_token.to_hash # For storage\\nA refresh token is a unique token returned when creating an access token that can be\\nused to request a new access token when the existing current access token expires.To refresh an access token, the application must make a POST request to\\nhttps://api.tradegecko.com/oauth/token with the client_id,\\nclient_secret, redirect_uri, refresh_token and grant_type as parameters.\\nhttps://api.tradegecko.com/oauth/token: indicates the API token endpoint.\\ngrant_type=refresh_token: specifies that your application is requesting an refresh token.\\nclient_id=<CLIENT_ID>: the application's client ID provided when registering your application.\\nclient_secret=<CLIENT_SECRET>: the application's client secret provided when registering your application.\\nredirect_uri=<REDIRECT_URI>: should be set to a URL in your application where the code will be received.\\nrefresh_token: must match the refresh token returned by the authorization endpoint in Phase 4\\n\\n**Note:** When the access token is refreshed, a new refresh token is\\ngenerated and this should be stored and used the next time the token is refreshed is invoked.\\nUsing an expired refresh token will return an error.\\n\"},{\"id\":\"resource-owner-password-credentials-flow\",\"title\":\"Resource Owner Password Credentials flow\",\"body\":\"The TradeGecko API also supports the Resource Owner Password Credentials flow\\nthrough the concept of Privileged Access Tokens.These tokens are generated through the TradeGecko UI and do not expire.\\nThis means that you can access the API using the privileged token without the need\\nto use browser redirects or manage refresh tokens.However you will need to manually manage key rotation yourselves if your privileged\\nkey gets compromised in any way.Because of the inherent higher safety risks involved in storing privileged access tokens,\\nthe Resource Owner Password Credentials flow is only available on single-account Applications.\\nOnce you have obtained your Privileged Access Token, you can use cURL or Ruby to check if it is working.\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <PRIVILEGED_ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/accounts/current\\nrequire 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\ngecko.authorize_from_existing(<PRIVILEGED_ACCESS_TOKEN>, nil, nil)\\ngecko.Account.current\\nPhase 1: Privileged Access Token GenerationAs the application developer, after registering your application,\\nyou will see a button to \\\"Create a Privileged Token\\\" for the application.\\n  \\nIf you have already registered your application, you can add a privileged token by\\nfinding your application in your TradeGecko App List.\\nImportant: The Privileged Access Tokens provide unfettered access to your TradeGecko\\naccount, be very careful to store them securely.\\n\"},{\"id\":\"pagination\",\"title\":\"Pagination\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/users?limit=5&page=2\\nrequire 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.User.where(limit: 5, page: 2)\\nThe TradeGecko API enables pagination via limit\\nand page query parameters on GET requests to index pages. The default page size is 50 items, with the maximum page size being 250.\"},{\"id\":\"filtering-collections\",\"title\":\"Filtering Collections\",\"body\":\"The TradeGecko API allows filtering of records by passing along query parameters.\\nThese are some of the filters currently allowed by the API (where relevant).curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/products?created_at_min=2015-11-04/\\nrequire 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Product.where(created_at_min: \\\"2015-11-04\\\")\\nIndex Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of object IDs, see Batching Requests\\n\\n\\ncreated_at_min\\nReturn objects only created since\\n\\n\\ncreated_at_max\\nReturn objects only created before\\n\\n\\nupdated_at_min\\nReturn objects only updated since\\n\\n\\nupdated_at_max\\nReturn objects only updated before\\n\\n\\norder\\nThe order to return the collection i.e \\\"?order=created_at desc\\\"\\n\\n\\nlimit\\nSee Pagination (default is 50)\\n\\n\\npage\\nSee Pagination\\n\\nIn addition, each record type has their own specific filters; \\nthese filters are covered in their respective sections.Batching RequestsRequests can be batched together to get records with different IDs in a single API call.\\nGET https://api.tradegecko.com/products?ids[]=1&ids[]=2Batching can also be done to return the results of multiple possible values.\\nFor example, a single API call can return products with multiple brands:\\nGET https://api.tradegecko.com/products?brand[]=ABC&brand[]=XYZOr statuses:\\nGET https://api.tradegecko.com/orders?status[]=draft&status[]=activeComma-separated support for Integer filtersFor ID based filters, optionally a comma-separated collection can be used instead for brevity.\\nGET https://api.tradegecko.com/products?ids=1,2, or\\nGET https://api.tradegecko.com/variants?product_id=1,2Combining Multiple Filters in a Single callYou can combine filters in a single API call to return tighter subsets of results.\\nGET https://api.tradegecko.com/companies?company_status=active&company_type=supplier&order=created_at+desc&page=2&limit=20\"},{\"id\":\"response-metadata\",\"title\":\"Response Metadata\",\"body\":\"Every response returned from the TradeGecko API returns some useful pieces of information in the response headers.\"},{\"id\":\"request-ids\",\"title\":\"Request IDs\",\"body\":\"Every response will include an X-Request-ID parameter unique to that specific request.\\nIf you need to contact us about a specific request, please make sure to include the specific request ID in any communication with us to help speed up investigations.\"},{\"id\":\"pagination-links\",\"title\":\"Pagination Links\",\"body\":\"curl -IXGET https://api.tradegecko.com/products?page=1 -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <PRIVILEGED_ACCESS_TOKEN>\\\" | grep X-Pagination\\nX-Pagination: {\\\"total_records\\\":3103,\\\"total_pages\\\":32,\\\"first_page\\\":true,\\\"last_page\\\":false,\\\"out_of_bounds\\\":false,\\\"offset\\\":0}\\nEvery response that returns a collection will include pagination data in the headers.\\nThis data can be found as JSON under the X-Pagination header.\\ntotal_records: The total number of records matching the filters (excludes page & limit params).\\ntotal_pages: The total number of pages of records matching the filters.\\nfirst_page: true/false based on whether this is the first page of results.\\nlast_page: true/false based on whether this is the last page of results.\\nout_of_bounds: true/false based on whether the pagination request is out of bounds.\\noffset: The offset from 0 for the start of this page\\n\\nA small handful of endpoints include a `meta` key in the JSON, \\nthis is for historical reasons and should not be relied on, please use the pagination headers instead.\\n\"},{\"id\":\"rate-limiting\",\"title\":\"Rate Limiting\",\"body\":\"The TradeGecko API provides a rate limit of 300 requests per 300 seconds.curl -IXGET https://api.tradegecko.com/products?page=1 -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" | grep X-Rate-Limit\\nX-Rate-Limit-Limit: 300\\nX-Rate-Limit-Remaining: 291\\nX-Rate-Limit-Reset: 1509339000\\nYour current rate limit quota is provided in the response headers of every request.\\n\\nHeader\\nDescription\\n\\n\\n\\nX-Rate-Limit-Limit\\nNumber of requests available for this application (always 300)       .\\n\\n\\nX-Rate-Limit-Remaining\\nNumber of requests remaining in quota\\n\\n\\nX-Rate-Limit-Reset\\nThe timestamp (as seconds since epoch) when the quota will reset.\\n\\nIf you go over this limit the API will return a response with a status code of 429 until the reset time.  \\n The API limit is tracked against the combination of application and account, so if your application is serving multiple accounts each account will have it's own quota.\\n\"},{\"id\":\"idempotency-tokens\",\"title\":\"Idempotency Tokens\",\"body\":\"curl https://api.tradegecko.com/orders/ </span>\\n     -X POST </span>\\n     -H \\\"Idempotency-Key: ecf83ef1-0f85-4860-bbc3-70a4bd74be41\\\" </span>\\n     -H \\\"Content-type: application/json\\\" </span>\\n     -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" </span>\\n     -d '{\\\"order\\\": {\\\"company_id\\\": 101, \\\"shipping_address_id\\\": 1002, \\\"billing_address_id\\\": 1002, \\\"status\\\": \\\"active\\\", \\\"issued_at\\\": \\\"21-02-2018\\\", \\\"order_line_items\\\": [{\\\"variant_id\\\": 14, \\\"quantity\\\": 1}, {\\\"variant_id\\\": 15, \\\"quantity\\\": 2}]}}'\\norder = gecko.Order.build({\\n  company_id: 101,\\n  shipping_address_id: 1002,\\n  billing_address_id: 1002,\\n  issued_at: Time.now,\\n})\\norder.order_line_items.build(variant_id: 14, quantity: 1)\\norder.order_line_items.build(variant_id: 15, quantity: 2)\\norder.save(idempotency_token: \\\"ecf83ef1-0f85-4860-bbc3-70a4bd74be41\\\")\\nThe TradeGecko API has support for idempotent \\nrequests via an optional Idempotency-Key request header.\\nBy providing a unique Idempotency key in your POST or PUT requests the API can \\nguarantee that a specific operation is only performed once.The keys expire after 24 hours.\"},{\"id\":\"soft-deletion\",\"title\":\"Soft Deletion\",\"body\":\"TradeGecko uses soft-deletion for most of its records. \\nIn the API, a soft-deleted object will have a status of archived. \\nThese records will not be returned by default, but can be accessed using filters to \\nspecifically return records with a status of archived.\"},{\"id\":\"webhooks\",\"title\":\"Webhooks\",\"body\":\"You can use webhooks to receive notifications fo a collection of common events, see the list here.Once you've created a webhook via the API, any time that matching event is triggered in the customer's TradeGecko account, the endpoint will receive a POST request.The Webhook notificationThe webhook request you received will include a JSON serialized payload including the\\nobject_id, event, a timestamp and the resource_url.  {\\n    \\\"object_id\\\": 1234567,\\n    \\\"event\\\": \\\"fulfillments.create\\\",\\n    \\\"timestamp\\\": 1546272000,\\n    \\\"resource_url\\\": \\\"https://api.tradegecko.com/fulfillments/1234567.json\\\"\\n  }\\nIt will also include some specific HTTP headers.X-Gecko-Delivery: A unique identifier for the event, if you have any issues with webhooks, please provide this value when submitting any support ticket.X-Gecko-Signature: A signed signature for verification.To ensure the request comes from TradeGecko itself and is not being spoofed be sure to verify the\\nsignature agains the payload received.An example implementation in Ruby is provided.def generate_signature(body)\\n  digest = OpenSSL::Digest.new('sha256')\\n  Base64.encode64(OpenSSL::HMAC.digest(digest, application.secret, body.to_json)).strip\\nend\\nResponding to a webhookWhen receiving a webhook, the request must complete within a 10-second window, we highly recommending processing the webhooks asynchronously to avoid any problems.We use HTTP response codes to determine whether a webhook has been received successfully.\\nIf your server returns a HTTP status code between 200 and 399, we assume it has been processed successfully.A HTTP 410 Gone response will automatically delete the webhook.Other responses will cause the outgoing request to be retried, based on an exponential backoff strategy.If we receive unsuccessful responses consecutively for 3 days, the webhook will be deleted. Any successful response within the 3 day period will reset the counter.\\nApplication developers will receive daily emails to notify them of webhook failure and webhook deletion.\"},{\"id\":\"sideloading-resources\",\"title\":\"Sideloading Resources\",\"body\":\"TradeGecko allows you retrieve associated resources as part of a single request.\\nThis can be done by adding an include parameter containing a comma-separated list of resources to load.\\n  Sideloading for Orders and Purchase Orders are currently available only when retrieving a single order or purchase order. Using the `include` parameter won't work on index pages.\\nHere's a few examples:Fetching a ProductGET https://api.tradegecko.com/products/1?include=variantscurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" https://api.tradegecko.com/products/153172?include=variants\\n{\\n   \\\"variants\\\":[\\n      {\\n         \\\"id\\\":558277,\\n         \\\"created_at\\\":\\\"2013-11-18T03:00:38.459Z\\\",\\n         \\\"updated_at\\\":\\\"2018-05-23T08:02:29.569Z\\\",\\n         \\\"product_id\\\":153172,\\n         ...\\n      }\\n   ],\\n   \\\"product\\\":{\\n      \\\"id\\\":153172,\\n      \\\"created_at\\\":\\\"2013-07-23T16:25:36.582Z\\\",\\n      \\\"updated_at\\\":\\\"2018-09-01T04:54:25.085Z\\\",\\n      \\\"brand\\\":null,\\n      \\\"description\\\":\\\"Wiggly and squiggly. Watch out for the tail falling off!\\\\u003cbr\\\\u003e\\\",\\n      \\\"image_url\\\":null,\\n      ...\\n   }\\n}\\nFetching an OrderGET https://api.tradegecko.com/orders/160?include=order_line_items,shipping_address,billing_address,companycurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" https://api.tradegecko.com/orders?include=order_line_items,shipping_address,billing_address,company\\n{\\n   \\\"order_line_items\\\":[\\n      {\\n         \\\"id\\\":335,\\n         \\\"created_at\\\":\\\"2018-02-23T07:54:43.756Z\\\",\\n         \\\"updated_at\\\":\\\"2018-03-22T13:50:57.564Z\\\",\\n         \\\"order_id\\\":160,\\n         \\\"variant_id\\\":1193,\\n         ...\\n      },\\n      {\\n         \\\"id\\\":336,\\n         \\\"created_at\\\":\\\"2018-02-23T07:54:43.765Z\\\",\\n         \\\"updated_at\\\":\\\"2018-03-22T13:50:57.507Z\\\",\\n         \\\"order_id\\\":160,\\n         \\\"variant_id\\\":1199,\\n         ...\\n      },\\n      {\\n         \\\"id\\\":337,\\n         \\\"created_at\\\":\\\"2018-02-23T07:54:43.774Z\\\",\\n         \\\"updated_at\\\":\\\"2018-03-22T13:50:57.475Z\\\",\\n         \\\"order_id\\\":160,\\n         \\\"variant_id\\\":1182,\\n         ...\\n      }\\n   ],\\n   \\\"addresses\\\":[\\n      {\\n         \\\"id\\\":147,\\n         \\\"created_at\\\":\\\"2018-02-23T07:54:42.462Z\\\",\\n         \\\"updated_at\\\":\\\"2018-02-23T07:54:42.462Z\\\",\\n         \\\"company_id\\\":96,\\n         \\\"address1\\\":\\\"1260 Billy Plaza\\\",\\n         ...\\n      },\\n      {\\n         \\\"id\\\":146,\\n         \\\"created_at\\\":\\\"2018-02-23T07:54:42.460Z\\\",\\n         \\\"updated_at\\\":\\\"2018-02-23T07:54:42.460Z\\\",\\n         \\\"company_id\\\":96,\\n         \\\"address1\\\":\\\"620 Pfannerstill Run\\\",\\n         ...\\n      }\\n   ],\\n   \\\"companies\\\":[\\n      {\\n         \\\"id\\\":96,\\n         \\\"created_at\\\":\\\"2018-02-23T07:54:42.457Z\\\",\\n         \\\"updated_at\\\":\\\"2018-03-22T13:50:30.892Z\\\",\\n         ...\\n      }\\n   ],\\n   \\\"order\\\":{\\n      \\\"id\\\":160,\\n      \\\"created_at\\\":\\\"2018-02-23T07:54:43.683Z\\\",\\n      \\\"updated_at\\\":\\\"2018-09-24T03:29:30.759Z\\\",\\n      \\\"assignee_id\\\":null,\\n      \\\"billing_address_id\\\":147,\\n      \\\"company_id\\\":96,\\n      \\\"contact_id\\\":null,\\n      ...\\n   }\\n}\\nFetching a Bundle Product Variant's CompositionSideloading parameters for composition API work for both single and collection actions. Examples:GET https://api.tradegecko.com/variants/composition?include=bundleGET https://api.tradegecko.com/variants/composition/1?include=bundle,componentcurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" https://api.tradegecko.com/variants/composition?include=bundle,component\\n{\\n   \\\"variants\\\": [\\n      {\\n         \\\"id\\\": 1,\\n         \\\"sku\\\": \\\"DRK-0001\\\",\\n         ...\\n      },\\n      {\\n         \\\"id\\\": 2,\\n         \\\"sku\\\": \\\"DRINK-PACK-SKU\\\",\\n         ...\\n      },\\n      ...\\n   ],\\n   \\\"composition\\\": [\\n      {\\n         \\\"bundle_sku\\\": \\\"DRINK-PACK-SKU\\\",\\n         \\\"component_sku\\\": \\\"DRK-0001\\\",\\n         \\\"quantity\\\": \\\"6.0\\\",\\n         \\\"bundle_id\\\": 2,\\n         \\\"component_id\\\": 1\\n      },\\n      ...\\n   ]\\n}\\n\"},{\"id\":\"errors\",\"title\":\"Errors\",\"body\":\"The TradeGecko API uses the following error codes:\\n\\nError Code\\nMeaning\\n\\n\\n\\n400\\nBad Request -- You have passed a malformed request\\n\\n\\n401\\nUnauthorized -- Your API access token is invalid\\n\\n\\n402\\nPayment Required -- Your subscription has lapsed\\n\\n\\n403\\nForbidden -- The resource requested is not available with your permissions\\n\\n\\n404\\nNot Found -- The specified resource could not be found\\n\\n\\n414\\nRequest URI too long -- You have applied too many filters on a GET request\\n\\n\\n422\\nUnprocessable Entity -- Your request is invalid\\n\\n\\n429\\nToo Many Requests -- You are allowed 300 requests per 300 seconds\\n\\n\\n500\\nInternal Server Error -- We had a problem with our server. Try again later\\n\\n\\n503\\nService Unavailable (Time out) -- The server was unable to finish the request in time, either the server was overloaded or if fetching large pages of data, please try using a smaller page size\\n\\n\"},{\"id\":\"guides\",\"title\":\"Guides\",\"body\":\"Check out these guides to start integrating TradeGecko with your external sales channels, fulfillment services or warehouse management systems: \\n     Ecommerce Integration Guide\\n  \\n     Fulfillment Service Integration Guide\\n  \\n     Warehouse Management Integration Guide\\n  \"},{\"id\":\"creating-a-sales-order\",\"title\":\"Creating a Sales Order\",\"body\":\"There are several ways to create a Sales Order via the TradeGecko API, \\ndepending on the number of line items, and whether the order is being made to a \\nnew or existing customer.We're going to be POSTing a minimal JSON to the /orders endpoint.\\nCheck out The Order Object for descriptions of all \\nof the available fields.As always, check the sidebar for example code.Here's a few examples:\\nCreating a Sales Order for an existing customer being shipped and billed to an existing address.\\nCreating a Sales Order for an existing customer, but to a new address.\\nCreating a Sales Order for a new customer.\\n1. Order with Existing Customer{\\n  \\\"order\\\": {\\n    \\\"company_id\\\": 101,\\n    \\\"shipping_address_id\\\": 1002,\\n    \\\"billing_address_id\\\": 1002,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"issued_at\\\": \\\"21-02-2018\\\",\\n    \\\"order_line_items\\\": [\\n      { \\\"variant_id\\\": 14, \\\"quantity\\\": 1 },\\n      { \\\"variant_id\\\": 15, \\\"quantity\\\": 2 }\\n    ]\\n  }\\n}\\norder = gecko.Order.build({\\n  company_id: 101,\\n  shipping_address_id: 1002,\\n  billing_address_id: 1002,\\n  issued_at: Time.now,\\n})\\norder.order_line_items.build(variant_id: 14, quantity: 1)\\norder.order_line_items.build(variant_id: 15, quantity: 2)\\norder.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" https://api.tradegecko.com/orders/ \\\\\\n-d '{\\\"order\\\": {\\\"company_id\\\": 101, \\\"shipping_address_id\\\": 1002, \\\"billing_address_id\\\": 1002, \\\"status\\\": \\\"active\\\", \\\"issued_at\\\": \\\"21-02-2018\\\", \\\"order_line_items\\\": [{\\\"variant_id\\\": 14, \\\"quantity\\\": 1}, {\\\"variant_id\\\": 15, \\\"quantity\\\": 2}]}}'\\n2. Order with Existing Customer but new addressWe have two options here, we can either create the address in a separate request,\\nor as in the JSON below we can embed the new address inside the Order JSON and\\nit will get created for us.{\\n  \\\"order\\\": {\\n    \\\"company_id\\\": 101,\\n    \\\"shipping_address\\\": {\\n      \\\"address1\\\": \\\"123 Cross St\\\",\\n      \\\"city\\\": \\\"Springfield\\\",\\n      \\\"country\\\": \\\"United States of America\\\",\\n      \\\"label\\\": \\\"Head Office\\\"\\n    },\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"issued_at\\\": \\\"21-02-2018\\\",\\n    \\\"order_line_items\\\": [\\n      { \\\"variant_id\\\": 14, \\\"quantity\\\": 1 },\\n      { \\\"variant_id\\\": 15, \\\"quantity\\\": 2 }\\n    ]\\n  }\\n}\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" https://api.tradegecko.com/orders/\\n-d '{\\\"order\\\": {\\\"company_id\\\": 101, \\\"shipping_address\\\": {\\\"address1\\\": \\\"123 Cross St\\\", \\\"city\\\": \\\"Springfield\\\", \\\"country\\\": \\\"United States of America\\\", \\\"label\\\": \\\"Head Office\\\"}, \\\"status\\\": \\\"active\\\", \\\"issued_at\\\": \\\"21-02-2018\\\", \\\"order_line_items\\\": [{\\\"variant_id\\\": 14, \\\"quantity\\\": 1}, {\\\"variant_id\\\": 15, \\\"quantity\\\": 2}]}}'\\n# The rubygem does not yet support creating nested addresses,\\n# so this will make two API requests.\\naddress = gecko.Address.build({\\n  company_id: 101,\\n  address1: \\\"123 Cross St\\\",\\n  city: \\\"Springfield\\\",\\n  country: \\\"United States of America\\\",\\n  label: \\\"Head Office\\\"\\n})\\naddress.save\\norder = gecko.Order.build({\\n  company_id: 101,\\n  shipping_address_id: address.id,\\n  billing_address_id: address.id,\\n  issued_at: Time.now,\\n})\\norder.order_line_items.build(variant_id: 14, quantity: 1)\\norder.order_line_items.build(variant_id: 15, quantity: 2)\\norder.save\\n\\n  If you are unsure whether an address exists in your system yet, you will need to\\n  handle lookup separately as the order endpoint does not do any address deduping work.\\n\\n  In the example above we have not included a billing address,\\n  if the billing address is not included the API will assume the shipping address\\n  is the same as the billing address, if there is a different billing address,\\n  then either include a `billing_address_id` if the address already exists,\\n  or nest a new address under the `billing_address` key.\\n3. Order for New CustomerIf the order is for a new company, the company can either be created via a separate\\nrequest, or nested inside the order.\\nIf nesting inside the order, at least a shipping_address must be included as well.{\\n  \\\"order\\\": {\\n    \\\"company\\\": {\\n      \\\"name\\\": \\\"Bill's Boots\\\",\\n      \\\"company_code\\\": \\\"BB-123\\\",\\n      \\\"company_type\\\": \\\"business\\\",\\n      \\\"email\\\": \\\"billy@billsboots.com\\\",\\n      \\\"website\\\": \\\"https://billsboots.com\\\"\\n    },\\n    \\\"shipping_address\\\": {\\n      \\\"address1\\\": \\\"123 Cross St\\\",\\n      \\\"city\\\": \\\"Springfield\\\",\\n      \\\"country\\\": \\\"United States of America\\\",\\n      \\\"label\\\": \\\"Head Office\\\"\\n    },\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"issued_at\\\": \\\"21-02-2018\\\",\\n    \\\"order_line_items\\\": [\\n      { \\\"variant_id\\\": 14, \\\"quantity\\\": 1 },\\n      { \\\"variant_id\\\": 15, \\\"quantity\\\": 2 }\\n    ]\\n  }\\n}\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\" https://api.tradegecko.com/orders/ \\\\\\n-d '{\\\"order\\\": {\\\"company\\\": {\\\"name\\\": \\\"Bill\\\\'s Boots\\\", \\\"company_code\\\": \\\"BB-123\\\", \\\"company_type\\\": \\\"business\\\", \\\"email\\\": \\\"billy@billsboots.com\\\", \\\"website\\\": \\\"https://billsboots.com\\\"}, \\\"shipping_address\\\": {\\\"address1\\\": \\\"123 Cross St\\\", \\\"city\\\": \\\"Springfield\\\", \\\"country\\\": \\\"United States of America\\\", \\\"label\\\": \\\"Head Office\\\"}, \\\"status\\\": \\\"active\\\", \\\"issued_at\\\": \\\"21-02-2018\\\", \\\"order_line_items\\\": [{\\\"variant_id\\\": 14, \\\"quantity\\\": 1}, {\\\"variant_id\\\": 15, \\\"quantity\\\": 2 }]}}'\\ncompany = gecko.Company.build({\\n  name: \\\"Bill's Boots\\\",\\n  company_code: \\\"BB-123\\\",\\n  company_type: \\\"business\\\",\\n  email: \\\"billy@billsboots.com\\\",\\n  website: \\\"https://billsboots.com\\\"\\n})\\ncompany.save\\naddress = gecko.Address.build({\\n  address1: \\\"123 Cross St\\\",\\n  city: \\\"Springfield\\\",\\n  country: \\\"United States of America\\\",\\n  label: \\\"Head Office\\\"\\n})\\naddress.save\\n  company_id: company.id,\\n  shipping_address_id: address.id,\\n  billing_address_id: address.id,\\n  issued_at: Time.now,\\n})\\norder.order_line_items.build(variant_id: 14, quantity: 1)\\norder.order_line_items.build(variant_id: 15, quantity: 2)\\norder.save\\nCreating a Sales Order with > 250 items.If you are regularly creating orders with several hundreds of items you may run into\\nthe occasional case where the server times out.To mitigate effects of timeouts we suggest the use of two extra mechanisms.1. Idempotency Tokens\\nBy using an Idempotency Token header when creating the\\nSales Order, you can automatically recover from occasional timeout errors by simply\\nretrying the POST request and the API will ensure only a single Sales Order is created.2. Multi-part Creates\\nFor an order with a significant number of line items, it may make sense to split\\nthem into multiple requests.\\nWe don't suggest unless you're running into regular issues with Sales Order size.\\nIn this case, create the Sales Order as above with a section of the line items\\n(150 for example), and then fire an Order update request with just an array of\\nthe next set of items.PUT /orders/12345{\\n  \\\"order\\\": {\\n    \\\"order_line_items\\\": [\\n      { \\\"variant_id\\\": 14, \\\"quantity\\\": 1 },\\n      { \\\"variant_id\\\": 15, \\\"quantity\\\": 2 }\\n    ]\\n  }\\n}\\n\\nIf you are regularly making > 400 line item orders via the TradeGecko API, please\\ncontact your success rep as we'd love to discuss your usecases further.\\n\"},{\"id\":\"resources\",\"title\":\"Resources\",\"body\":\"\"},{\"id\":\"account\",\"title\":\"Account\",\"body\":\"This is an object representing an account.\"},{\"id\":\"the-account-object\",\"title\":\"The Account object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nDate and time when the account was created.\\ntrue\\n\\n\\nupdated_at\\nString\\nDate and time when the account was last updated.\\ntrue\\n\\n\\ncontact_email\\nString\\nContact email used on TradeGecko documents and emails.\\n\\n\\n\\ncontact_mobile\\nString\\nContact mobile number for your account.\\n\\n\\n\\ncontact_phone\\nString\\nContact phone number used on TradeGecko documents and emails.\\n\\n\\n\\ncountry\\nString\\nNeeds to be a valid ISO3166-1 alpha-2 code (US, NZ, SG etc)\\n\\n\\n\\ndefault_order_price_list_id\\nString\\nThe default price list id for new Sales Orders, unless a price list is set on the company.\\n\\n\\n\\ndefault_purchase_order_price_list_id\\nString\\nThe default price list for new Purchase Orders, unless a price list is set on the company.\\n\\n\\n\\ndefault_sales_ledger_account_on\\nString\\nValue can either be 'company', 'variant' or 'channel'. This determines how your sales total will be tracked on.\\n\\n\\n\\ndefault_tax_treatment\\nString\\nValue can either be 'inclusive' or 'exclusive'. This will be the default tax treatment for orders created without assigning a tax_treatment attribute.\\n\\n\\n\\nindustry\\nString\\nThe industry in which your account belongs to.\\n\\n\\n\\nlogo_url  deprecated\\nString\\nImage URL for the account's logo.\\ntrue\\n\\n\\nname\\nString\\nName of the account.\\n\\n\\n\\nstock_level_warn\\nBoolean\\nShow a warning if attempting to ship a shipment without all the stock available\\n\\n\\n\\ntax_label\\nString\\nPrimary tax label for your business. e.g. VAT or GST.\\n\\n\\n\\ntax_number\\nString\\nYour company's tax number. e.g. 12-345-678.\\n\\n\\n\\ntax_number_label\\nString\\nTax Number Label for your Organization. e.g. VAT Number.\\n\\n\\n\\ntime_zone\\nString\\nThe name of the time zone in TZ format. e.g. Asia/Singapore\\n\\n\\n\\nwebsite\\nString\\nYour company's website URL.\\n\\n\\n\\nprimary_location_id\\nInteger\\nThe default location used when dealing with stock. New variants will be added here.\\n\\n\\n\\nprimary_billing_location_id\\nInteger\\nThe default billing address used on your document headers and purchase orders.\\n\\n\\n\\ndefault_currency_id\\nInteger\\nThe default currency for creating a new sales order.\\n\\n\\n\\ndefault_payment_method_id\\nInteger\\nThe default method of payment for creating a new payment.\\n\\n\\n\\ndefault_payment_term_id\\nInteger\\nThe default term of payment. This can also be used to push to multiple ledger accounts in your accounting integration.\\n\\n\\n\\nbilling_contact_id\\nInteger\\nAccount Owner, can only be transferred by existing owner\\n\\n\\n\\ndefault_sales_order_tax_type_id\\nInteger\\nThe default tax type for creating a new sales order.\\n\\n\\n\\ndefault_purchase_order_tax_type_id\\nInteger\\nThe default tax type that is selected when you create a new purchase order.\\n\\n\\n\\ndefault_tax_exempt_id\\nInteger\\nThe default tax type for non-taxable products.\\n\\n\\n\\ndefault_tax_rate  deprecated\\nString\\n\\ntrue\\n\\n\\ndefault_tax_type  deprecated\\nString\\n\\n\\n\\n\\ndefault_tax_type_id\\nInteger\\nThe default tax type for creating a new sales order.\\n\\n\\n\\ndefault_order_price_type_id  deprecated\\nString\\n\\n\\n\\n\\ndefault_purchase_order_price_type_id  deprecated\\nString\\n\\n\\n\\n\\nlocation_ids\\nArray\\nAn array of IDs of all the account's active locations\\ntrue\\n\\n\\nuser_ids\\nArray\\nAn array of IDs of all the account's active users\\ntrue\\n\\n\"},{\"id\":\"get-current-account\",\"title\":\"Get current account\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Account.current\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/accounts/current\\n{\\n  \\\"account\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:23.803Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:24.326Z\\\",\\n    \\\"contact_email\\\": \\\"lcp@tradegecko.com\\\",\\n    \\\"contact_mobile\\\": null,\\n    \\\"contact_phone\\\": null,\\n    \\\"country\\\": \\\"NZ\\\",\\n    \\\"default_order_price_list_id\\\": \\\"wholesale\\\",\\n    \\\"default_purchase_order_price_list_id\\\": \\\"buy\\\",\\n    \\\"default_sales_ledger_account_on\\\": \\\"company\\\",\\n    \\\"default_tax_treatment\\\": \\\"exclusive\\\",\\n    \\\"default_document_theme_id\\\": 1,\\n    \\\"industry\\\": \\\"\\\",\\n    \\\"logo_url\\\": null,\\n    \\\"name\\\": \\\"Bob's Burgers\\\",\\n    \\\"stock_level_warn\\\": true,\\n    \\\"tax_label\\\": \\\"GST\\\",\\n    \\\"tax_number\\\": null,\\n    \\\"tax_number_label\\\": \\\"GST Registration Number\\\",\\n    \\\"time_zone\\\": \\\"Pacific/Auckland\\\",\\n    \\\"website\\\": null,\\n    \\\"primary_location_id\\\": 1,\\n    \\\"primary_billing_location_id\\\": 1,\\n    \\\"default_currency_id\\\": 1,\\n    \\\"default_payment_method_id\\\": 2,\\n    \\\"default_payment_term_id\\\": 3,\\n    \\\"billing_contact_id\\\": 1,\\n    \\\"default_sales_order_tax_type_id\\\": 2,\\n    \\\"default_purchase_order_tax_type_id\\\": 3,\\n    \\\"default_tax_exempt_id\\\": 1,\\n    \\\"default_tax_rate\\\": \\\"15.0\\\",\\n    \\\"default_tax_type\\\": \\\"exclusive\\\",\\n    \\\"default_tax_type_id\\\": 2,\\n    \\\"default_order_price_type_id\\\": \\\"wholesale\\\",\\n    \\\"default_purchase_order_price_type_id\\\": \\\"buy\\\",\\n    \\\"location_ids\\\": [\\n      1\\n    ],\\n    \\\"user_ids\\\": [\\n      1\\n    ]\\n  }\\n}\\nRetrieves the details of the current account.HTTP RequestGET https://api.tradegecko.com/accounts/current\"},{\"id\":\"update-an-account\",\"title\":\"Update an account\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\naccount = gecko.Account.find(1)\\naccount.attributes = {\\n  country: \\\"US\\\"\\n}\\naccount.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/accounts/1 -d '{\\\"account\\\":{\\\"country\\\":\\\"US\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the account gets updated successfully.\\n\\nUpdates the specified account by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the account creation call.HTTP RequestPUT https://api.tradegecko.com/accounts/{RESOURCE_ID}\"},{\"id\":\"address\",\"title\":\"Address\",\"body\":\"This is an object representing an address of a company. Companies can\\n  have multiple addresses but an address object belongs to only one\\n  Company.\"},{\"id\":\"the-address-object\",\"title\":\"The Address object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nDate and time when the address was created.\\ntrue\\n\\n\\nupdated_at\\nString\\nDate and time when the address was last updated.\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'.\\ntrue\\n\\n\\ncompany_id\\nInteger\\nThe company id where the address belongs.\\n\\n\\n\\naddress1\\nString\\nFirst line of address.\\n\\n\\n\\naddress2\\nString\\nSecond line of address.\\n\\n\\n\\ncity\\nString\\nCity of an address.\\n\\n\\n\\ncompany_name\\nString\\nAttention to field of an address.\\n\\n\\n\\ncountry\\nString\\nCountry of an address.\\n\\n\\n\\ncountry_code\\nString\\nISO3166-1 alpha2 code for the country, will be generated from country field if not provided\\n\\n\\n\\nemail\\nString\\nEmail of person associated with address.\\n\\n\\n\\nfirst_name\\nString\\nFirst name of person associated with address. Used in attention to field.\\n\\n\\n\\nlast_name\\nString\\nLast name of person associated with address. Used in attention to field.\\n\\n\\n\\nlabel\\nString\\nA (unique per company) label for the address e.g. Shipping, Billing.\\n\\n\\n\\nphone_number\\nString\\nPhone number of person associated with address.\\n\\n\\n\\nstate\\nString\\nState of an address.\\n\\n\\n\\nsuburb\\nString\\nSuburb of an address.\\n\\n\\n\\nzip_code\\nString\\nZip code of an address.\\n\\n\\n\"},{\"id\":\"list-all-addresses\",\"title\":\"List all addresses\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Address.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/addresses/\\n{\\n  \\\"addresses\\\": [\\n    {\\n      \\\"id\\\": 6,\\n      \\\"created_at\\\": \\\"2015-11-04T06:59:35.285Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-04T06:59:35.285Z\\\",\\n      \\\"company_id\\\": 4,\\n      \\\"address1\\\": \\\"Test address\\\",\\n      \\\"address2\\\": \\\"\\\",\\n      \\\"city\\\": \\\"Singapore\\\",\\n      \\\"company_name\\\": \\\"\\\",\\n      \\\"country\\\": \\\"Singapore\\\",\\n      \\\"country_code\\\": \\\"SG\\\",\\n      \\\"email\\\": \\\"\\\",\\n      \\\"first_name\\\": null,\\n      \\\"last_name\\\": null,\\n      \\\"label\\\": \\\"Shipping\\\",\\n      \\\"phone_number\\\": \\\"\\\",\\n      \\\"state\\\": \\\"\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"suburb\\\": \\\"\\\",\\n      \\\"zip_code\\\": \\\"\\\"\\n    },\\n    {\\n      \\\"id\\\": 5,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.630Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:24.630Z\\\",\\n      \\\"company_id\\\": 3,\\n      \\\"address1\\\": \\\"06157 Waters Road\\\",\\n      \\\"address2\\\": \\\"505 Frederick Flat\\\",\\n      \\\"city\\\": \\\"East Trudie\\\",\\n      \\\"company_name\\\": null,\\n      \\\"country\\\": \\\"Great Britain\\\",\\n      \\\"country_code\\\": \\\"GB\\\",\\n      \\\"email\\\": \\\"samara@williamwonkacandyltd.com\\\",\\n      \\\"first_name\\\": null,\\n      \\\"last_name\\\": null,\\n      \\\"label\\\": \\\"Warehouse (DEMO)\\\",\\n      \\\"phone_number\\\": \\\"952-649-4655\\\",\\n      \\\"state\\\": null,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"suburb\\\": null,\\n      \\\"zip_code\\\": \\\"98366-5837\\\"\\n    }\\n  ]\\n}\\nReturns a list of addresses you’ve previously created. The addresses are returned in sorted order, with the most recent addresses appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of address IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\n\\ncompany_id\\nFilter addresses by company\\n\\nHTTP Request:GET  https://api.tradegecko.com/addresses\"},{\"id\":\"create-a-new-address\",\"title\":\"Create a new address\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\naddress = gecko.Address.build({\\n  company_id: 1,\\n  label: \\\"Main Office\\\",\\n  address1: \\\"12 Park Ave\\\"\\n})\\naddress.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/addresses/ -d '{\\\"address\\\":{\\\"company_id\\\":1,\\\"label\\\":\\\"Main Office\\\",\\\"address1\\\":\\\"12 Park Ave\\\"}}'\\n{\\n  \\\"address\\\": {\\n    \\\"id\\\": 6,\\n    \\\"created_at\\\": \\\"2015-11-04T06:59:35.285Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-04T06:59:35.285Z\\\",\\n    \\\"company_id\\\": 4,\\n    \\\"address1\\\": \\\"Test address\\\",\\n    \\\"address2\\\": \\\"\\\",\\n    \\\"city\\\": \\\"Singapore\\\",\\n    \\\"company_name\\\": \\\"\\\",\\n    \\\"country\\\": \\\"Singapore\\\",\\n    \\\"country_code\\\": \\\"SG\\\",\\n    \\\"email\\\": \\\"\\\",\\n    \\\"first_name\\\": null,\\n    \\\"last_name\\\": null,\\n    \\\"label\\\": \\\"Shipping\\\",\\n    \\\"phone_number\\\": \\\"\\\",\\n    \\\"state\\\": \\\"\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"suburb\\\": \\\"\\\",\\n    \\\"zip_code\\\": \\\"\\\"\\n  }\\n}\\nCreates a new address object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ncompany_id\\nInteger\\nThe company id where the address belongs.\\ntrue\\n\\n\\naddress1\\nString\\nFirst line of address.\\ntrue\\n\\n\\naddress2\\nString\\nSecond line of address.\\n\\n\\n\\ncity\\nString\\nCity of an address.\\n\\n\\n\\ncompany_name\\nString\\nAttention to field of an address.\\n\\n\\n\\ncountry\\nString\\nCountry of an address.\\n\\n\\n\\ncountry_code\\nString\\nISO3166-1 alpha2 code for the country, will be generated from country field if not provided\\n\\n\\n\\nemail\\nString\\nEmail of person associated with address.\\n\\n\\n\\nfirst_name\\nString\\nFirst name of person associated with address. Used in attention to field.\\n\\n\\n\\nlast_name\\nString\\nLast name of person associated with address. Used in attention to field.\\n\\n\\n\\nlabel\\nString\\nA (unique per company) label for the address e.g. Shipping, Billing.\\n\\n\\n\\nphone_number\\nString\\nPhone number of person associated with address.\\n\\n\\n\\nstate\\nString\\nState of an address.\\n\\n\\n\\nsuburb\\nString\\nSuburb of an address.\\n\\n\\n\\nzip_code\\nString\\nZip code of an address.\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/addresses/\"},{\"id\":\"retrieve-a-particular-address\",\"title\":\"Retrieve a particular address\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Address.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/addresses/1\\n{\\n  \\\"address\\\": {\\n    \\\"id\\\": 6,\\n    \\\"created_at\\\": \\\"2015-11-04T06:59:35.285Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-04T06:59:35.285Z\\\",\\n    \\\"company_id\\\": 4,\\n    \\\"address1\\\": \\\"Test address\\\",\\n    \\\"address2\\\": \\\"\\\",\\n    \\\"city\\\": \\\"Singapore\\\",\\n    \\\"company_name\\\": \\\"\\\",\\n    \\\"country\\\": \\\"Singapore\\\",\\n    \\\"country_code\\\": \\\"SG\\\",\\n    \\\"email\\\": \\\"\\\",\\n    \\\"first_name\\\": null,\\n    \\\"last_name\\\": null,\\n    \\\"label\\\": \\\"Shipping\\\",\\n    \\\"phone_number\\\": \\\"\\\",\\n    \\\"state\\\": \\\"\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"suburb\\\": \\\"\\\",\\n    \\\"zip_code\\\": \\\"\\\"\\n  }\\n}\\nRetrieves the details of an existing address. You need only supply the unique address identifier that was returned upon address creation.HTTP RequestGET https://api.tradegecko.com/addresses/{RESOURCE_ID}\"},{\"id\":\"update-an-address\",\"title\":\"Update an address\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\naddress = gecko.Address.find(1)\\naddress.attributes = {\\n  address1: \\\"12 Park Ave\\\",\\n  city: \\\"Singapore\\\",\\n  label: \\\"Main Office\\\"\\n}\\naddress.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/addresses/1 -d '{\\\"address\\\":{\\\"address1\\\":\\\"12 Park Ave\\\",\\\"city\\\":\\\"Singapore\\\",\\\"label\\\":\\\"Main Office\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the address gets updated successfully.\\n\\nUpdates the specified address by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the address creation call.HTTP RequestPUT https://api.tradegecko.com/addresses/{RESOURCE_ID}\"},{\"id\":\"delete-an-address\",\"title\":\"Delete an address\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\naddress = gecko.Address.find(1)\\naddress.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/addresses/1\\n\\nResponse\\n\\nReturns 204 status when the address gets deleted successfully.\\n\\nPermanently deletes an address. It cannot be undone.\\n  This address will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/addresses/{RESOURCE_ID}/\"},{\"id\":\"company\",\"title\":\"Company\",\"body\":\"This is an object representing a company.\"},{\"id\":\"the-company-object\",\"title\":\"The Company object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active', 'disabled' or 'archived'\\n\\n\\n\\nassignee_id\\nInteger\\nID of the user to which new PO/SO will be assigned by default\\n\\n\\n\\ndefault_ledger_account_id\\nInteger\\n\\n\\n\\n\\ndefault_payment_method_id\\nInteger\\n\\n\\n\\n\\ndefault_payment_term_id\\nInteger\\n\\n\\n\\n\\ndefault_stock_location_id\\nInteger\\n\\n\\n\\n\\ndefault_tax_type_id\\nInteger\\n\\n\\n\\n\\ncompany_code\\nString\\nA unique identifier for your records\\n\\n\\n\\ncompany_type\\nString\\nCan be 'business', 'supplier' or 'consumer'\\n\\n\\n\\ndefault_discount_rate\\nString\\n\\n\\n\\n\\ndefault_price_list_id\\nString\\n\\n\\n\\n\\ndefault_tax_rate  deprecated\\nString\\nAlias to default_tax_type#effective_rate\\n\\n\\n\\ndescription\\nString\\n\\n\\n\\n\\nemail\\nString\\n\\n\\n\\n\\nfax\\nString\\n\\n\\n\\n\\nname\\nString\\n\\n\\n\\n\\nphone_number\\nString\\n\\n\\n\\n\\ntax_number\\nString\\n\\n\\n\\n\\nwebsite\\nString\\n\\n\\n\\n\\ntags\\nArray[String]\\nCompany tags for easier filtering and searching\\n\\n\\n\\naddress_ids\\nArray\\n\\ntrue\\n\\n\\ncontact_ids\\nArray\\n\\ntrue\\n\\n\\nnote_ids\\nArray\\n\\ntrue\\n\\n\\ndefault_price_type_id  deprecated\\nString\\nUse default_price_list_id instead\\n\\n\\n\"},{\"id\":\"list-all-companies\",\"title\":\"List all companies\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Company.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/companies/\\n{\\n  \\\"companies\\\": [\\n    {\\n      \\\"id\\\": 4,\\n      \\\"created_at\\\": \\\"2015-11-02T01:44:42.417Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:44:42.417Z\\\",\\n      \\\"assignee_id\\\": 1,\\n      \\\"default_ledger_account_id\\\": null,\\n      \\\"default_payment_method_id\\\": null,\\n      \\\"default_payment_term_id\\\": null,\\n      \\\"default_stock_location_id\\\": null,\\n      \\\"default_tax_type_id\\\": null,\\n      \\\"company_code\\\": null,\\n      \\\"company_type\\\": \\\"business\\\",\\n      \\\"default_discount_rate\\\": null,\\n      \\\"default_price_list_id\\\": null,\\n      \\\"default_tax_rate\\\": null,\\n      \\\"default_document_theme_id\\\": null,\\n      \\\"description\\\": \\\"\\\",\\n      \\\"email\\\": null,\\n      \\\"fax\\\": null,\\n      \\\"name\\\": \\\"B2B Test Company\\\",\\n      \\\"phone_number\\\": null,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"tax_number\\\": null,\\n      \\\"website\\\": null,\\n      \\\"tags\\\": [\\n\\n],\\n      \\\"address_ids\\\": [\\n        6\\n      ],\\n      \\\"contact_ids\\\": [\\n        7\\n      ],\\n      \\\"note_ids\\\": [\\n\\n],\\n      \\\"default_price_type_id\\\": null\\n    },\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.612Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:24.612Z\\\",\\n      \\\"assignee_id\\\": null,\\n      \\\"default_ledger_account_id\\\": null,\\n      \\\"default_payment_method_id\\\": null,\\n      \\\"default_payment_term_id\\\": null,\\n      \\\"default_stock_location_id\\\": null,\\n      \\\"default_tax_type_id\\\": null,\\n      \\\"company_code\\\": null,\\n      \\\"company_type\\\": \\\"supplier\\\",\\n      \\\"default_discount_rate\\\": null,\\n      \\\"default_price_list_id\\\": null,\\n      \\\"default_tax_rate\\\": null,\\n      \\\"default_document_theme_id\\\": null,\\n      \\\"description\\\": \\\"Greatest Candy-maker and chocolatier of all time and place\\\",\\n      \\\"email\\\": \\\"william@example.com\\\",\\n      \\\"fax\\\": null,\\n      \\\"name\\\": \\\"Wonka Candy (DEMO)\\\",\\n      \\\"phone_number\\\": \\\"123-456-789\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"tax_number\\\": null,\\n      \\\"website\\\": \\\"http://williamwonkacandyltd.com\\\",\\n      \\\"tags\\\": [\\n\\n],\\n      \\\"address_ids\\\": [\\n        4,\\n        5\\n      ],\\n      \\\"contact_ids\\\": [\\n        3,\\n        4,\\n        5\\n      ],\\n      \\\"note_ids\\\": [\\n\\n],\\n      \\\"default_price_type_id\\\": null\\n    }\\n  ]\\n}\\nReturns a list of companies you’ve previously created. The companies are returned in sorted order, with the most recent companies appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of company IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nPossible options are: active, disabled.\\n\\n\\nassignee_id\\nPossibe options: ID of any user\\n\\n\\ndefault_ledger_account_id\\n\\n\\n\\ndefault_payment_method_id\\n\\n\\n\\ndefault_payment_term_id\\n\\n\\n\\ndefault_stock_location_id\\n\\n\\n\\ndefault_tax_type_id\\n\\n\\n\\ncompany_code\\n\\n\\n\\ncompany_type\\nPossible options are: business, supplier, or consumer\\n\\n\\ndefault_price_list_id\\n\\n\\n\\ndefault_document_theme_id\\n\\n\\n\\nemail\\n\\n\\n\\ndefault_price_type_id\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/companies\"},{\"id\":\"create-a-new-company\",\"title\":\"Create a new company\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncompany = gecko.Company.build({\\n  name: \\\"TradeGecko (Demo)\\\",\\n  company_type: \\\"supplier\\\"\\n})\\ncompany.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/companies/ -d '{\\\"company\\\":{\\\"name\\\":\\\"TradeGecko (Demo)\\\",\\\"company_type\\\":\\\"supplier\\\"}}'\\n{\\n  \\\"company\\\": {\\n    \\\"id\\\": 4,\\n    \\\"created_at\\\": \\\"2015-11-02T01:44:42.417Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:44:42.417Z\\\",\\n    \\\"assignee_id\\\": 1,\\n    \\\"default_ledger_account_id\\\": null,\\n    \\\"default_payment_method_id\\\": null,\\n    \\\"default_payment_term_id\\\": null,\\n    \\\"default_stock_location_id\\\": null,\\n    \\\"default_tax_type_id\\\": null,\\n    \\\"company_code\\\": null,\\n    \\\"company_type\\\": \\\"business\\\",\\n    \\\"default_discount_rate\\\": null,\\n    \\\"default_price_list_id\\\": null,\\n    \\\"default_tax_rate\\\": null,\\n    \\\"default_document_theme_id\\\": null,\\n    \\\"description\\\": \\\"\\\",\\n    \\\"email\\\": null,\\n    \\\"fax\\\": null,\\n    \\\"name\\\": \\\"B2B Test Company\\\",\\n    \\\"phone_number\\\": null,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"tax_number\\\": null,\\n    \\\"website\\\": null,\\n    \\\"tags\\\": [\\n\\n],\\n    \\\"address_ids\\\": [\\n      6\\n    ],\\n    \\\"contact_ids\\\": [\\n      7\\n    ],\\n    \\\"note_ids\\\": [\\n\\n],\\n    \\\"default_price_type_id\\\": null\\n  }\\n}\\nCreates a new company object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nassignee_id\\nInteger\\nID of the user to which new PO/SO will be assigned by default\\n\\n\\n\\ndefault_ledger_account_id\\nInteger\\n\\n\\n\\n\\ndefault_payment_method_id\\nInteger\\n\\n\\n\\n\\ndefault_payment_term_id\\nInteger\\n\\n\\n\\n\\ndefault_stock_location_id\\nInteger\\n\\n\\n\\n\\ndefault_tax_type_id\\nInteger\\n\\n\\n\\n\\ncompany_code\\nString\\nA unique identifier for your records\\n\\n\\n\\ncompany_type\\nString\\nCan be 'business', 'supplier' or 'consumer'\\ntrue\\n\\n\\ndefault_discount_rate\\nString\\n\\n\\n\\n\\ndefault_price_list_id\\nString\\n\\n\\n\\n\\ndefault_tax_rate deprecated\\nString\\nAlias to default_tax_type#effective_rate\\n\\n\\n\\ndescription\\nString\\n\\n\\n\\n\\nemail\\nString\\n\\n\\n\\n\\nfax\\nString\\n\\n\\n\\n\\nname\\nString\\n\\ntrue\\n\\n\\nphone_number\\nString\\n\\n\\n\\n\\ntax_number\\nString\\n\\n\\n\\n\\nwebsite\\nString\\n\\n\\n\\n\\ntags\\nArray[String]\\nCompany tags for easier filtering and searching\\n\\n\\n\\ndefault_price_type_id deprecated\\nString\\nUse default_price_list_id instead\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/companies/\"},{\"id\":\"retrieve-a-particular-company\",\"title\":\"Retrieve a particular company\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Company.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/companies/1\\n{\\n  \\\"company\\\": {\\n    \\\"id\\\": 4,\\n    \\\"created_at\\\": \\\"2015-11-02T01:44:42.417Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:44:42.417Z\\\",\\n    \\\"assignee_id\\\": 1,\\n    \\\"default_ledger_account_id\\\": null,\\n    \\\"default_payment_method_id\\\": null,\\n    \\\"default_payment_term_id\\\": null,\\n    \\\"default_stock_location_id\\\": null,\\n    \\\"default_tax_type_id\\\": null,\\n    \\\"company_code\\\": null,\\n    \\\"company_type\\\": \\\"business\\\",\\n    \\\"default_discount_rate\\\": null,\\n    \\\"default_price_list_id\\\": null,\\n    \\\"default_tax_rate\\\": null,\\n    \\\"default_document_theme_id\\\": null,\\n    \\\"description\\\": \\\"\\\",\\n    \\\"email\\\": null,\\n    \\\"fax\\\": null,\\n    \\\"name\\\": \\\"B2B Test Company\\\",\\n    \\\"phone_number\\\": null,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"tax_number\\\": null,\\n    \\\"website\\\": null,\\n    \\\"tags\\\": [\\n\\n],\\n    \\\"address_ids\\\": [\\n      6\\n    ],\\n    \\\"contact_ids\\\": [\\n      7\\n    ],\\n    \\\"note_ids\\\": [\\n\\n],\\n    \\\"default_price_type_id\\\": null\\n  }\\n}\\nRetrieves the details of an existing company. You need only supply the unique company identifier that was returned upon company creation.HTTP RequestGET https://api.tradegecko.com/companies/{RESOURCE_ID}\"},{\"id\":\"update-a-company\",\"title\":\"Update a company\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncompany = gecko.Company.find(1)\\ncompany.attributes = {\\n  name: \\\"Elephant\\\",\\n  email: \\\"hello@tradegecko.com\\\",\\n  website: \\\"http://tradegecko.com\\\"\\n}\\ncompany.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/companies/1 -d '{\\\"company\\\":{\\\"name\\\":\\\"Elephant\\\",\\\"email\\\":\\\"hello@tradegecko.com\\\",\\\"website\\\":\\\"http://tradegecko.com\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the company gets updated successfully.\\n\\nUpdates the specified company by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the company creation call.HTTP RequestPUT https://api.tradegecko.com/companies/{RESOURCE_ID}\"},{\"id\":\"delete-a-company\",\"title\":\"Delete a company\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncompany = gecko.Company.find(1)\\ncompany.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/companies/1\\n\\nResponse\\n\\nReturns 204 status when the company gets deleted successfully.\\n\\nPermanently deletes a company. It cannot be undone.\\n  This company will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/companies/{RESOURCE_ID}/\"},{\"id\":\"composition\",\"title\":\"Composition\",\"body\":\"This is an object representing a composition.\"},{\"id\":\"the-composition-object\",\"title\":\"The Composition object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nbundle_id\\nInteger\\nThe ID corresponding to the bundle variant. (Must be composite: true)\\ntrue\\n\\n\\nbundle_sku\\nString\\nThe provided bundle variant's SKU.\\ntrue\\n\\n\\ncomponent_id\\nInteger\\nThe ID corresponding to this particular component variant of the bundle.\\ntrue\\n\\n\\ncomponent_sku\\nString\\nThe provided component variant's SKU.\\ntrue\\n\\n\\nquantity\\nString\\nThe quantity of this component variant required to make up the bundle.\\ntrue\\n\\n\"},{\"id\":\"list-all-composition\",\"title\":\"List all composition\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Composition.where({:sku=>[\\\"B-SKU-001\\\"]})\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/variants/composition/\\n{\\n  \\\"composition\\\": [\\n    {\\n      \\\"bundle_id\\\": 151235,\\n      \\\"bundle_sku\\\": \\\"B-SKU-001\\\",\\n      \\\"component_id\\\": 341234,\\n      \\\"component_sku\\\": \\\"SKU-002\\\",\\n      \\\"quantity\\\": \\\"20\\\"\\n    },\\n    {\\n      \\\"bundle_id\\\": 151235,\\n      \\\"bundle_sku\\\": \\\"B-SKU-001\\\",\\n      \\\"component_id\\\": 341235,\\n      \\\"component_sku\\\": \\\"SKU-003\\\",\\n      \\\"quantity\\\": \\\"10\\\"\\n    }\\n  ]\\n}\\nReturns a list of composition you’ve previously created. The composition are returned in sorted order, with the most recent composition appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn Array of Bundle IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\nbundle_sku\\nFilter by Bundle SKU via sku parameter\\n\\n\\ncomponent_id\\nAn Array of Component IDs\\n\\nHTTP Request:GET  https://api.tradegecko.com/variants/composition\"},{\"id\":\"retrieve-a-particular-composition\",\"title\":\"Retrieve a particular composition\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Composition.find(151235)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/variants/composition/151235\\n{\\n  \\\"composition\\\": {\\n    \\\"bundle_id\\\": 151235,\\n    \\\"bundle_sku\\\": \\\"B-SKU-001\\\",\\n    \\\"component_id\\\": 341234,\\n    \\\"component_sku\\\": \\\"SKU-002\\\",\\n    \\\"quantity\\\": \\\"20\\\"\\n  }\\n}\\nRetrieves the details of an existing composition. You need only supply the unique composition identifier that was returned upon composition creation.HTTP RequestGET https://api.tradegecko.com/variants/composition/{RESOURCE_ID}\"},{\"id\":\"contact\",\"title\":\"Contact\",\"body\":\"This is an object representing a contact of a company. Companies can\\n  have multiple contacts but a contact object belongs to only one\\n  Company.\"},{\"id\":\"the-contact-object\",\"title\":\"The Contact object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nDate and time when the contact was created.\\ntrue\\n\\n\\nupdated_at\\nString\\nDate and time when the contact was last updated.\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'.\\ntrue\\n\\n\\ncompany_id\\nInteger\\nThe company id where the contact belongs.\\n\\n\\n\\nemail\\nString\\nEmail address of the contact.\\n\\n\\n\\nfax\\nString\\nFax number of the contact.\\n\\n\\n\\nfirst_name\\nString\\nFirst name of the contact.\\n\\n\\n\\nlast_name\\nString\\nLast name of the contact.\\n\\n\\n\\nlocation\\nString\\nDepartment of the contact.\\n\\n\\n\\nmobile\\nString\\nMobile number of the contact.\\n\\n\\n\\nnotes\\nString\\nNotes on the contact.\\n\\n\\n\\nphone_number\\nString\\nPhone number of the contact.\\n\\n\\n\\nposition\\nString\\nJob title of the contact.\\n\\n\\n\\nonline_ordering\\nBoolean\\nTells whether this contact has access to your B2B store.\\n\\n\\n\\nphone  deprecated\\nString\\n\\n\\n\\n\"},{\"id\":\"list-all-contacts\",\"title\":\"List all contacts\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Contact.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/contacts/\\n{\\n  \\\"contacts\\\": [\\n    {\\n      \\\"id\\\": 7,\\n      \\\"created_at\\\": \\\"2015-11-02T01:44:42.483Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:45:17.085Z\\\",\\n      \\\"company_id\\\": 4,\\n      \\\"email\\\": \\\"lachlan@tradegecko.com\\\",\\n      \\\"fax\\\": null,\\n      \\\"first_name\\\": \\\"B2B Test Contact\\\",\\n      \\\"last_name\\\": \\\"\\\",\\n      \\\"location\\\": null,\\n      \\\"mobile\\\": null,\\n      \\\"notes\\\": null,\\n      \\\"phone_number\\\": null,\\n      \\\"position\\\": null,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"iguana_admin\\\": true,\\n      \\\"online_ordering\\\": true,\\n      \\\"invitation_accepted_at\\\": \\\"2015-11-02T01:45:17.082Z\\\",\\n      \\\"phone\\\": null\\n    },\\n    {\\n      \\\"id\\\": 6,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.821Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:33:35.379Z\\\",\\n      \\\"company_id\\\": 1,\\n      \\\"email\\\": \\\"lcp@tradegecko.com\\\",\\n      \\\"fax\\\": null,\\n      \\\"first_name\\\": \\\"lcp\\\",\\n      \\\"last_name\\\": \\\"Gecko\\\",\\n      \\\"location\\\": null,\\n      \\\"mobile\\\": null,\\n      \\\"notes\\\": null,\\n      \\\"phone_number\\\": null,\\n      \\\"position\\\": null,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"iguana_admin\\\": null,\\n      \\\"online_ordering\\\": true,\\n      \\\"invitation_accepted_at\\\": \\\"2015-11-02T01:33:35.377Z\\\",\\n      \\\"phone\\\": null\\n    }\\n  ]\\n}\\nReturns a list of contacts you’ve previously created. The contacts are returned in sorted order, with the most recent contacts appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of contact IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\n\\ncompany_id\\nFilter contacts by company\\n\\n\\nonline_ordering\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/contacts\"},{\"id\":\"create-a-new-contact\",\"title\":\"Create a new contact\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncontact = gecko.Contact.build({\\n  first_name: \\\"TradeGecko (Demo)\\\",\\n  company_id: 1\\n})\\ncontact.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/contacts/ -d '{\\\"contact\\\":{\\\"first_name\\\":\\\"TradeGecko (Demo)\\\",\\\"company_id\\\":1}}'\\n{\\n  \\\"contact\\\": {\\n    \\\"id\\\": 7,\\n    \\\"created_at\\\": \\\"2015-11-02T01:44:42.483Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:45:17.085Z\\\",\\n    \\\"company_id\\\": 4,\\n    \\\"email\\\": \\\"lachlan@tradegecko.com\\\",\\n    \\\"fax\\\": null,\\n    \\\"first_name\\\": \\\"B2B Test Contact\\\",\\n    \\\"last_name\\\": \\\"\\\",\\n    \\\"location\\\": null,\\n    \\\"mobile\\\": null,\\n    \\\"notes\\\": null,\\n    \\\"phone_number\\\": null,\\n    \\\"position\\\": null,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"iguana_admin\\\": true,\\n    \\\"online_ordering\\\": true,\\n    \\\"invitation_accepted_at\\\": \\\"2015-11-02T01:45:17.082Z\\\",\\n    \\\"phone\\\": null\\n  }\\n}\\nCreates a new contact object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ncompany_id\\nInteger\\nThe company id where the contact belongs.\\ntrue\\n\\n\\nemail\\nString\\nEmail address of the contact.\\n\\n\\n\\nfax\\nString\\nFax number of the contact.\\n\\n\\n\\nfirst_name\\nString\\nFirst name of the contact.\\ntrue\\n\\n\\nlast_name\\nString\\nLast name of the contact.\\n\\n\\n\\nlocation\\nString\\nDepartment of the contact.\\n\\n\\n\\nmobile\\nString\\nMobile number of the contact.\\n\\n\\n\\nnotes\\nString\\nNotes on the contact.\\n\\n\\n\\nphone_number\\nString\\nPhone number of the contact.\\n\\n\\n\\nposition\\nString\\nJob title of the contact.\\n\\n\\n\\nonline_ordering\\nBoolean\\nTells whether this contact has access to your B2B store.\\n\\n\\n\\nphone deprecated\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/contacts/\"},{\"id\":\"retrieve-a-particular-contact\",\"title\":\"Retrieve a particular contact\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Contact.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/contacts/1\\n{\\n  \\\"contact\\\": {\\n    \\\"id\\\": 7,\\n    \\\"created_at\\\": \\\"2015-11-02T01:44:42.483Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:45:17.085Z\\\",\\n    \\\"company_id\\\": 4,\\n    \\\"email\\\": \\\"lachlan@tradegecko.com\\\",\\n    \\\"fax\\\": null,\\n    \\\"first_name\\\": \\\"B2B Test Contact\\\",\\n    \\\"last_name\\\": \\\"\\\",\\n    \\\"location\\\": null,\\n    \\\"mobile\\\": null,\\n    \\\"notes\\\": null,\\n    \\\"phone_number\\\": null,\\n    \\\"position\\\": null,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"iguana_admin\\\": true,\\n    \\\"online_ordering\\\": true,\\n    \\\"invitation_accepted_at\\\": \\\"2015-11-02T01:45:17.082Z\\\",\\n    \\\"phone\\\": null\\n  }\\n}\\nRetrieves the details of an existing contact. You need only supply the unique contact identifier that was returned upon contact creation.HTTP RequestGET https://api.tradegecko.com/contacts/{RESOURCE_ID}\"},{\"id\":\"update-a-contact\",\"title\":\"Update a contact\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncontact = gecko.Contact.find(1)\\ncontact.attributes = {\\n  last_name: \\\"Rogers\\\"\\n}\\ncontact.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/contacts/1 -d '{\\\"contact\\\":{\\\"last_name\\\":\\\"Rogers\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the contact gets updated successfully.\\n\\nUpdates the specified contact by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the contact creation call.HTTP RequestPUT https://api.tradegecko.com/contacts/{RESOURCE_ID}\"},{\"id\":\"delete-a-contact\",\"title\":\"Delete a contact\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncontact = gecko.Contact.find(1)\\ncontact.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/contacts/1\\n\\nResponse\\n\\nReturns 204 status when the contact gets deleted successfully.\\n\\nPermanently deletes a contact. It cannot be undone.\\n  This contact will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/contacts/{RESOURCE_ID}/\"},{\"id\":\"currency\",\"title\":\"Currency\",\"body\":\"This is an object representing a currency.\"},{\"id\":\"the-currency-object\",\"title\":\"The Currency object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'\\ntrue\\n\\n\\ndelimiter\\nString\\n\\n\\n\\n\\nformat\\nString\\nUses %n (number) and %u (unit). e.g. (%u%n would appear as '$12')\\n\\n\\n\\niso\\nString\\nThree-character currency code\\n\\n\\n\\nname\\nString\\n\\n\\n\\n\\nprecision\\nString\\n\\n\\n\\n\\nrate\\nString\\nExchange rate based on account's base currency\\n\\n\\n\\nseparator\\nString\\n\\n\\n\\n\\nsymbol\\nString\\n\\n\\n\\n\"},{\"id\":\"list-all-currencies\",\"title\":\"List all currencies\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Currency.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/currencies/\\n{\\n  \\\"currencies\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n      \\\"delimiter\\\": \\\",\\\",\\n      \\\"format\\\": \\\"%u%n\\\",\\n      \\\"iso\\\": \\\"NZD\\\",\\n      \\\"name\\\": \\\"New Zealand Dollars\\\",\\n      \\\"precision\\\": 2,\\n      \\\"rate\\\": \\\"1.1\\\",\\n      \\\"separator\\\": \\\".\\\",\\n      \\\"symbol\\\": \\\"$\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"subunit\\\": 100\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n      \\\"delimiter\\\": \\\",\\\",\\n      \\\"format\\\": \\\"%u%n\\\",\\n      \\\"iso\\\": \\\"SGD\\\",\\n      \\\"name\\\": \\\"Singaporean Dollars\\\",\\n      \\\"precision\\\": 2,\\n      \\\"rate\\\": \\\"1.0\\\",\\n      \\\"separator\\\": \\\".\\\",\\n      \\\"symbol\\\": \\\"$\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"subunit\\\": 100\\n    }\\n  ]\\n}\\nReturns a list of currencies you’ve previously created. The currencies are returned in sorted order, with the most recent currencies appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of currency IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\nHTTP Request:GET  https://api.tradegecko.com/currencies\"},{\"id\":\"create-a-new-currency\",\"title\":\"Create a new currency\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncurrency = gecko.Currency.build({\\n  iso: \\\"USD\\\",\\n  precision: 4,\\n  format: \\\"%n%u\\\"\\n})\\ncurrency.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/currencies/ -d '{\\\"currency\\\":{\\\"iso\\\":\\\"USD\\\",\\\"precision\\\":4,\\\"format\\\":\\\"%n%u\\\"}}'\\n{\\n  \\\"currency\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n    \\\"delimiter\\\": \\\",\\\",\\n    \\\"format\\\": \\\"%u%n\\\",\\n    \\\"iso\\\": \\\"NZD\\\",\\n    \\\"name\\\": \\\"New Zealand Dollars\\\",\\n    \\\"precision\\\": 2,\\n    \\\"rate\\\": \\\"1.1\\\",\\n    \\\"separator\\\": \\\".\\\",\\n    \\\"symbol\\\": \\\"$\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"subunit\\\": 100\\n  }\\n}\\nCreates a new currency object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ndelimiter\\nString\\n\\n\\n\\n\\nformat\\nString\\nUses %n (number) and %u (unit). e.g. (%u%n would appear as '$12')\\n\\n\\n\\niso\\nString\\nThree-character currency code\\ntrue\\n\\n\\nname\\nString\\n\\n\\n\\n\\nprecision\\nString\\n\\n\\n\\n\\nrate\\nString\\nExchange rate based on account's base currency\\n\\n\\n\\nseparator\\nString\\n\\n\\n\\n\\nsymbol\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/currencies/\"},{\"id\":\"retrieve-a-particular-currency\",\"title\":\"Retrieve a particular currency\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Currency.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/currencies/1\\n{\\n  \\\"currency\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:23.947Z\\\",\\n    \\\"delimiter\\\": \\\",\\\",\\n    \\\"format\\\": \\\"%u%n\\\",\\n    \\\"iso\\\": \\\"NZD\\\",\\n    \\\"name\\\": \\\"New Zealand Dollars\\\",\\n    \\\"precision\\\": 2,\\n    \\\"rate\\\": \\\"1.1\\\",\\n    \\\"separator\\\": \\\".\\\",\\n    \\\"symbol\\\": \\\"$\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"subunit\\\": 100\\n  }\\n}\\nRetrieves the details of an existing currency. You need only supply the unique currency identifier that was returned upon currency creation.HTTP RequestGET https://api.tradegecko.com/currencies/{RESOURCE_ID}\"},{\"id\":\"update-a-currency\",\"title\":\"Update a currency\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncurrency = gecko.Currency.find(1)\\ncurrency.attributes = {\\n  separator: \\\".\\\"\\n}\\ncurrency.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/currencies/1 -d '{\\\"currency\\\":{\\\"separator\\\":\\\".\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the currency gets updated successfully.\\n\\nUpdates the specified currency by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the currency creation call.HTTP RequestPUT https://api.tradegecko.com/currencies/{RESOURCE_ID}\"},{\"id\":\"delete-a-currency\",\"title\":\"Delete a currency\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ncurrency = gecko.Currency.find(1)\\ncurrency.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/currencies/1\\n\\nResponse\\n\\nReturns 204 status when the currency gets deleted successfully.\\n\\nPermanently deletes a currency. It cannot be undone.\\n  This currency will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/currencies/{RESOURCE_ID}/\"},{\"id\":\"fulfillment\",\"title\":\"Fulfillment\",\"body\":\"This is an object representing a fulfillment.\"},{\"id\":\"the-fulfillment-object\",\"title\":\"The Fulfillment object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nDate and time when the fulfillment was created.\\ntrue\\n\\n\\nupdated_at\\nString\\nDate and time when the fulfillment was last updated.\\ntrue\\n\\n\\norder_id\\nInteger\\nThe order to which the fulfillment belongs.\\n\\n\\n\\nshipping_address_id\\nInteger\\nThe shipping address for the fulfillment.\\n\\n\\n\\nbilling_address_id\\nInteger\\nThe billing address for the fulfillment.\\n\\n\\n\\nstock_location_id\\nInteger\\nThe stock location where stock will be withdrawn from.\\n\\n\\n\\ndelivery_type\\nString\\nMode of delivery.\\n\\n\\n\\nexchange_rate\\nString\\nCurrency exchange_rate at time of creation.\\n\\n\\n\\nnotes\\nString\\nAdditional notes.\\n\\n\\n\\npacked_at\\nString\\nTimestamp when fulfillment is packed.\\n\\n\\n\\nreceived_at\\nString\\nTimestamp when fulfillment is received.\\n\\n\\n\\nservice\\nString\\nDictates the service where this fulfillment was handled.\\n\\n\\n\\nshipped_at\\nString\\nTimestamp when fulfillment is shipped.\\n\\n\\n\\nstatus\\nString\\nOne of packed or fulfilled. Will update to deleted or void if deleted, respectively.\\n\\n\\n\\ntracking_company\\nString\\nService that is providing fulfillment.\\n\\n\\n\\ntracking_number\\nString\\nTracking number provided by tracking company.\\n\\n\\n\\ntracking_url\\nString\\nLink to tracking info.\\n\\n\\n\\norder_number\\nString\\nOrder Number of associated order.\\ntrue\\n\\n\\ncompany_id\\nInteger\\nCompany of associated order.\\ntrue\\n\\n\\nfulfillment_line_item_ids\\nArray\\nAn array of IDs of the fulfillment's line items.\\ntrue\\n\\n\"},{\"id\":\"list-all-fulfillments\",\"title\":\"List all fulfillments\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Fulfillment.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillments/\\n{\\n  \\\"fulfillments\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.524Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.524Z\\\",\\n      \\\"order_id\\\": 2,\\n      \\\"shipping_address_id\\\": 1,\\n      \\\"billing_address_id\\\": 1,\\n      \\\"stock_location_id\\\": 1,\\n      \\\"delivery_type\\\": null,\\n      \\\"exchange_rate\\\": \\\"1.0\\\",\\n      \\\"notes\\\": null,\\n      \\\"packed_at\\\": \\\"2015-11-02\\\",\\n      \\\"receipt\\\": {\\n      },\\n      \\\"received_at\\\": \\\"2015-11-02T00:00:00.000Z\\\",\\n      \\\"service\\\": null,\\n      \\\"shipped_at\\\": \\\"2015-11-02T00:00:00.000Z\\\",\\n      \\\"status\\\": \\\"packed\\\",\\n      \\\"tracking_company\\\": null,\\n      \\\"tracking_number\\\": null,\\n      \\\"tracking_url\\\": null,\\n      \\\"order_number\\\": \\\"SO0002\\\",\\n      \\\"company_id\\\": 1,\\n      \\\"fulfillment_line_item_ids\\\": [\\n        3,\\n        2,\\n        1\\n      ]\\n    }\\n  ]\\n}\\nReturns a list of fulfillments you’ve previously created. The fulfillments are returned in sorted order, with the most recent fulfillments appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of fulfillment IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\norder_id\\n\\n\\n\\nshipping_address_id\\n\\n\\n\\nbilling_address_id\\n\\n\\n\\nstock_location_id\\n\\n\\n\\nreceipt\\nUsed by Shopify\\n\\n\\nstatus\\nPossible options: packed, or fulfilled, void, deleted\\n\\n\\ncompany_id\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/fulfillments\"},{\"id\":\"create-a-new-fulfillment\",\"title\":\"Create a new fulfillment\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment = gecko.Fulfillment.build({\\n  order_id: 1,\\n  packed_at: \\\"2015-11-02T01:22:25.524Z\\\",\\n  billing_address_id: 1,\\n  shipping_address_id: 1,\\n  fulfillment_line_items: [\\n    {\\n      order_line_item_id: 1,\\n      quantity: 1\\n    },\\n    {\\n      order_line_item_id: 2,\\n      quantity: 1\\n    }\\n  ]\\n})\\nfulfillment.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillments/ -d '{\\\"fulfillment\\\":{\\\"order_id\\\":1,\\\"packed_at\\\":\\\"2015-11-02T01:22:25.524Z\\\",\\\"billing_address_id\\\":1,\\\"shipping_address_id\\\":1,\\\"fulfillment_line_items\\\":[{\\\"order_line_item_id\\\":1,\\\"quantity\\\":1},{\\\"order_line_item_id\\\":2,\\\"quantity\\\":1}]}}'\\n{\\n  \\\"fulfillment\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.524Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.524Z\\\",\\n    \\\"order_id\\\": 2,\\n    \\\"shipping_address_id\\\": 1,\\n    \\\"billing_address_id\\\": 1,\\n    \\\"stock_location_id\\\": 1,\\n    \\\"delivery_type\\\": null,\\n    \\\"exchange_rate\\\": \\\"1.0\\\",\\n    \\\"notes\\\": null,\\n    \\\"packed_at\\\": \\\"2015-11-02\\\",\\n    \\\"receipt\\\": {\\n    },\\n    \\\"received_at\\\": \\\"2015-11-02T00:00:00.000Z\\\",\\n    \\\"service\\\": null,\\n    \\\"shipped_at\\\": \\\"2015-11-02T00:00:00.000Z\\\",\\n    \\\"status\\\": \\\"packed\\\",\\n    \\\"tracking_company\\\": null,\\n    \\\"tracking_number\\\": null,\\n    \\\"tracking_url\\\": null,\\n    \\\"order_number\\\": \\\"SO0002\\\",\\n    \\\"company_id\\\": 1,\\n    \\\"fulfillment_line_item_ids\\\": [\\n      3,\\n      2,\\n      1\\n    ]\\n  }\\n}\\nCreates a new fulfillment object.\\nThis endpoint also accepts embedded fulfillment_line_items.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\norder_id\\nInteger\\nThe order to which the fulfillment belongs.\\ntrue\\n\\n\\nshipping_address_id\\nInteger\\nThe shipping address for the fulfillment.\\n\\n\\n\\nbilling_address_id\\nInteger\\nThe billing address for the fulfillment.\\n\\n\\n\\nstock_location_id\\nInteger\\nThe stock location where stock will be withdrawn from.\\n\\n\\n\\ndelivery_type\\nString\\nMode of delivery.\\n\\n\\n\\nexchange_rate\\nString\\nCurrency exchange_rate at time of creation.\\n\\n\\n\\nnotes\\nString\\nAdditional notes.\\n\\n\\n\\npacked_at\\nString\\nTimestamp when fulfillment is packed.\\n\\n\\n\\nreceived_at\\nString\\nTimestamp when fulfillment is received.\\n\\n\\n\\nservice\\nString\\nDictates the service where this fulfillment was handled.\\n\\n\\n\\nshipped_at\\nString\\nTimestamp when fulfillment is shipped.\\n\\n\\n\\nstatus\\nString\\nOne of packed or fulfilled. Will update to deleted or void if deleted, respectively.\\n\\n\\n\\ntracking_company\\nString\\nService that is providing fulfillment.\\n\\n\\n\\ntracking_number\\nString\\nTracking number provided by tracking company.\\n\\n\\n\\ntracking_url\\nString\\nLink to tracking info.\\n\\n\\nFulfillmentLineItem\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nfulfillment_id\\nInteger\\nThe fulfillment to which the fulfillment_line_item belongs.\\ntrue\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the fulfillment_line_item belongs.\\ntrue\\n\\n\\nbase_price\\nString\\nSales value of the variant in base currency at fulfillment shipped_at date.\\n\\n\\n\\nposition\\nInteger\\nDisplay order.\\n\\n\\n\\nquantity\\nString\\nQuantity of the variant fulfilled.\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/fulfillments/\"},{\"id\":\"retrieve-a-particular-fulfillment\",\"title\":\"Retrieve a particular fulfillment\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Fulfillment.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillments/1\\n{\\n  \\\"fulfillment\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.524Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.524Z\\\",\\n    \\\"order_id\\\": 2,\\n    \\\"shipping_address_id\\\": 1,\\n    \\\"billing_address_id\\\": 1,\\n    \\\"stock_location_id\\\": 1,\\n    \\\"delivery_type\\\": null,\\n    \\\"exchange_rate\\\": \\\"1.0\\\",\\n    \\\"notes\\\": null,\\n    \\\"packed_at\\\": \\\"2015-11-02\\\",\\n    \\\"receipt\\\": {\\n    },\\n    \\\"received_at\\\": \\\"2015-11-02T00:00:00.000Z\\\",\\n    \\\"service\\\": null,\\n    \\\"shipped_at\\\": \\\"2015-11-02T00:00:00.000Z\\\",\\n    \\\"status\\\": \\\"packed\\\",\\n    \\\"tracking_company\\\": null,\\n    \\\"tracking_number\\\": null,\\n    \\\"tracking_url\\\": null,\\n    \\\"order_number\\\": \\\"SO0002\\\",\\n    \\\"company_id\\\": 1,\\n    \\\"fulfillment_line_item_ids\\\": [\\n      3,\\n      2,\\n      1\\n    ]\\n  }\\n}\\nRetrieves the details of an existing fulfillment. You need only supply the unique fulfillment identifier that was returned upon fulfillment creation.HTTP RequestGET https://api.tradegecko.com/fulfillments/{RESOURCE_ID}\"},{\"id\":\"update-a-fulfillment\",\"title\":\"Update a fulfillment\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment = gecko.Fulfillment.find(1)\\nfulfillment.attributes = {\\n  tracking_company: \\\"GeckoShip\\\",\\n  tracking_number: \\\"123TrackMe\\\"\\n}\\nfulfillment.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillments/1 -d '{\\\"fulfillment\\\":{\\\"tracking_company\\\":\\\"GeckoShip\\\",\\\"tracking_number\\\":\\\"123TrackMe\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the fulfillment gets updated successfully.\\n\\nUpdates the specified fulfillment by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the fulfillment creation call.HTTP RequestPUT https://api.tradegecko.com/fulfillments/{RESOURCE_ID}\"},{\"id\":\"delete-a-fulfillment\",\"title\":\"Delete a fulfillment\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment = gecko.Fulfillment.find(1)\\nfulfillment.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillments/1\\n\\nResponse\\n\\nReturns 204 status when the fulfillment gets deleted successfully.\\n\\nPermanently deletes a fulfillment. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/fulfillments/{RESOURCE_ID}/\"},{\"id\":\"fulfillmentlineitem\",\"title\":\"FulfillmentLineItem\",\"body\":\"This is an object representing a fulfillment_line_item of a fulfillment. Fulfillments can\\n  have multiple fulfillment_line_items but a fulfillment_line_item object belongs to only one\\n  Fulfillment.\"},{\"id\":\"the-fulfillmentlineitem-object\",\"title\":\"The FulfillmentLineItem object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nfulfillment_id\\nInteger\\nThe fulfillment to which the fulfillment_line_item belongs.\\n\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the fulfillment_line_item belongs.\\n\\n\\n\\nbase_price\\nString\\nSales value of the variant in base currency at fulfillment shipped_at date.\\ntrue\\n\\n\\nposition\\nInteger\\nDisplay order.\\n\\n\\n\\nquantity\\nString\\nQuantity of the variant fulfilled.\\n\\n\\n\\nvariant_id\\nString\\nThe order_line_item's variant.\\ntrue\\n\\n\\nvariant_sku\\nString\\nThe sku of the order_line_item's variant.\\ntrue\\n\\n\"},{\"id\":\"list-all-fulfillment_line_items\",\"title\":\"List all fulfillment_line_items\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.FulfillmentLineItem.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_line_items/\\n{\\n  \\\"fulfillment_line_items\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n      \\\"fulfillment_id\\\": 1,\\n      \\\"order_line_item_id\\\": 4,\\n      \\\"base_price\\\": null,\\n      \\\"position\\\": 1,\\n      \\\"quantity\\\": \\\"1.0\\\",\\n      \\\"variant_id\\\": 1,\\n      \\\"variant_sku\\\": \\\"SKU1\\\"\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.533Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.533Z\\\",\\n      \\\"fulfillment_id\\\": 1,\\n      \\\"order_line_item_id\\\": 5,\\n      \\\"base_price\\\": null,\\n      \\\"position\\\": 2,\\n      \\\"quantity\\\": \\\"2.0\\\",\\n      \\\"variant_id\\\": 2,\\n      \\\"variant_sku\\\": \\\"SKU2\\\"\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.531Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.531Z\\\",\\n      \\\"fulfillment_id\\\": 1,\\n      \\\"order_line_item_id\\\": 6,\\n      \\\"base_price\\\": null,\\n      \\\"position\\\": 3,\\n      \\\"quantity\\\": \\\"2.0\\\",\\n      \\\"variant_id\\\": 3,\\n      \\\"variant_sku\\\": \\\"SKU3\\\"\\n    }\\n  ]\\n}\\nReturns a list of fulfillment_line_items you’ve previously created. The fulfillment_line_items are returned in sorted order, with the most recent fulfillment_line_items appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of fulfillment_line_item IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nfulfillment_id\\nFilter fulfillment_line_items by fulfillment\\n\\n\\norder_line_item_id\\nFilter fulfillment_line_items by order_line_item\\n\\n\\nbase_price\\n\\n\\n\\nposition\\n\\n\\n\\nquantity\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/fulfillment_line_items\"},{\"id\":\"create-a-new-fulfillment_line_item\",\"title\":\"Create a new fulfillment_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_line_item = gecko.FulfillmentLineItem.build({\\n  fulfillment_id: 1,\\n  order_line_item_id: 1,\\n  quantity: \\\"10.0\\\",\\n  position: 1\\n})\\nfulfillment_line_item.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_line_items/ -d '{\\\"fulfillment_line_item\\\":{\\\"fulfillment_id\\\":1,\\\"order_line_item_id\\\":1,\\\"quantity\\\":\\\"10.0\\\",\\\"position\\\":1}}'\\n{\\n  \\\"fulfillment_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"fulfillment_id\\\": 1,\\n    \\\"order_line_item_id\\\": 4,\\n    \\\"base_price\\\": null,\\n    \\\"position\\\": 1,\\n    \\\"quantity\\\": \\\"1.0\\\",\\n    \\\"variant_id\\\": 1,\\n    \\\"variant_sku\\\": \\\"SKU1\\\"\\n  }\\n}\\nCreates a new fulfillment_line_item object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nfulfillment_id\\nInteger\\nThe fulfillment to which the fulfillment_line_item belongs.\\ntrue\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the fulfillment_line_item belongs.\\ntrue\\n\\n\\nbase_price\\nString\\nSales value of the variant in base currency at fulfillment shipped_at date.\\n\\n\\n\\nposition\\nInteger\\nDisplay order.\\n\\n\\n\\nquantity\\nString\\nQuantity of the variant fulfilled.\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/fulfillment_line_items/\"},{\"id\":\"retrieve-a-particular-fulfillment_line_item\",\"title\":\"Retrieve a particular fulfillment_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.FulfillmentLineItem.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_line_items/1\\n{\\n  \\\"fulfillment_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"fulfillment_id\\\": 1,\\n    \\\"order_line_item_id\\\": 4,\\n    \\\"base_price\\\": null,\\n    \\\"position\\\": 1,\\n    \\\"quantity\\\": \\\"1.0\\\",\\n    \\\"variant_id\\\": 1,\\n    \\\"variant_sku\\\": \\\"SKU1\\\"\\n  }\\n}\\nRetrieves the details of an existing fulfillment_line_item. You need only supply the unique fulfillment_line_item identifier that was returned upon fulfillment_line_item creation.HTTP RequestGET https://api.tradegecko.com/fulfillment_line_items/{RESOURCE_ID}\"},{\"id\":\"update-a-fulfillment_line_item\",\"title\":\"Update a fulfillment_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_line_item = gecko.FulfillmentLineItem.find(1)\\nfulfillment_line_item.attributes = {\\n  quantity: \\\"22.0\\\"\\n}\\nfulfillment_line_item.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_line_items/1 -d '{\\\"fulfillment_line_item\\\":{\\\"quantity\\\":\\\"22.0\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the fulfillment_line_item gets updated successfully.\\n\\nUpdates the specified fulfillment_line_item by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the fulfillment_line_item creation call.HTTP RequestPUT https://api.tradegecko.com/fulfillment_line_items/{RESOURCE_ID}\"},{\"id\":\"delete-a-fulfillment_line_item\",\"title\":\"Delete a fulfillment_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_line_item = gecko.FulfillmentLineItem.find(1)\\nfulfillment_line_item.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_line_items/1\\n\\nResponse\\n\\nReturns 204 status when the fulfillment_line_item gets deleted successfully.\\n\\nPermanently deletes a fulfillment_line_item. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/fulfillment_line_items/{RESOURCE_ID}/\"},{\"id\":\"fulfillmentreturn\",\"title\":\"FulfillmentReturn\",\"body\":\"This is an object representing a fulfillment_return of an order. Orders can\\n  have multiple fulfillment_returns but a fulfillment_return object belongs to only one\\n  Order.\"},{\"id\":\"the-fulfillmentreturn-object\",\"title\":\"The FulfillmentReturn object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nDate and time when the fulfillment_return was created.\\ntrue\\n\\n\\nupdated_at\\nString\\nDate and time when the fulfillment_return was last updated.\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'returning', 'received', 'void' or 'deleted'\\n\\n\\n\\norder_id\\nInteger\\nThe order to which the fulfillment_return belongs.\\n\\n\\n\\nlocation_id\\nInteger\\nThe location to which the fulfillment_return belongs.\\n\\n\\n\\ntracking_number\\nString\\nTracking number of fulfillment_return.\\n\\n\\n\\ntracking_url\\nString\\nTracking url of fulfillment_return.\\n\\n\\n\\ntracking_company\\nString\\nTracking company used for fulfillment_return.\\n\\n\\n\\ndelivery_type\\nString\\nMode of delivery.\\n\\n\\n\\nnotes\\nString\\nAdditional notes.\\n\\n\\n\\nexchange_rate\\nString\\nCurrency exchange_rate at time of creation.\\n\\n\\n\\nreceived_at\\nString\\nTimestamp when fulfillment_return is received.\\n\\n\\n\\ncredit_note_number\\nString\\nAfter a fulfillment return is created, a credit note with this number is created for accounting purposes.\\n\\n\\n\\ncompany_id\\nInteger\\nCompany of associated order.\\ntrue\\n\\n\"},{\"id\":\"list-all-fulfillment_returns\",\"title\":\"List all fulfillment_returns\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.FulfillmentReturn.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_returns/\\n{\\n  \\\"fulfillment_returns\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n      \\\"order_id\\\": 1,\\n      \\\"location_id\\\": 1,\\n      \\\"delivery_type\\\": null,\\n      \\\"exchange_rate\\\": \\\"1.0\\\",\\n      \\\"notes\\\": null,\\n      \\\"received_at\\\": null,\\n      \\\"tracking_company\\\": null,\\n      \\\"tracking_number\\\": null,\\n      \\\"tracking_url\\\": null,\\n      \\\"status\\\": \\\"returning\\\",\\n      \\\"credit_note_number\\\": \\\"CN0001\\\",\\n      \\\"order_number\\\": \\\"SO0001\\\",\\n      \\\"company_id\\\": 1\\n    }\\n  ]\\n}\\nReturns a list of fulfillment_returns you’ve previously created. The fulfillment_returns are returned in sorted order, with the most recent fulfillment_returns appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of fulfillment_return IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\n\\norder_id\\n\\n\\n\\nlocation_id\\n\\n\\n\\ncompany_id\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/fulfillment_returns\"},{\"id\":\"create-a-new-fulfillment_return\",\"title\":\"Create a new fulfillment_return\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_return = gecko.FulfillmentReturn.build({\\n  order_id: 1,\\n  fulfillment_return_line_items: [\\n    {\\n      order_line_item_id: 1,\\n      quantity: 1\\n    },\\n    {\\n      order_line_item_id: 2,\\n      quantity: 1\\n    }\\n  ]\\n})\\nfulfillment_return.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_returns/ -d '{\\\"fulfillment_return\\\":{\\\"order_id\\\":1,\\\"fulfillment_return_line_items\\\":[{\\\"order_line_item_id\\\":1,\\\"quantity\\\":1},{\\\"order_line_item_id\\\":2,\\\"quantity\\\":1}]}}'\\n{\\n  \\\"fulfillment_return\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"order_id\\\": 1,\\n    \\\"location_id\\\": 1,\\n    \\\"delivery_type\\\": null,\\n    \\\"exchange_rate\\\": \\\"1.0\\\",\\n    \\\"notes\\\": null,\\n    \\\"received_at\\\": null,\\n    \\\"tracking_company\\\": null,\\n    \\\"tracking_number\\\": null,\\n    \\\"tracking_url\\\": null,\\n    \\\"status\\\": \\\"returning\\\",\\n    \\\"credit_note_number\\\": \\\"CN0001\\\",\\n    \\\"order_number\\\": \\\"SO0001\\\",\\n    \\\"company_id\\\": 1\\n  }\\n}\\nCreates a new fulfillment_return object.\\nThis endpoint also accepts embedded fulfillment_return_line_items.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\norder_id\\nInteger\\nThe order to which the fulfillment_return belongs.\\ntrue\\n\\n\\nlocation_id\\nInteger\\nThe location to which the fulfillment_return belongs.\\n\\n\\n\\ntracking_number\\nString\\nTracking number of fulfillment_return.\\n\\n\\n\\ntracking_url\\nString\\nTracking url of fulfillment_return.\\n\\n\\n\\ntracking_company\\nString\\nTracking company used for fulfillment_return.\\n\\n\\n\\ndelivery_type\\nString\\nMode of delivery.\\n\\n\\n\\nnotes\\nString\\nAdditional notes.\\n\\n\\n\\nexchange_rate\\nString\\nCurrency exchange_rate at time of creation.\\n\\n\\n\\nreceived_at\\nString\\nTimestamp when fulfillment_return is received.\\n\\n\\n\\ncredit_note_number\\nString\\nAfter a fulfillment return is created, a credit note with this number is created for accounting purposes.\\n\\n\\nFulfillmentReturnLineItem\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nfulfillment_return_id\\nInteger\\nThe fulfillment_return to which the fulfillment_return_line_item belongs.\\ntrue\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the fulfillment_return_line_item belongs.\\ntrue\\n\\n\\nbase_price\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nquantity\\nString\\n\\ntrue\\n\\n\\nledger_account_id\\nInteger\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/fulfillment_returns/\"},{\"id\":\"retrieve-a-particular-fulfillment_return\",\"title\":\"Retrieve a particular fulfillment_return\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.FulfillmentReturn.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_returns/1\\n{\\n  \\\"fulfillment_return\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"order_id\\\": 1,\\n    \\\"location_id\\\": 1,\\n    \\\"delivery_type\\\": null,\\n    \\\"exchange_rate\\\": \\\"1.0\\\",\\n    \\\"notes\\\": null,\\n    \\\"received_at\\\": null,\\n    \\\"tracking_company\\\": null,\\n    \\\"tracking_number\\\": null,\\n    \\\"tracking_url\\\": null,\\n    \\\"status\\\": \\\"returning\\\",\\n    \\\"credit_note_number\\\": \\\"CN0001\\\",\\n    \\\"order_number\\\": \\\"SO0001\\\",\\n    \\\"company_id\\\": 1\\n  }\\n}\\nRetrieves the details of an existing fulfillment_return. You need only supply the unique fulfillment_return identifier that was returned upon fulfillment_return creation.HTTP RequestGET https://api.tradegecko.com/fulfillment_returns/{RESOURCE_ID}\"},{\"id\":\"update-a-fulfillment_return\",\"title\":\"Update a fulfillment_return\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_return = gecko.FulfillmentReturn.find(1)\\nfulfillment_return.attributes = {\\n  location_id: 2\\n}\\nfulfillment_return.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_returns/1 -d '{\\\"fulfillment_return\\\":{\\\"location_id\\\":2}}'\\n\\nResponse\\n\\nReturns 204 status when the fulfillment_return gets updated successfully.\\n\\nUpdates the specified fulfillment_return by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the fulfillment_return creation call.HTTP RequestPUT https://api.tradegecko.com/fulfillment_returns/{RESOURCE_ID}\"},{\"id\":\"delete-a-fulfillment_return\",\"title\":\"Delete a fulfillment_return\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_return = gecko.FulfillmentReturn.find(1)\\nfulfillment_return.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_returns/1\\n\\nResponse\\n\\nReturns 204 status when the fulfillment_return gets deleted successfully.\\n\\nPermanently deletes a fulfillment_return. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/fulfillment_returns/{RESOURCE_ID}/\"},{\"id\":\"fulfillmentreturnlineitem\",\"title\":\"FulfillmentReturnLineItem\",\"body\":\"This is an object representing a fulfillment_return_line_item of a fulfillment_return. Fulfillment_returns can\\n  have multiple fulfillment_return_line_items but a fulfillment_return_line_item object belongs to only one\\n  Fulfillment_return.\"},{\"id\":\"the-fulfillmentreturnlineitem-object\",\"title\":\"The FulfillmentReturnLineItem object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nDate and time when the fulfillment_return_line_item was created.\\ntrue\\n\\n\\nupdated_at\\nString\\nDate and time when the fulfillment_return_line_item was created.\\ntrue\\n\\n\\nfulfillment_return_id\\nInteger\\nThe fulfillment_return to which the fulfillment_return_line_item belongs.\\n\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the fulfillment_return_line_item belongs.\\n\\n\\n\\nbase_price\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\nledger_account_id\\nInteger\\n\\n\\n\\n\"},{\"id\":\"list-all-fulfillment_return_line_items\",\"title\":\"List all fulfillment_return_line_items\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.FulfillmentReturnLineItem.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_return_line_items/\\n{\\n  \\\"fulfillment_return_line_items\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n      \\\"fulfillment_return_id\\\": 1,\\n      \\\"order_line_item_id\\\": 1,\\n      \\\"base_price\\\": null,\\n      \\\"position\\\": 0,\\n      \\\"quantity\\\": \\\"1.0\\\",\\n      \\\"ledger_account_id\\\": null,\\n      \\\"stock_trail_ids\\\": [\\n\\n]\\n    }\\n  ]\\n}\\nReturns a list of fulfillment_return_line_items you’ve previously created. The fulfillment_return_line_items are returned in sorted order, with the most recent fulfillment_return_line_items appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of fulfillment_return_line_item IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nfulfillment_return_id\\nFilter fulfillment_return_line_items by fulfillment_return\\n\\n\\norder_line_item_id\\nFilter fulfillment_return_line_items by order_line_item\\n\\n\\nledger_account_id\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/fulfillment_return_line_items\"},{\"id\":\"create-a-new-fulfillment_return_line_item\",\"title\":\"Create a new fulfillment_return_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_return_line_item = gecko.FulfillmentReturnLineItem.build({\\n  fulfillment_return_id: 1,\\n  order_line_item_id: 1,\\n  quantity: \\\"10.0\\\"\\n})\\nfulfillment_return_line_item.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_return_line_items/ -d '{\\\"fulfillment_return_line_item\\\":{\\\"fulfillment_return_id\\\":1,\\\"order_line_item_id\\\":1,\\\"quantity\\\":\\\"10.0\\\"}}'\\n{\\n  \\\"fulfillment_return_line_item\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"fulfillment_return_id\\\": 1,\\n    \\\"order_line_item_id\\\": 1,\\n    \\\"base_price\\\": null,\\n    \\\"position\\\": 0,\\n    \\\"quantity\\\": \\\"1.0\\\",\\n    \\\"ledger_account_id\\\": null,\\n    \\\"stock_trail_ids\\\": [\\n\\n]\\n  }\\n}\\nCreates a new fulfillment_return_line_item object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nfulfillment_return_id\\nInteger\\nThe fulfillment_return to which the fulfillment_return_line_item belongs.\\ntrue\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the fulfillment_return_line_item belongs.\\ntrue\\n\\n\\nbase_price\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nquantity\\nString\\n\\ntrue\\n\\n\\nledger_account_id\\nInteger\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/fulfillment_return_line_items/\"},{\"id\":\"retrieve-a-particular-fulfillment_return_line_item\",\"title\":\"Retrieve a particular fulfillment_return_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.FulfillmentReturnLineItem.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_return_line_items/1\\n{\\n  \\\"fulfillment_return_line_item\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.535Z\\\",\\n    \\\"fulfillment_return_id\\\": 1,\\n    \\\"order_line_item_id\\\": 1,\\n    \\\"base_price\\\": null,\\n    \\\"position\\\": 0,\\n    \\\"quantity\\\": \\\"1.0\\\",\\n    \\\"ledger_account_id\\\": null,\\n    \\\"stock_trail_ids\\\": [\\n\\n]\\n  }\\n}\\nRetrieves the details of an existing fulfillment_return_line_item. You need only supply the unique fulfillment_return_line_item identifier that was returned upon fulfillment_return_line_item creation.HTTP RequestGET https://api.tradegecko.com/fulfillment_return_line_items/{RESOURCE_ID}\"},{\"id\":\"update-a-fulfillment_return_line_item\",\"title\":\"Update a fulfillment_return_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_return_line_item = gecko.FulfillmentReturnLineItem.find(1)\\nfulfillment_return_line_item.attributes = {\\n  quantity: \\\"22.0\\\"\\n}\\nfulfillment_return_line_item.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_return_line_items/1 -d '{\\\"fulfillment_return_line_item\\\":{\\\"quantity\\\":\\\"22.0\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the fulfillment_return_line_item gets updated successfully.\\n\\nUpdates the specified fulfillment_return_line_item by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the fulfillment_return_line_item creation call.HTTP RequestPUT https://api.tradegecko.com/fulfillment_return_line_items/{RESOURCE_ID}\"},{\"id\":\"delete-a-fulfillment_return_line_item\",\"title\":\"Delete a fulfillment_return_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nfulfillment_return_line_item = gecko.FulfillmentReturnLineItem.find(1)\\nfulfillment_return_line_item.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/fulfillment_return_line_items/1\\n\\nResponse\\n\\nReturns 204 status when the fulfillment_return_line_item gets deleted successfully.\\n\\nPermanently deletes a fulfillment_return_line_item. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/fulfillment_return_line_items/{RESOURCE_ID}/\"},{\"id\":\"image\",\"title\":\"Image\",\"body\":\"This is an object representing an image of a variant. Variants can\\n  have multiple images but an image object belongs to only one\\n  Variant.\"},{\"id\":\"the-image-object\",\"title\":\"The Image object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\nproduct_id\\nInteger\\nThe product to which the image belongs.\\n\\n\\n\\nvariant_id  deprecated\\nInteger\\nThe variant to which the image belongs.\\n\\n\\n\\nvariant_ids\\nArray\\nThe variants to which the image belongs.\\n\\n\\n\\nuploader_id\\nInteger\\nIdentifier of the creating user or Integration (e.g. 'Shopify')\\ntrue\\n\\n\\nname\\nString\\nName of the file if changed\\n\\n\\n\\nposition\\nInteger\\n\\ntrue\\n\\n\\nbase_path\\nString\\nBase URL where image has been uploaded\\ntrue\\n\\n\\nfile_name\\nString\\nParsed name of the file\\ntrue\\n\\n\\nversions\\nString\\nAn array of image sizes\\ntrue\\n\\n\\nimage_processing\\nString\\nTells whether image sizes have been generated\\ntrue\\n\\n\\nurl\\nString\\nURL of image for fetching\\n\\n\\n\"},{\"id\":\"list-all-images\",\"title\":\"List all images\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Image.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/images/\\n{\\n  \\\"images\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"product_id\\\": 1,\\n      \\\"variant_id\\\": 1,\\n      \\\"variant_ids\\\": [\\n        1,\\n        2\\n      ],\\n      \\\"uploader_id\\\": 1,\\n      \\\"name\\\": \\\"\\\",\\n      \\\"position\\\": 1,\\n      \\\"base_path\\\": \\\"https://tradegecko-development-images.s3.amazonaws.com/uploads/variant_image/image/2231\\\",\\n      \\\"file_name\\\": \\\"1xUh3yT8SN6SjK6l1WXw_photo_large.png\\\",\\n      \\\"versions\\\": [\\n        \\\"thumbnail\\\",\\n        \\\"medium\\\"\\n      ]\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"product_id\\\": 1,\\n      \\\"variant_id\\\": 1,\\n      \\\"variant_ids\\\": [\\n        1,\\n        2\\n      ],\\n      \\\"uploader_id\\\": 1,\\n      \\\"name\\\": null,\\n      \\\"position\\\": 1,\\n      \\\"base_path\\\": \\\"https://tradegecko-development-images.s3.amazonaws.com/uploads/variant_image/image/2229\\\",\\n      \\\"file_name\\\": \\\"shw005a_4.jpg\\\",\\n      \\\"versions\\\": [\\n        \\\"thumbnail\\\",\\n        \\\"medium\\\"\\n      ],\\n      \\\"image_processing\\\": true\\n    }\\n  ]\\n}\\nReturns a list of images you’ve previously created. The images are returned in sorted order, with the most recent images appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of image IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nproduct_id\\nFilter images by product\\n\\n\\nvariant_id\\nFilter images by variant\\n\\n\\nvariant_ids\\nFilter images by variant\\n\\n\\nuploader_id\\nFilter images by uploader\\n\\nHTTP Request:GET  https://api.tradegecko.com/images\"},{\"id\":\"create-a-new-image\",\"title\":\"Create a new image\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nimage = gecko.Image.build({\\n  product_id: 1,\\n  variant_ids: [\\n    1,\\n    2\\n  ],\\n  url: \\\"http://www.thisismyimage.com/image.png\\\"\\n})\\nimage.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/images/ -d '{\\\"image\\\":{\\\"product_id\\\":1,\\\"variant_ids\\\":[1,2],\\\"url\\\":\\\"http://www.thisismyimage.com/image.png\\\"}}'\\n{\\n  \\\"image\\\": {\\n    \\\"id\\\": 2,\\n    \\\"product_id\\\": 1,\\n    \\\"variant_id\\\": 1,\\n    \\\"variant_ids\\\": [\\n      1,\\n      2\\n    ],\\n    \\\"uploader_id\\\": 1,\\n    \\\"name\\\": \\\"\\\",\\n    \\\"position\\\": 1,\\n    \\\"base_path\\\": \\\"https://tradegecko-development-images.s3.amazonaws.com/uploads/variant_image/image/2231\\\",\\n    \\\"file_name\\\": \\\"1xUh3yT8SN6SjK6l1WXw_photo_large.png\\\",\\n    \\\"versions\\\": [\\n      \\\"thumbnail\\\",\\n      \\\"medium\\\"\\n    ]\\n  }\\n}\\nCreates a new image object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nproduct_id\\nInteger\\nThe product to which the image belongs.\\ntrue\\n\\n\\nvariant_id deprecated\\nInteger\\nThe variant to which the image belongs.\\n\\n\\n\\nvariant_ids\\nArray\\nThe variants to which the image belongs.\\ntrue\\n\\n\\nurl\\nString\\nURL of image for fetching\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/images/\"},{\"id\":\"retrieve-a-particular-image\",\"title\":\"Retrieve a particular image\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Image.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/images/1\\n{\\n  \\\"image\\\": {\\n    \\\"id\\\": 2,\\n    \\\"product_id\\\": 1,\\n    \\\"variant_id\\\": 1,\\n    \\\"variant_ids\\\": [\\n      1,\\n      2\\n    ],\\n    \\\"uploader_id\\\": 1,\\n    \\\"name\\\": \\\"\\\",\\n    \\\"position\\\": 1,\\n    \\\"base_path\\\": \\\"https://tradegecko-development-images.s3.amazonaws.com/uploads/variant_image/image/2231\\\",\\n    \\\"file_name\\\": \\\"1xUh3yT8SN6SjK6l1WXw_photo_large.png\\\",\\n    \\\"versions\\\": [\\n      \\\"thumbnail\\\",\\n      \\\"medium\\\"\\n    ]\\n  }\\n}\\nRetrieves the details of an existing image. You need only supply the unique image identifier that was returned upon image creation.HTTP RequestGET https://api.tradegecko.com/images/{RESOURCE_ID}\"},{\"id\":\"delete-an-image\",\"title\":\"Delete an image\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nimage = gecko.Image.find(1)\\nimage.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/images/1\\n\\nResponse\\n\\nReturns 204 status when the image gets deleted successfully.\\n\\nPermanently deletes an image. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/images/{RESOURCE_ID}/\"},{\"id\":\"invoice\",\"title\":\"Invoice\",\"body\":\"This is an object representing an invoice.\"},{\"id\":\"the-invoice-object\",\"title\":\"The Invoice object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\norder_id\\nInteger\\nThe order to which the invoice belongs.\\n\\n\\n\\nshipping_address_id\\nInteger\\nThe shipping address for the invoice.\\n\\n\\n\\nbilling_address_id\\nInteger\\nThe billing address for the invoice.\\n\\n\\n\\npayment_term_id\\nInteger\\n\\n\\n\\n\\ndue_at\\nString\\n\\n\\n\\n\\nexchange_rate\\nString\\n\\n\\n\\n\\ninvoice_number\\nString\\n\\n\\n\\n\\ninvoiced_at\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\ncached_total\\nString\\n\\ntrue\\n\\n\\npayment_status\\nString\\n\\ntrue\\n\\n\\norder_number\\nString\\n\\ntrue\\n\\n\\ncompany_id\\nInteger\\n\\ntrue\\n\\n\\ncurrency_id\\nInteger\\n\\ntrue\\n\\n\\ninvoice_line_item_ids\\nArray\\n\\ntrue\\n\\n\\npayment_ids\\nArray\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-invoices\",\"title\":\"List all invoices\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Invoice.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoices/\\n{\\n  \\\"invoices\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.408Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.408Z\\\",\\n      \\\"document_url\\\": \\\"http://localhost:3000/d/-34nGV_4zRUNysT7LE3mAaUN\\\",\\n      \\\"order_id\\\": 2,\\n      \\\"shipping_address_id\\\": 1,\\n      \\\"billing_address_id\\\": 1,\\n      \\\"payment_term_id\\\": null,\\n      \\\"due_at\\\": \\\"2015-11-02\\\",\\n      \\\"exchange_rate\\\": \\\"1.0\\\",\\n      \\\"invoice_number\\\": \\\"SO0002\\\",\\n      \\\"invoiced_at\\\": \\\"2015-11-02\\\",\\n      \\\"notes\\\": null,\\n      \\\"cached_total\\\": \\\"102.0\\\",\\n      \\\"payment_status\\\": \\\"unpaid\\\",\\n      \\\"order_number\\\": \\\"SO0002\\\",\\n      \\\"company_id\\\": 1,\\n      \\\"currency_id\\\": 1,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"invoice_line_item_ids\\\": [\\n        {\\n          \\\"quantity\\\": \\\"1.0\\\",\\n          \\\"order_line_item_id\\\": 123\\n        },\\n        {\\n          \\\"quantity\\\": \\\"1.0\\\",\\n          \\\"order_line_item_id\\\": 456\\n        }\\n      ],\\n      \\\"payment_ids\\\": [\\n\\n],\\n      \\\"refund_ids\\\": [\\n\\n]\\n    }\\n  ]\\n}\\nReturns a list of invoices you’ve previously created. The invoices are returned in sorted order, with the most recent invoices appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of invoice IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\norder_id\\n\\n\\n\\nshipping_address_id\\n\\n\\n\\nbilling_address_id\\n\\n\\n\\npayment_term_id\\n\\n\\n\\ninvoice_number\\n\\n\\n\\npayment_status\\n\\n\\n\\ncompany_id\\n\\n\\n\\ncurrency_id\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/invoices\"},{\"id\":\"create-a-new-invoice\",\"title\":\"Create a new invoice\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ninvoice = gecko.Invoice.build({\\n  order_id: 1,\\n  billing_address_id: 1,\\n  shipping_address_id: 1,\\n  invoice_line_items: [\\n    {\\n      quantity: \\\"1.0\\\",\\n      order_line_item_id: 123\\n    },\\n    {\\n      quantity: \\\"1.0\\\",\\n      order_line_item_id: 456\\n    }\\n  ]\\n})\\ninvoice.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoices/ -d '{\\\"invoice\\\":{\\\"order_id\\\":1,\\\"billing_address_id\\\":1,\\\"shipping_address_id\\\":1,\\\"invoice_line_items\\\":[{\\\"quantity\\\":\\\"1.0\\\",\\\"order_line_item_id\\\":123},{\\\"quantity\\\":\\\"1.0\\\",\\\"order_line_item_id\\\":456}]}}'\\n{\\n  \\\"invoice\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.408Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.408Z\\\",\\n    \\\"document_url\\\": \\\"http://localhost:3000/d/-34nGV_4zRUNysT7LE3mAaUN\\\",\\n    \\\"order_id\\\": 2,\\n    \\\"shipping_address_id\\\": 1,\\n    \\\"billing_address_id\\\": 1,\\n    \\\"payment_term_id\\\": null,\\n    \\\"due_at\\\": \\\"2015-11-02\\\",\\n    \\\"exchange_rate\\\": \\\"1.0\\\",\\n    \\\"invoice_number\\\": \\\"SO0002\\\",\\n    \\\"invoiced_at\\\": \\\"2015-11-02\\\",\\n    \\\"notes\\\": null,\\n    \\\"cached_total\\\": \\\"102.0\\\",\\n    \\\"payment_status\\\": \\\"unpaid\\\",\\n    \\\"order_number\\\": \\\"SO0002\\\",\\n    \\\"company_id\\\": 1,\\n    \\\"currency_id\\\": 1,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"invoice_line_item_ids\\\": [\\n      {\\n        \\\"quantity\\\": \\\"1.0\\\",\\n        \\\"order_line_item_id\\\": 123\\n      },\\n      {\\n        \\\"quantity\\\": \\\"1.0\\\",\\n        \\\"order_line_item_id\\\": 456\\n      }\\n    ],\\n    \\\"payment_ids\\\": [\\n\\n],\\n    \\\"refund_ids\\\": [\\n\\n]\\n  }\\n}\\nCreates a new invoice object.\\nThis endpoint also accepts embedded invoice_line_items.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\norder_id\\nInteger\\nThe order to which the invoice belongs.\\ntrue\\n\\n\\nshipping_address_id\\nInteger\\nThe shipping address for the invoice.\\n\\n\\n\\nbilling_address_id\\nInteger\\nThe billing address for the invoice.\\n\\n\\n\\npayment_term_id\\nInteger\\n\\n\\n\\n\\ndue_at\\nString\\n\\n\\n\\n\\nexchange_rate\\nString\\n\\n\\n\\n\\ninvoice_number\\nString\\n\\n\\n\\n\\ninvoiced_at\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\nInvoiceLineItem\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ninvoice_id\\nInteger\\nThe invoice to which the invoice_line_item belongs.\\ntrue\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the invoice_line_item belongs.\\ntrue\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nquantity\\nString\\n\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/invoices/\"},{\"id\":\"retrieve-a-particular-invoice\",\"title\":\"Retrieve a particular invoice\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Invoice.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoices/1\\n{\\n  \\\"invoice\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.408Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.408Z\\\",\\n    \\\"document_url\\\": \\\"http://localhost:3000/d/-34nGV_4zRUNysT7LE3mAaUN\\\",\\n    \\\"order_id\\\": 2,\\n    \\\"shipping_address_id\\\": 1,\\n    \\\"billing_address_id\\\": 1,\\n    \\\"payment_term_id\\\": null,\\n    \\\"due_at\\\": \\\"2015-11-02\\\",\\n    \\\"exchange_rate\\\": \\\"1.0\\\",\\n    \\\"invoice_number\\\": \\\"SO0002\\\",\\n    \\\"invoiced_at\\\": \\\"2015-11-02\\\",\\n    \\\"notes\\\": null,\\n    \\\"cached_total\\\": \\\"102.0\\\",\\n    \\\"payment_status\\\": \\\"unpaid\\\",\\n    \\\"order_number\\\": \\\"SO0002\\\",\\n    \\\"company_id\\\": 1,\\n    \\\"currency_id\\\": 1,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"invoice_line_item_ids\\\": [\\n      {\\n        \\\"quantity\\\": \\\"1.0\\\",\\n        \\\"order_line_item_id\\\": 123\\n      },\\n      {\\n        \\\"quantity\\\": \\\"1.0\\\",\\n        \\\"order_line_item_id\\\": 456\\n      }\\n    ],\\n    \\\"payment_ids\\\": [\\n\\n],\\n    \\\"refund_ids\\\": [\\n\\n]\\n  }\\n}\\nRetrieves the details of an existing invoice. You need only supply the unique invoice identifier that was returned upon invoice creation.HTTP RequestGET https://api.tradegecko.com/invoices/{RESOURCE_ID}\"},{\"id\":\"update-an-invoice\",\"title\":\"Update an invoice\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ninvoice = gecko.Invoice.find(1)\\ninvoice.attributes = {\\n  billing_address_id: 2,\\n  payment_term_id: 1\\n}\\ninvoice.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoices/1 -d '{\\\"invoice\\\":{\\\"billing_address_id\\\":2,\\\"payment_term_id\\\":1}}'\\n\\nResponse\\n\\nReturns 204 status when the invoice gets updated successfully.\\n\\nUpdates the specified invoice by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the invoice creation call.HTTP RequestPUT https://api.tradegecko.com/invoices/{RESOURCE_ID}\"},{\"id\":\"delete-an-invoice\",\"title\":\"Delete an invoice\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ninvoice = gecko.Invoice.find(1)\\ninvoice.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoices/1\\n\\nResponse\\n\\nReturns 204 status when the invoice gets deleted successfully.\\n\\nPermanently deletes an invoice. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/invoices/{RESOURCE_ID}/\"},{\"id\":\"invoicelineitem\",\"title\":\"InvoiceLineItem\",\"body\":\"This is an object representing an invoice_line_item of an invoice. Invoices can\\n  have multiple invoice_line_items but an invoice_line_item object belongs to only one\\n  Invoice.\"},{\"id\":\"the-invoicelineitem-object\",\"title\":\"The InvoiceLineItem object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\ninvoice_id\\nInteger\\nThe invoice to which the invoice_line_item belongs.\\n\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the invoice_line_item belongs.\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nquantity\\nString\\n\\n\\n\\n\"},{\"id\":\"list-all-invoice_line_items\",\"title\":\"List all invoice_line_items\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.InvoiceLineItem.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoice_line_items/\\n{\\n  \\\"invoice_line_items\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.427Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.427Z\\\",\\n      \\\"invoice_id\\\": 1,\\n      \\\"order_line_item_id\\\": 4,\\n      \\\"ledger_account_id\\\": null,\\n      \\\"position\\\": 1,\\n      \\\"quantity\\\": \\\"1.0\\\"\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.424Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.424Z\\\",\\n      \\\"invoice_id\\\": 1,\\n      \\\"order_line_item_id\\\": 5,\\n      \\\"ledger_account_id\\\": null,\\n      \\\"position\\\": 2,\\n      \\\"quantity\\\": \\\"2.0\\\"\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:25.420Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:25.420Z\\\",\\n      \\\"invoice_id\\\": 1,\\n      \\\"order_line_item_id\\\": 6,\\n      \\\"ledger_account_id\\\": null,\\n      \\\"position\\\": 3,\\n      \\\"quantity\\\": \\\"2.0\\\"\\n    }\\n  ]\\n}\\nReturns a list of invoice_line_items you’ve previously created. The invoice_line_items are returned in sorted order, with the most recent invoice_line_items appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of invoice_line_item IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ninvoice_id\\nFilter invoice_line_items by invoice\\n\\n\\norder_line_item_id\\nFilter invoice_line_items by order_line_item\\n\\n\\nbase_price\\nSales value of the variant in base currency at invoice shipped_at date\\n\\n\\nposition\\n\\n\\n\\nquantity\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/invoice_line_items\"},{\"id\":\"create-a-new-invoice_line_item\",\"title\":\"Create a new invoice_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ninvoice_line_item = gecko.InvoiceLineItem.build({\\n  invoice_id: 1,\\n  order_line_item_id: 1,\\n  quantity: \\\"10.0\\\",\\n  position: 1\\n})\\ninvoice_line_item.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoice_line_items/ -d '{\\\"invoice_line_item\\\":{\\\"invoice_id\\\":1,\\\"order_line_item_id\\\":1,\\\"quantity\\\":\\\"10.0\\\",\\\"position\\\":1}}'\\n{\\n  \\\"invoice_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.427Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.427Z\\\",\\n    \\\"invoice_id\\\": 1,\\n    \\\"order_line_item_id\\\": 4,\\n    \\\"ledger_account_id\\\": null,\\n    \\\"position\\\": 1,\\n    \\\"quantity\\\": \\\"1.0\\\"\\n  }\\n}\\nCreates a new invoice_line_item object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ninvoice_id\\nInteger\\nThe invoice to which the invoice_line_item belongs.\\ntrue\\n\\n\\norder_line_item_id\\nInteger\\nThe order_line_item to which the invoice_line_item belongs.\\ntrue\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nquantity\\nString\\n\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/invoice_line_items/\"},{\"id\":\"retrieve-a-particular-invoice_line_item\",\"title\":\"Retrieve a particular invoice_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.InvoiceLineItem.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoice_line_items/1\\n{\\n  \\\"invoice_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:25.427Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:25.427Z\\\",\\n    \\\"invoice_id\\\": 1,\\n    \\\"order_line_item_id\\\": 4,\\n    \\\"ledger_account_id\\\": null,\\n    \\\"position\\\": 1,\\n    \\\"quantity\\\": \\\"1.0\\\"\\n  }\\n}\\nRetrieves the details of an existing invoice_line_item. You need only supply the unique invoice_line_item identifier that was returned upon invoice_line_item creation.HTTP RequestGET https://api.tradegecko.com/invoice_line_items/{RESOURCE_ID}\"},{\"id\":\"update-an-invoice_line_item\",\"title\":\"Update an invoice_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ninvoice_line_item = gecko.InvoiceLineItem.find(1)\\ninvoice_line_item.attributes = {\\n  quantity: \\\"22.0\\\"\\n}\\ninvoice_line_item.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoice_line_items/1 -d '{\\\"invoice_line_item\\\":{\\\"quantity\\\":\\\"22.0\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the invoice_line_item gets updated successfully.\\n\\nUpdates the specified invoice_line_item by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the invoice_line_item creation call.HTTP RequestPUT https://api.tradegecko.com/invoice_line_items/{RESOURCE_ID}\"},{\"id\":\"delete-an-invoice_line_item\",\"title\":\"Delete an invoice_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ninvoice_line_item = gecko.InvoiceLineItem.find(1)\\ninvoice_line_item.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/invoice_line_items/1\\n\\nResponse\\n\\nReturns 204 status when the invoice_line_item gets deleted successfully.\\n\\nPermanently deletes an invoice_line_item. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/invoice_line_items/{RESOURCE_ID}/\"},{\"id\":\"location\",\"title\":\"Location\",\"body\":\"This is an object representing a location.\"},{\"id\":\"the-location-object\",\"title\":\"The Location object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'\\ntrue\\n\\n\\naddress1\\nString\\n\\n\\n\\n\\naddress2\\nString\\n\\n\\n\\n\\ncity\\nString\\n\\n\\n\\n\\ncountry\\nString\\nTwo letter country code (e.g. SG, US)\\n\\n\\n\\nholds_stock\\nString\\nTells whether location is a warehouse\\n\\n\\n\\nlabel\\nString\\nA unique name among 'active' locations\\n\\n\\n\\nstate\\nString\\n\\n\\n\\n\\nsuburb\\nString\\n\\n\\n\\n\\nzip_code\\nString\\n\\n\\n\\n\"},{\"id\":\"list-all-locations\",\"title\":\"List all locations\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Location.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/locations/\\n{\\n  \\\"locations\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n      \\\"address1\\\": null,\\n      \\\"address2\\\": null,\\n      \\\"city\\\": null,\\n      \\\"country\\\": \\\"NZ\\\",\\n      \\\"holds_stock\\\": true,\\n      \\\"label\\\": \\\"Secondary Location\\\",\\n      \\\"state\\\": null,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"suburb\\\": null,\\n      \\\"zip_code\\\": null\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n      \\\"address1\\\": null,\\n      \\\"address2\\\": null,\\n      \\\"city\\\": null,\\n      \\\"country\\\": \\\"NZ\\\",\\n      \\\"holds_stock\\\": true,\\n      \\\"label\\\": \\\"Primary Location\\\",\\n      \\\"state\\\": null,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"suburb\\\": null,\\n      \\\"zip_code\\\": null\\n    }\\n  ]\\n}\\nReturns a list of locations you’ve previously created. The locations are returned in sorted order, with the most recent locations appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of location IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\nHTTP Request:GET  https://api.tradegecko.com/locations\"},{\"id\":\"create-a-new-location\",\"title\":\"Create a new location\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nlocation = gecko.Location.build({\\n  label: \\\"Secondary office\\\",\\n  address1: \\\"887 Orchard Road\\\",\\n  country: \\\"SG\\\"\\n})\\nlocation.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/locations/ -d '{\\\"location\\\":{\\\"label\\\":\\\"Secondary office\\\",\\\"address1\\\":\\\"887 Orchard Road\\\",\\\"country\\\":\\\"SG\\\"}}'\\n{\\n  \\\"location\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n    \\\"address1\\\": null,\\n    \\\"address2\\\": null,\\n    \\\"city\\\": null,\\n    \\\"country\\\": \\\"NZ\\\",\\n    \\\"holds_stock\\\": true,\\n    \\\"label\\\": \\\"Secondary Location\\\",\\n    \\\"state\\\": null,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"suburb\\\": null,\\n    \\\"zip_code\\\": null\\n  }\\n}\\nCreates a new location object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\naddress1\\nString\\n\\ntrue\\n\\n\\naddress2\\nString\\n\\n\\n\\n\\ncity\\nString\\n\\n\\n\\n\\ncountry\\nString\\nTwo letter country code (e.g. SG, US)\\ntrue\\n\\n\\nholds_stock\\nString\\nTells whether location is a warehouse\\n\\n\\n\\nlabel\\nString\\nA unique name among 'active' locations\\ntrue\\n\\n\\nstate\\nString\\n\\n\\n\\n\\nsuburb\\nString\\n\\n\\n\\n\\nzip_code\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/locations/\"},{\"id\":\"retrieve-a-particular-location\",\"title\":\"Retrieve a particular location\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Location.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/locations/1\\n{\\n  \\\"location\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:24.335Z\\\",\\n    \\\"address1\\\": null,\\n    \\\"address2\\\": null,\\n    \\\"city\\\": null,\\n    \\\"country\\\": \\\"NZ\\\",\\n    \\\"holds_stock\\\": true,\\n    \\\"label\\\": \\\"Secondary Location\\\",\\n    \\\"state\\\": null,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"suburb\\\": null,\\n    \\\"zip_code\\\": null\\n  }\\n}\\nRetrieves the details of an existing location. You need only supply the unique location identifier that was returned upon location creation.HTTP RequestGET https://api.tradegecko.com/locations/{RESOURCE_ID}\"},{\"id\":\"update-a-location\",\"title\":\"Update a location\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nlocation = gecko.Location.find(1)\\nlocation.attributes = {\\n  address1: \\\"121 Telok Ayer Street\\\"\\n}\\nlocation.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/locations/1 -d '{\\\"location\\\":{\\\"address1\\\":\\\"121 Telok Ayer Street\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the location gets updated successfully.\\n\\nUpdates the specified location by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the location creation call.HTTP RequestPUT https://api.tradegecko.com/locations/{RESOURCE_ID}\"},{\"id\":\"delete-a-location\",\"title\":\"Delete a location\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nlocation = gecko.Location.find(1)\\nlocation.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/locations/1\\n\\nResponse\\n\\nReturns 204 status when the location gets deleted successfully.\\n\\nPermanently deletes a location. It cannot be undone.\\n  This location will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/locations/{RESOURCE_ID}/\"},{\"id\":\"note\",\"title\":\"Note\",\"body\":\"This is an object representing a note of a company. Companies can\\n  have multiple notes but a note object belongs to only one\\n  Company.\"},{\"id\":\"the-note-object\",\"title\":\"The Note object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\ncompany_id\\nInteger\\nThe company id where the address belongs.\\n\\n\\n\\nuser_id\\nInteger\\nThe user id of the author of the note.\\ntrue\\n\\n\\nbody\\nString\\n\\n\\n\\n\"},{\"id\":\"list-all-notes\",\"title\":\"List all notes\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Note.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/notes/\\n{\\n  \\\"notes\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2015-11-13T08:29:32.741Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-13T08:29:32.741Z\\\",\\n      \\\"company_id\\\": 4,\\n      \\\"user_id\\\": 1,\\n      \\\"body\\\": \\\"90% discount, right? They are the best.\\\"\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-13T08:29:23.837Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-13T08:29:23.837Z\\\",\\n      \\\"company_id\\\": 4,\\n      \\\"user_id\\\": 1,\\n      \\\"body\\\": \\\"Working with them has been a real pleasure.\\\"\\n    }\\n  ]\\n}\\nReturns a list of notes you’ve previously created. The notes are returned in sorted order, with the most recent notes appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of note IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncompany_id\\nFilter addresses by company\\n\\n\\nuser_id\\nFilter addresses by user\\n\\nHTTP Request:GET  https://api.tradegecko.com/notes\"},{\"id\":\"create-a-new-note\",\"title\":\"Create a new note\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nnote = gecko.Note.build({\\n  company_id: 1,\\n  body: \\\"These kittens are adorable.\\\"\\n})\\nnote.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/notes/ -d '{\\\"note\\\":{\\\"company_id\\\":1,\\\"body\\\":\\\"These kittens are adorable.\\\"}}'\\n{\\n  \\\"note\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-13T08:29:32.741Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-13T08:29:32.741Z\\\",\\n    \\\"company_id\\\": 4,\\n    \\\"user_id\\\": 1,\\n    \\\"body\\\": \\\"90% discount, right? They are the best.\\\"\\n  }\\n}\\nCreates a new note object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ncompany_id\\nInteger\\nThe company id where the address belongs.\\ntrue\\n\\n\\nbody\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/notes/\"},{\"id\":\"retrieve-a-particular-note\",\"title\":\"Retrieve a particular note\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Note.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/notes/1\\n{\\n  \\\"note\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-13T08:29:32.741Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-13T08:29:32.741Z\\\",\\n    \\\"company_id\\\": 4,\\n    \\\"user_id\\\": 1,\\n    \\\"body\\\": \\\"90% discount, right? They are the best.\\\"\\n  }\\n}\\nRetrieves the details of an existing note. You need only supply the unique note identifier that was returned upon note creation.HTTP RequestGET https://api.tradegecko.com/notes/{RESOURCE_ID}\"},{\"id\":\"update-a-note\",\"title\":\"Update a note\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nnote = gecko.Note.find(1)\\nnote.attributes = {\\n  body: \\\"Cupcakes are for champions\\\"\\n}\\nnote.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/notes/1 -d '{\\\"note\\\":{\\\"body\\\":\\\"Cupcakes are for champions\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the note gets updated successfully.\\n\\nUpdates the specified note by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the note creation call.HTTP RequestPUT https://api.tradegecko.com/notes/{RESOURCE_ID}\"},{\"id\":\"delete-a-note\",\"title\":\"Delete a note\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nnote = gecko.Note.find(1)\\nnote.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/notes/1\\n\\nResponse\\n\\nReturns 204 status when the note gets deleted successfully.\\n\\nPermanently deletes a note. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/notes/{RESOURCE_ID}/\"},{\"id\":\"order\",\"title\":\"Order\",\"body\":\"This is an object representing an order.\"},{\"id\":\"the-order-object\",\"title\":\"The Order object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nThe date and time (ISO8601 format) when the Order was created_at\\ntrue\\n\\n\\nupdated_at\\nString\\nThe date and time (ISO8601 format) when the Order was last updated\\ntrue\\n\\n\\nassignee_id\\nInteger\\nThe assignee to which the order belongs.\\n\\n\\n\\nissued_at\\nString\\nIssue date for the order\\n\\n\\n\\nship_at\\nString\\nShip date for the order.\\n\\n\\n\\nbilling_address_id\\nInteger\\n\\n\\n\\n\\ncompany_id\\nInteger\\n\\n\\n\\n\\ncontact_id\\nInteger\\n\\n\\n\\n\\ncurrency_id\\nInteger\\n\\n\\n\\n\\nshipping_address_id\\nInteger\\n\\n\\n\\n\\nstock_location_id\\nInteger\\n\\n\\n\\n\\nuser_id\\nInteger\\n\\ntrue\\n\\n\\nsource_id\\nString\\nInternal ID of the OAuth application that created the order (if not via web interface)\\ntrue\\n\\n\\ndefault_price_list_id\\nString\\n\\n\\n\\n\\ndocument_url\\nString\\nShareable URL for resource document\\ntrue\\n\\n\\nemail\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\norder_number\\nString\\n\\n\\n\\n\\nphone_number\\nString\\n\\n\\n\\n\\nreference_number\\nString\\nA reference for the order that isn't the order_number\\n\\n\\n\\nsource_url\\nString\\n\\n\\n\\n\\ntags\\nArray[String]\\nReference tags for the order, used in filtering.\\n\\n\\n\\ntax_treatment\\nString\\nOne of 'exclusive' or 'inclusive', if not provided defaults to account default.\\n\\n\\n\\ntotal\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nSignifies the current state of the order, can be set as 'draft', 'active' or 'finalized'\\n\\n\\n\\npayment_status\\nString\\n\\ntrue\\n\\n\\ninvoice_status\\nString\\n\\ntrue\\n\\n\\npacked_status\\nString\\n\\ntrue\\n\\n\\nfulfillment_status\\nString\\n\\ntrue\\n\\n\\nreturn_status\\nString\\n\\ntrue\\n\\n\\nreturning_status\\nString\\n\\ntrue\\n\\n\\nshippability_status\\nString\\n\\ntrue\\n\\n\\nbackordering_status\\nString\\n\\ntrue\\n\\n\\nfulfillment_ids\\nArray\\n\\ntrue\\n\\n\\ninvoice_ids\\nArray\\n\\ntrue\\n\\n\\nfulfillment_return_ids\\nArray\\n\\ntrue\\n\\n\\npayment_ids\\nArray\\n\\ntrue\\n\\n\\nrefund_ids\\nArray\\n\\ntrue\\n\\n\\ninvoices\\nArray\\n\\ntrue\\n\\n\\ninvoice_numbers\\nHash\\n\\ntrue\\n\\n\\norder_line_item_ids\\nArray\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-orders\",\"title\":\"List all orders\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Order.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/\\n{\\n  \\\"orders\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-12T08:06:01.561Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-12T08:06:01.561Z\\\",\\n      \\\"document_url\\\": \\\"https://go.tradegecko.com/d/not-a-real-token-2\\\",\\n      \\\"assignee_id\\\": null,\\n      \\\"billing_address_id\\\": 1,\\n      \\\"company_id\\\": 1,\\n      \\\"contact_id\\\": null,\\n      \\\"currency_id\\\": 1,\\n      \\\"shipping_address_id\\\": 1,\\n      \\\"stock_location_id\\\": 1,\\n      \\\"user_id\\\": 1,\\n      \\\"default_price_list_id\\\": \\\"retail\\\",\\n      \\\"email\\\": \\\"example@tradegecko.com\\\",\\n      \\\"fulfillment_status\\\": \\\"unshipped\\\",\\n      \\\"invoice_status\\\": \\\"uninvoiced\\\",\\n      \\\"issued_at\\\": \\\"2015-11-12\\\",\\n      \\\"notes\\\": null,\\n      \\\"order_number\\\": \\\"SO0001\\\",\\n      \\\"packed_status\\\": \\\"unpacked\\\",\\n      \\\"payment_status\\\": \\\"unpaid\\\",\\n      \\\"phone_number\\\": \\\"+1 650-468-2904\\\",\\n      \\\"reference_number\\\": null,\\n      \\\"return_status\\\": \\\"unreturned\\\",\\n      \\\"returning_status\\\": \\\"unreturning\\\",\\n      \\\"ship_at\\\": null,\\n      \\\"source_url\\\": null,\\n      \\\"status\\\": \\\"draft\\\",\\n      \\\"tax_label\\\": \\\"GST\\\",\\n      \\\"tax_override\\\": null,\\n      \\\"tax_treatment\\\": \\\"inclusive\\\",\\n      \\\"total\\\": 0,\\n      \\\"tags\\\": [\\n\\n],\\n      \\\"fulfillment_ids\\\": [\\n\\n],\\n      \\\"fulfillment_return_ids\\\": [\\n\\n],\\n      \\\"invoice_ids\\\": [\\n\\n],\\n      \\\"payment_ids\\\": [\\n\\n],\\n      \\\"refund_ids\\\": [\\n\\n],\\n      \\\"invoices\\\": [\\n\\n],\\n      \\\"cached_total\\\": 0,\\n      \\\"default_price_type_id\\\": \\\"wholesale\\\",\\n      \\\"source\\\": null,\\n      \\\"tax_type\\\": \\\"exclusive\\\",\\n      \\\"tracking_number\\\": null,\\n      \\\"url\\\": null,\\n      \\\"source_id\\\": null,\\n      \\\"invoice_numbers\\\": {\\n        \\\"1\\\": \\\"INV001\\\"\\n      },\\n      \\\"order_line_item_ids\\\": [\\n        1,\\n        2\\n      ]\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-12T08:06:00.561Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-12T08:06:00.561Z\\\",\\n      \\\"document_url\\\": \\\"https://go.tradegecko.com/d/not-a-real-token\\\",\\n      \\\"assignee_id\\\": null,\\n      \\\"billing_address_id\\\": 1,\\n      \\\"company_id\\\": 1,\\n      \\\"contact_id\\\": null,\\n      \\\"currency_id\\\": 1,\\n      \\\"shipping_address_id\\\": 1,\\n      \\\"stock_location_id\\\": 1,\\n      \\\"user_id\\\": 1,\\n      \\\"default_price_list_id\\\": \\\"wholesale\\\",\\n      \\\"email\\\": \\\"example@tradegecko.com\\\",\\n      \\\"fulfillment_status\\\": \\\"unshipped\\\",\\n      \\\"invoice_status\\\": \\\"uninvoiced\\\",\\n      \\\"issued_at\\\": \\\"2015-11-12\\\",\\n      \\\"notes\\\": null,\\n      \\\"order_number\\\": \\\"SO0001\\\",\\n      \\\"packed_status\\\": \\\"unpacked\\\",\\n      \\\"payment_status\\\": \\\"unpaid\\\",\\n      \\\"phone_number\\\": \\\"+1 650-468-2904\\\",\\n      \\\"reference_number\\\": null,\\n      \\\"return_status\\\": \\\"unreturned\\\",\\n      \\\"returning_status\\\": \\\"unreturning\\\",\\n      \\\"ship_at\\\": null,\\n      \\\"source_url\\\": null,\\n      \\\"status\\\": \\\"draft\\\",\\n      \\\"tax_label\\\": \\\"GST\\\",\\n      \\\"tax_override\\\": null,\\n      \\\"tax_treatment\\\": \\\"exclusive\\\",\\n      \\\"total\\\": 0,\\n      \\\"tags\\\": [\\n\\n],\\n      \\\"fulfillment_ids\\\": [\\n\\n],\\n      \\\"fulfillment_return_ids\\\": [\\n\\n],\\n      \\\"invoice_ids\\\": [\\n\\n],\\n      \\\"payment_ids\\\": [\\n\\n],\\n      \\\"refund_ids\\\": [\\n\\n],\\n      \\\"invoices\\\": [\\n\\n],\\n      \\\"cached_total\\\": 0,\\n      \\\"default_price_type_id\\\": \\\"wholesale\\\",\\n      \\\"source\\\": null,\\n      \\\"tax_type\\\": \\\"exclusive\\\",\\n      \\\"tracking_number\\\": null,\\n      \\\"url\\\": null,\\n      \\\"source_id\\\": null,\\n      \\\"invoice_numbers\\\": {\\n        \\\"1\\\": \\\"INV001\\\"\\n      },\\n      \\\"order_line_item_ids\\\": [\\n\\n]\\n    }\\n  ]\\n}\\nReturns a list of orders you’ve previously created. The orders are returned in sorted order, with the most recent orders appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of order IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nassignee_id\\nFilter orders by assignee\\n\\n\\nbilling_address_id\\n\\n\\n\\ncompany_id\\n\\n\\n\\ncontact_id\\n\\n\\n\\ncurrency_id\\n\\n\\n\\nshipping_address_id\\n\\n\\n\\nstock_location_id\\n\\n\\n\\nuser_id\\n\\n\\n\\nsource_id\\nInternal ID of the OAuth application that created the order (if not via web interface)\\n\\n\\norder_number\\n\\n\\n\\nreference_number\\n\\n\\n\\ntags\\n\\n\\n\\nstatus\\nPossible options are draft, active, finalized\\n\\n\\npayment_status\\nOne or multiple of 'unpaid', 'partial' and 'paid'\\n\\n\\ninvoice_status\\ne.g. uninvoiced, partial or invoiced\\n\\n\\npacked_status\\ne.g. unpacked, partial or packed\\n\\n\\nfulfillment_status\\ne.g. unshipped, partial or shipped\\n\\n\\nreturn_status\\ne.g. unreturned, partial or returned\\n\\n\\nreturning_status\\ne.g. unreturning, partial or returning\\n\\n\\nshippability_status\\ne.g. not_shippable, partially_shippable or shippable\\n\\n\\nbackordering_status\\ne.g. not_backordered, partially_backordered or backordered\\n\\nHTTP Request:GET  https://api.tradegecko.com/orders\"},{\"id\":\"create-a-new-order\",\"title\":\"Create a new order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\norder = gecko.Order.build({\\n  company_id: 1,\\n  issued_at: \\\"2015-11-12T08:06:01.561Z\\\",\\n  billing_address_id: 1,\\n  shipping_address_id: 1,\\n  order_line_items: [\\n    {\\n      variant_id: 123,\\n      quantity: 2,\\n      price: 10\\n    },\\n    {\\n      variant_id: 456,\\n      quantity: 5,\\n      price: 15.5\\n    }\\n  ]\\n})\\norder.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/ -d '{\\\"order\\\":{\\\"company_id\\\":1,\\\"issued_at\\\":\\\"2015-11-12T08:06:01.561Z\\\",\\\"billing_address_id\\\":1,\\\"shipping_address_id\\\":1,\\\"order_line_items\\\":[{\\\"variant_id\\\":123,\\\"quantity\\\":2,\\\"price\\\":10},{\\\"variant_id\\\":456,\\\"quantity\\\":5,\\\"price\\\":15.5}]}}'\\n{\\n  \\\"order\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-12T08:06:01.561Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-12T08:06:01.561Z\\\",\\n    \\\"document_url\\\": \\\"https://go.tradegecko.com/d/not-a-real-token-2\\\",\\n    \\\"assignee_id\\\": null,\\n    \\\"billing_address_id\\\": 1,\\n    \\\"company_id\\\": 1,\\n    \\\"contact_id\\\": null,\\n    \\\"currency_id\\\": 1,\\n    \\\"shipping_address_id\\\": 1,\\n    \\\"stock_location_id\\\": 1,\\n    \\\"user_id\\\": 1,\\n    \\\"default_price_list_id\\\": \\\"retail\\\",\\n    \\\"email\\\": \\\"example@tradegecko.com\\\",\\n    \\\"fulfillment_status\\\": \\\"unshipped\\\",\\n    \\\"invoice_status\\\": \\\"uninvoiced\\\",\\n    \\\"issued_at\\\": \\\"2015-11-12\\\",\\n    \\\"notes\\\": null,\\n    \\\"order_number\\\": \\\"SO0001\\\",\\n    \\\"packed_status\\\": \\\"unpacked\\\",\\n    \\\"payment_status\\\": \\\"unpaid\\\",\\n    \\\"phone_number\\\": \\\"+1 650-468-2904\\\",\\n    \\\"reference_number\\\": null,\\n    \\\"return_status\\\": \\\"unreturned\\\",\\n    \\\"returning_status\\\": \\\"unreturning\\\",\\n    \\\"ship_at\\\": null,\\n    \\\"source_url\\\": null,\\n    \\\"status\\\": \\\"draft\\\",\\n    \\\"tax_label\\\": \\\"GST\\\",\\n    \\\"tax_override\\\": null,\\n    \\\"tax_treatment\\\": \\\"inclusive\\\",\\n    \\\"total\\\": 0,\\n    \\\"tags\\\": [\\n\\n],\\n    \\\"fulfillment_ids\\\": [\\n\\n],\\n    \\\"fulfillment_return_ids\\\": [\\n\\n],\\n    \\\"invoice_ids\\\": [\\n\\n],\\n    \\\"payment_ids\\\": [\\n\\n],\\n    \\\"refund_ids\\\": [\\n\\n],\\n    \\\"invoices\\\": [\\n\\n],\\n    \\\"cached_total\\\": 0,\\n    \\\"default_price_type_id\\\": \\\"wholesale\\\",\\n    \\\"source\\\": null,\\n    \\\"tax_type\\\": \\\"exclusive\\\",\\n    \\\"tracking_number\\\": null,\\n    \\\"url\\\": null,\\n    \\\"source_id\\\": null,\\n    \\\"invoice_numbers\\\": {\\n      \\\"1\\\": \\\"INV001\\\"\\n    },\\n    \\\"order_line_item_ids\\\": [\\n      1,\\n      2\\n    ]\\n  }\\n}\\nCreates a new order object.\\nThis endpoint also accepts embedded order_line_items.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nassignee_id\\nInteger\\nThe assignee to which the order belongs.\\n\\n\\n\\nissued_at\\nString\\nIssue date for the order\\ntrue\\n\\n\\nship_at\\nString\\nShip date for the order.\\n\\n\\n\\nbilling_address_id\\nInteger\\n\\ntrue\\n\\n\\ncompany_id\\nInteger\\n\\ntrue\\n\\n\\ncontact_id\\nInteger\\n\\n\\n\\n\\nshipping_address_id\\nInteger\\n\\ntrue\\n\\n\\nstock_location_id\\nInteger\\n\\n\\n\\n\\ndefault_price_list_id\\nString\\n\\n\\n\\n\\nemail\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\norder_number\\nString\\n\\n\\n\\n\\nphone_number\\nString\\n\\n\\n\\n\\nreference_number\\nString\\nA reference for the order that isn't the order_number\\n\\n\\n\\nsource_url\\nString\\n\\n\\n\\n\\ntags\\nArray[String]\\nReference tags for the order, used in filtering.\\n\\n\\n\\ntax_treatment\\nString\\nOne of 'exclusive' or 'inclusive', if not provided defaults to account default.\\n\\n\\n\\nstatus\\nString\\nSignifies the current state of the order, can be set as 'draft', 'active' or 'finalized'\\n\\n\\nOrderLineItem\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\norder_id\\nInteger\\nThe order to which the order_line_item belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the order_line_item belongs.\\ntrue\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the order_line_item belongs.\\ntrue\\n\\n\\ndiscount\\nString\\nBetween -100 and 100\\n\\n\\n\\nfreeform\\nBoolean\\n\\n\\n\\n\\nimage_url\\nString\\n\\n\\n\\n\\nlabel\\nString\\n\\n\\n\\n\\nline_type\\nString\\nOptional field for tracking the basic type of a line item, currently used for Channel/API integrations only, blank otherwise. Supported values are: 'product', 'discount', 'shipping', 'rounding', 'fee', and 'gift_wrap'\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\nPrice of a single item. If not provided, we will attempt to pull the price from the parent order's default price list\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\ntax_rate_override\\nString\\n\\n\\n\\n\\ntax_rate deprecated\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/orders/\"},{\"id\":\"retrieve-a-particular-order\",\"title\":\"Retrieve a particular order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Order.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/1\\n{\\n  \\\"order\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-12T08:06:01.561Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-12T08:06:01.561Z\\\",\\n    \\\"document_url\\\": \\\"https://go.tradegecko.com/d/not-a-real-token-2\\\",\\n    \\\"assignee_id\\\": null,\\n    \\\"billing_address_id\\\": 1,\\n    \\\"company_id\\\": 1,\\n    \\\"contact_id\\\": null,\\n    \\\"currency_id\\\": 1,\\n    \\\"shipping_address_id\\\": 1,\\n    \\\"stock_location_id\\\": 1,\\n    \\\"user_id\\\": 1,\\n    \\\"default_price_list_id\\\": \\\"retail\\\",\\n    \\\"email\\\": \\\"example@tradegecko.com\\\",\\n    \\\"fulfillment_status\\\": \\\"unshipped\\\",\\n    \\\"invoice_status\\\": \\\"uninvoiced\\\",\\n    \\\"issued_at\\\": \\\"2015-11-12\\\",\\n    \\\"notes\\\": null,\\n    \\\"order_number\\\": \\\"SO0001\\\",\\n    \\\"packed_status\\\": \\\"unpacked\\\",\\n    \\\"payment_status\\\": \\\"unpaid\\\",\\n    \\\"phone_number\\\": \\\"+1 650-468-2904\\\",\\n    \\\"reference_number\\\": null,\\n    \\\"return_status\\\": \\\"unreturned\\\",\\n    \\\"returning_status\\\": \\\"unreturning\\\",\\n    \\\"ship_at\\\": null,\\n    \\\"source_url\\\": null,\\n    \\\"status\\\": \\\"draft\\\",\\n    \\\"tax_label\\\": \\\"GST\\\",\\n    \\\"tax_override\\\": null,\\n    \\\"tax_treatment\\\": \\\"inclusive\\\",\\n    \\\"total\\\": 0,\\n    \\\"tags\\\": [\\n\\n],\\n    \\\"fulfillment_ids\\\": [\\n\\n],\\n    \\\"fulfillment_return_ids\\\": [\\n\\n],\\n    \\\"invoice_ids\\\": [\\n\\n],\\n    \\\"payment_ids\\\": [\\n\\n],\\n    \\\"refund_ids\\\": [\\n\\n],\\n    \\\"invoices\\\": [\\n\\n],\\n    \\\"cached_total\\\": 0,\\n    \\\"default_price_type_id\\\": \\\"wholesale\\\",\\n    \\\"source\\\": null,\\n    \\\"tax_type\\\": \\\"exclusive\\\",\\n    \\\"tracking_number\\\": null,\\n    \\\"url\\\": null,\\n    \\\"source_id\\\": null,\\n    \\\"invoice_numbers\\\": {\\n      \\\"1\\\": \\\"INV001\\\"\\n    },\\n    \\\"order_line_item_ids\\\": [\\n      1,\\n      2\\n    ]\\n  }\\n}\\nRetrieves the details of an existing order. You need only supply the unique order identifier that was returned upon order creation.HTTP RequestGET https://api.tradegecko.com/orders/{RESOURCE_ID}\"},{\"id\":\"update-an-order\",\"title\":\"Update an order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\norder = gecko.Order.find(1)\\norder.attributes = {\\n  status: \\\"active\\\",\\n  email: \\\"hello@tradegecko.com\\\",\\n  billing_address_id: 2\\n}\\norder.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/1 -d '{\\\"order\\\":{\\\"status\\\":\\\"active\\\",\\\"email\\\":\\\"hello@tradegecko.com\\\",\\\"billing_address_id\\\":2}}'\\n\\nResponse\\n\\nReturns 204 status when the order gets updated successfully.\\n\\nUpdates the specified order by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the order creation call.HTTP RequestPUT https://api.tradegecko.com/orders/{RESOURCE_ID}\"},{\"id\":\"order-actions\",\"title\":\"Order actions\",\"body\":\"Use the following endpoints to manage the order's invoice, payment and fulfillment. POST /orders/[:order_id]/actions/[:action]curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/[:order_id]/actions/[:order_action]\\n\\n\\nAction\\nDescription\\n\\n\\n\\ninvoice\\nInvoices the whole order. If there are already existing invoices, creates another invoice with the remaining uninvoiced line items\\n\\n\\npay\\nCreates payments for the entire order value. It will pay any existing unpaid or partially paid invoices and create an invoice and payment for the remaining value\\n\\n\\npack\\nCreate a fulfillment with status: packed for any unpacked items.\\n\\n\\nfulfil\\nCreate a fulfillment with status: fulfilled. It will fulfill any existing fulfillments and create a new fulfillment for any remaining items\\n\\n\\nvoid\\nVoids the order\\n\\nCustomized actionsSome action endpoints would allow you to pass additional parameters on the body of your POST request in order for you to do more with just a single API callcurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/[:order_id]/actions/[:order_action]\\n-d {\\\"payment\\\":{\\\"payment_method_name\\\": \\\"Credit Card\\\", \\\"paid_at\\\": \\\"2015-11-12T08:06:01.561Z\\\"}}\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/[:order_id]/actions/[:order_action]\\n-d {\\\"fulfillment\\\":{\\\"tracking_number\\\": \\\"00J6E0001234\\\", \\\"tracking_url\\\": \\\"https://trackpackage.com?track=00J6E0001234\\\", \\\"tracking_company\\\": \\\"Track Package\\\", \\\"service\\\": \\\"TPackage\\\", \\\"notes\\\": \\\"Handle with care\\\"}}\\n\\n\\nAction\\nDescription\\nAllowed Attributes\\n\\n\\n\\npay\\nSet the order's payment status to paid, create an invoice and create a payment using the provided payment_method_name and paid_at in a single API call\\npayment_method_name, paid_at\\n\\n\\ninvoice\\nSet the order's invoiced status to invoiced, and creates an invoice for all uninvoiced items in a single API call\\ndue_at, invoiced_at, notes\\n\\n\\npack\\nSet the order's status to packed, and create a fulfillment using any provided tracking details and notes in a single API call\\ntracking_number, tracking_company, tracking_url, service, notes\\n\\n\\nfulfil\\nSet the order's status to fulfilled, and create a fulfillment using any provided tracking details and notes in a single API call\\ntracking_number, tracking_company, tracking_url, service, notes\\n\\n\"},{\"id\":\"delete-an-order\",\"title\":\"Delete an order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\norder = gecko.Order.find(1)\\norder.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/orders/1\\n\\nResponse\\n\\nReturns 204 status when the order gets deleted successfully.\\n\\nPermanently deletes an order. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/orders/{RESOURCE_ID}/\"},{\"id\":\"orderlineitem\",\"title\":\"OrderLineItem\",\"body\":\"This is an object representing an order_line_item of an order. Orders can\\n  have multiple order_line_items but an order_line_item object belongs to only one\\n  Order.\"},{\"id\":\"the-orderlineitem-object\",\"title\":\"The OrderLineItem object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\norder_id\\nInteger\\nThe order to which the order_line_item belongs.\\n\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the order_line_item belongs.\\n\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the order_line_item belongs.\\n\\n\\n\\ndiscount\\nString\\nBetween -100 and 100\\n\\n\\n\\nfreeform\\nBoolean\\n\\n\\n\\n\\nimage_url\\nString\\n\\n\\n\\n\\nlabel\\nString\\n\\n\\n\\n\\nline_type\\nString\\nOptional field for tracking the basic type of a line item, currently used for Channel/API integrations only, blank otherwise. Supported values are: 'product', 'discount', 'shipping', 'rounding', 'fee', and 'gift_wrap'\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\nPrice of a single item. If not provided, we will attempt to pull the price from the parent order's default price list\\n\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\ntax_rate_override\\nString\\n\\n\\n\\n\\ntax_rate  deprecated\\nString\\n\\n\\n\\n\\nfulfillment_line_item_ids\\nArray\\n\\ntrue\\n\\n\\nfulfillment_return_line_item_ids\\nArray\\n\\ntrue\\n\\n\\ninvoice_line_item_ids\\nArray\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-order_line_items\",\"title\":\"List all order_line_items\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.OrderLineItem.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/order_line_items/\\n{\\n  \\\"order_line_items\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-12T06:39:53.231Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-12T06:39:53.231Z\\\",\\n      \\\"order_id\\\": 1,\\n      \\\"variant_id\\\": 2,\\n      \\\"tax_type_id\\\": 1,\\n      \\\"discount\\\": \\\"11.0\\\",\\n      \\\"freeform\\\": false,\\n      \\\"image_url\\\": null,\\n      \\\"label\\\": null,\\n      \\\"line_type\\\": null,\\n      \\\"position\\\": 0,\\n      \\\"price\\\": \\\"189.0\\\",\\n      \\\"quantity\\\": \\\"1.0\\\",\\n      \\\"tax_rate_override\\\": null,\\n      \\\"fulfillment_line_item_ids\\\": [\\n\\n],\\n      \\\"fulfillment_return_line_item_ids\\\": [\\n\\n],\\n      \\\"invoice_line_item_ids\\\": [\\n\\n]\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-12T06:32:31.607Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-12T06:32:31.607Z\\\",\\n      \\\"order_id\\\": 1,\\n      \\\"variant_id\\\": 1,\\n      \\\"tax_type_id\\\": 1,\\n      \\\"discount\\\": \\\"11.0\\\",\\n      \\\"freeform\\\": false,\\n      \\\"image_url\\\": \\\"null\\\",\\n      \\\"label\\\": \\\"null\\\",\\n      \\\"line_type\\\": \\\"product\\\",\\n      \\\"position\\\": 0,\\n      \\\"price\\\": \\\"189.0\\\",\\n      \\\"quantity\\\": \\\"1.0\\\",\\n      \\\"tax_rate_override\\\": null,\\n      \\\"fulfillment_line_item_ids\\\": [\\n\\n],\\n      \\\"fulfillment_return_line_item_ids\\\": [\\n\\n],\\n      \\\"invoice_line_item_ids\\\": [\\n\\n]\\n    }\\n  ]\\n}\\nReturns a list of order_line_items you’ve previously created. The order_line_items are returned in sorted order, with the most recent order_line_items appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of order_line_item IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\norder_id\\nFilter order_line_items by order\\n\\n\\nvariant_id\\nFilter order_line_items by variant\\n\\n\\ntax_type_id\\nFilter order_line_items by tax_type\\n\\n\\norder_status\\nFilter order_line_items by order status\\n\\nHTTP Request:GET  https://api.tradegecko.com/order_line_items\"},{\"id\":\"create-a-new-order_line_item\",\"title\":\"Create a new order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\norder_line_item = gecko.OrderLineItem.build({\\n  quantity: \\\"12.0\\\",\\n  order_id: 1,\\n  tax_type_id: 1,\\n  price: \\\"10.0\\\"\\n})\\norder_line_item.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/order_line_items/ -d '{\\\"order_line_item\\\":{\\\"quantity\\\":\\\"12.0\\\",\\\"order_id\\\":1,\\\"tax_type_id\\\":1,\\\"price\\\":\\\"10.0\\\"}}'\\n{\\n  \\\"order_line_item\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-12T06:39:53.231Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-12T06:39:53.231Z\\\",\\n    \\\"order_id\\\": 1,\\n    \\\"variant_id\\\": 2,\\n    \\\"tax_type_id\\\": 1,\\n    \\\"discount\\\": \\\"11.0\\\",\\n    \\\"freeform\\\": false,\\n    \\\"image_url\\\": null,\\n    \\\"label\\\": null,\\n    \\\"line_type\\\": null,\\n    \\\"position\\\": 0,\\n    \\\"price\\\": \\\"189.0\\\",\\n    \\\"quantity\\\": \\\"1.0\\\",\\n    \\\"tax_rate_override\\\": null,\\n    \\\"fulfillment_line_item_ids\\\": [\\n\\n],\\n    \\\"fulfillment_return_line_item_ids\\\": [\\n\\n],\\n    \\\"invoice_line_item_ids\\\": [\\n\\n]\\n  }\\n}\\nCreates a new order_line_item object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\norder_id\\nInteger\\nThe order to which the order_line_item belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the order_line_item belongs.\\ntrue\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the order_line_item belongs.\\ntrue\\n\\n\\ndiscount\\nString\\nBetween -100 and 100\\n\\n\\n\\nfreeform\\nBoolean\\n\\n\\n\\n\\nimage_url\\nString\\n\\n\\n\\n\\nlabel\\nString\\n\\n\\n\\n\\nline_type\\nString\\nOptional field for tracking the basic type of a line item, currently used for Channel/API integrations only, blank otherwise. Supported values are: 'product', 'discount', 'shipping', 'rounding', 'fee', and 'gift_wrap'\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\nPrice of a single item. If not provided, we will attempt to pull the price from the parent order's default price list\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\ntax_rate_override\\nString\\n\\n\\n\\n\\ntax_rate deprecated\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/order_line_items/\"},{\"id\":\"retrieve-a-particular-order_line_item\",\"title\":\"Retrieve a particular order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.OrderLineItem.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/order_line_items/1\\n{\\n  \\\"order_line_item\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-12T06:39:53.231Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-12T06:39:53.231Z\\\",\\n    \\\"order_id\\\": 1,\\n    \\\"variant_id\\\": 2,\\n    \\\"tax_type_id\\\": 1,\\n    \\\"discount\\\": \\\"11.0\\\",\\n    \\\"freeform\\\": false,\\n    \\\"image_url\\\": null,\\n    \\\"label\\\": null,\\n    \\\"line_type\\\": null,\\n    \\\"position\\\": 0,\\n    \\\"price\\\": \\\"189.0\\\",\\n    \\\"quantity\\\": \\\"1.0\\\",\\n    \\\"tax_rate_override\\\": null,\\n    \\\"fulfillment_line_item_ids\\\": [\\n\\n],\\n    \\\"fulfillment_return_line_item_ids\\\": [\\n\\n],\\n    \\\"invoice_line_item_ids\\\": [\\n\\n]\\n  }\\n}\\nRetrieves the details of an existing order_line_item. You need only supply the unique order_line_item identifier that was returned upon order_line_item creation.HTTP RequestGET https://api.tradegecko.com/order_line_items/{RESOURCE_ID}\"},{\"id\":\"update-an-order_line_item\",\"title\":\"Update an order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\norder_line_item = gecko.OrderLineItem.find(1)\\norder_line_item.attributes = {\\n  quantity: \\\"22.0\\\",\\n  price: \\\"12.0\\\"\\n}\\norder_line_item.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/order_line_items/1 -d '{\\\"order_line_item\\\":{\\\"quantity\\\":\\\"22.0\\\",\\\"price\\\":\\\"12.0\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the order_line_item gets updated successfully.\\n\\nUpdates the specified order_line_item by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the order_line_item creation call.HTTP RequestPUT https://api.tradegecko.com/order_line_items/{RESOURCE_ID}\"},{\"id\":\"delete-an-order_line_item\",\"title\":\"Delete an order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\norder_line_item = gecko.OrderLineItem.find(1)\\norder_line_item.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/order_line_items/1\\n\\nResponse\\n\\nReturns 204 status when the order_line_item gets deleted successfully.\\n\\nPermanently deletes an order_line_item. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/order_line_items/{RESOURCE_ID}/\"},{\"id\":\"paymentmethod\",\"title\":\"PaymentMethod\",\"body\":\"This is an object representing a payment_method.\"},{\"id\":\"the-paymentmethod-object\",\"title\":\"The PaymentMethod object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nname\\nString\\nName of the payment method.\\n\\n\\n\\nis_default\\nBoolean\\nIs the default payment method of the account.\\ntrue\\n\\n\"},{\"id\":\"list-all-payment_methods\",\"title\":\"List all payment_methods\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_methods/\\n{\\n  \\\"payment_methods\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2019-10-24T11:21:57.700Z\\\",\\n      \\\"updated_at\\\": \\\"2019-10-24T11:21:57.700Z\\\",\\n      \\\"name\\\": \\\"Cash\\\",\\n      \\\"is_default\\\": true\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2019-10-24T11:21:57.710Z\\\",\\n      \\\"updated_at\\\": \\\"2019-10-24T11:21:57.710Z\\\",\\n      \\\"name\\\": \\\"Credit Card\\\",\\n      \\\"is_default\\\": false\\n    },\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2019-10-24T11:21:57.721Z\\\",\\n      \\\"updated_at\\\": \\\"2019-10-24T11:21:57.721Z\\\",\\n      \\\"name\\\": \\\"Bank Transfer\\\",\\n      \\\"is_default\\\": false\\n    }\\n  ]\\n}\\nReturns a list of payment_methods you’ve previously created. The payment_methods are returned in sorted order, with the most recent payment_methods appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of payment_method IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nname\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/payment_methods\"},{\"id\":\"create-a-new-payment_method\",\"title\":\"Create a new payment_method\",\"body\":\"curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_methods/ -d '{\\\"payment_method\\\":{\\\"name\\\":\\\"Wire Transfer\\\"}}'\\n{\\n  \\\"payment_method\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2019-10-24T11:21:57.700Z\\\",\\n    \\\"updated_at\\\": \\\"2019-10-24T11:21:57.700Z\\\",\\n    \\\"name\\\": \\\"Cash\\\",\\n    \\\"is_default\\\": true\\n  }\\n}\\nCreates a new payment_method object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nname\\nString\\nName of the payment method.\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/payment_methods/\"},{\"id\":\"retrieve-a-particular-payment_method\",\"title\":\"Retrieve a particular payment_method\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_methods/\\n{\\n  \\\"payment_method\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2019-10-24T11:21:57.700Z\\\",\\n    \\\"updated_at\\\": \\\"2019-10-24T11:21:57.700Z\\\",\\n    \\\"name\\\": \\\"Cash\\\",\\n    \\\"is_default\\\": true\\n  }\\n}\\nRetrieves the details of an existing payment_method. You need only supply the unique payment_method identifier that was returned upon payment_method creation.HTTP RequestGET https://api.tradegecko.com/payment_methods/{RESOURCE_ID}\"},{\"id\":\"update-a-payment_method\",\"title\":\"Update a payment_method\",\"body\":\"curl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com//1 -d '{\\\"payment_method\\\":{\\\"name\\\":\\\"PayPal\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the payment_method gets updated successfully.\\n\\nUpdates the specified payment_method by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the payment_method creation call.HTTP RequestPUT https://api.tradegecko.com//{RESOURCE_ID}\"},{\"id\":\"delete-a-payment_method\",\"title\":\"Delete a payment_method\",\"body\":\"curl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_methods/1\\n\\nResponse\\n\\nReturns 204 status when the payment_method gets deleted successfully.\\n\\nPermanently deletes a payment_method. It cannot be undone.\\n  This payment_method will no longer be available for future Payment.HTTP RequestDELETE https://api.tradegecko.com/payment_methods/{RESOURCE_ID}/\"},{\"id\":\"paymentterm\",\"title\":\"PaymentTerm\",\"body\":\"This is an object representing a payment_term.\"},{\"id\":\"the-paymentterm-object\",\"title\":\"The PaymentTerm object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'\\ntrue\\n\\n\\nname\\nString\\n\\n\\n\\n\\ndue_in_days\\nString\\nNumber of days until payment is due\\n\\n\\n\\nfrom\\nString\\nDictates whether due_in_days starts from 'now' or 'eom' (end of month).\\n\\n\\n\"},{\"id\":\"list-all-payment_terms\",\"title\":\"List all payment_terms\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.PaymentTerm.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_terms/\\n{\\n  \\\"payment_terms\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"name\\\": \\\"NET30\\\",\\n      \\\"due_in_days\\\": 30,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"from\\\": \\\"now\\\"\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"name\\\": \\\"NET10\\\",\\n      \\\"due_in_days\\\": 10,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"from\\\": \\\"now\\\"\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"name\\\": \\\"Cash on Delivery\\\",\\n      \\\"due_in_days\\\": 0,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"from\\\": \\\"now\\\"\\n    }\\n  ]\\n}\\nReturns a list of payment_terms you’ve previously created. The payment_terms are returned in sorted order, with the most recent payment_terms appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of payment_term IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\nHTTP Request:GET  https://api.tradegecko.com/payment_terms\"},{\"id\":\"create-a-new-payment_term\",\"title\":\"Create a new payment_term\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npayment_term = gecko.PaymentTerm.build({\\n  name: \\\"NET30\\\",\\n  due_in_days: \\\"30\\\",\\n  from: \\\"eom\\\"\\n})\\npayment_term.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_terms/ -d '{\\\"payment_term\\\":{\\\"name\\\":\\\"NET30\\\",\\\"due_in_days\\\":\\\"30\\\",\\\"from\\\":\\\"eom\\\"}}'\\n{\\n  \\\"payment_term\\\": {\\n    \\\"id\\\": 3,\\n    \\\"name\\\": \\\"NET30\\\",\\n    \\\"due_in_days\\\": 30,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"from\\\": \\\"now\\\"\\n  }\\n}\\nCreates a new payment_term object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nname\\nString\\n\\n\\n\\n\\ndue_in_days\\nString\\nNumber of days until payment is due\\n\\n\\n\\nfrom\\nString\\nDictates whether due_in_days starts from 'now' or 'eom' (end of month).\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/payment_terms/\"},{\"id\":\"retrieve-a-particular-payment_term\",\"title\":\"Retrieve a particular payment_term\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.PaymentTerm.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_terms/1\\n{\\n  \\\"payment_term\\\": {\\n    \\\"id\\\": 3,\\n    \\\"name\\\": \\\"NET30\\\",\\n    \\\"due_in_days\\\": 30,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"from\\\": \\\"now\\\"\\n  }\\n}\\nRetrieves the details of an existing payment_term. You need only supply the unique payment_term identifier that was returned upon payment_term creation.HTTP RequestGET https://api.tradegecko.com/payment_terms/{RESOURCE_ID}\"},{\"id\":\"update-a-payment_term\",\"title\":\"Update a payment_term\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npayment_term = gecko.PaymentTerm.find(1)\\npayment_term.attributes = {\\n  from: \\\"now\\\"\\n}\\npayment_term.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_terms/1 -d '{\\\"payment_term\\\":{\\\"from\\\":\\\"now\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the payment_term gets updated successfully.\\n\\nUpdates the specified payment_term by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the payment_term creation call.HTTP RequestPUT https://api.tradegecko.com/payment_terms/{RESOURCE_ID}\"},{\"id\":\"delete-a-payment_term\",\"title\":\"Delete a payment_term\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npayment_term = gecko.PaymentTerm.find(1)\\npayment_term.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/payment_terms/1\\n\\nResponse\\n\\nReturns 204 status when the payment_term gets deleted successfully.\\n\\nPermanently deletes a payment_term. It cannot be undone.\\n  This payment_term will no longer be available for future Invoice.HTTP RequestDELETE https://api.tradegecko.com/payment_terms/{RESOURCE_ID}/\"},{\"id\":\"product\",\"title\":\"Product\",\"body\":\"This is an object representing a product.\"},{\"id\":\"the-product-object\",\"title\":\"The Product object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active', 'disabled' or 'archived'\\ntrue\\n\\n\\nbrand\\nString\\nName of the brand of the product\\n\\n\\n\\ndescription\\nString\\nA brief description of the product\\n\\n\\n\\nimage_url\\nString\\nFirst image of the product (sorted on position)\\ntrue\\n\\n\\nname\\nString\\n\\n\\n\\n\\nopt1\\nString\\nCustom product property name eg. 'Size', 'Color'\\n\\n\\n\\nopt2\\nString\\nCustom product property name eg. 'Size', 'Color'\\n\\n\\n\\nopt3\\nString\\nCustom product property name eg. 'Size', 'Color'\\n\\n\\n\\nproduct_type\\nString\\n\\n\\n\\n\\nquantity\\nString\\nSum of the quantities of child variants\\ntrue\\n\\n\\nsupplier  deprecated\\nString\\nName of the supplier of the product\\n\\n\\n\\nsupplier_ids\\nArray\\nShould currently only be one ID for backwards compatibility purposes\\n\\n\\n\\nimage_ids\\nArray\\nThe IDs of all the images linked to the product\\n\\n\\n\\ntags\\nArray\\nProduct tags for easier filtering and searching\\n\\n\\n\\nvariant_ids\\nArray\\n\\ntrue\\n\\n\\nvendor  deprecated\\nString\\nWill be removed very soon.\\n\\n\\n\"},{\"id\":\"list-all-products\",\"title\":\"List all products\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Product.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/products/\\n{\\n  \\\"products\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.817Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:24.817Z\\\",\\n      \\\"brand\\\": null,\\n      \\\"description\\\": \\\"All ready for Easter, our giant golden chocolate eggs are just what the doctor ordered, adults and children alike\\\",\\n      \\\"image_url\\\": null,\\n      \\\"name\\\": \\\"Golden Egg\\\",\\n      \\\"opt1\\\": \\\"Size\\\",\\n      \\\"opt2\\\": null,\\n      \\\"opt3\\\": null,\\n      \\\"product_type\\\": \\\"Chocolate\\\",\\n      \\\"quantity\\\": \\\"32.5\\\",\\n      \\\"search_cache\\\": \\\"DEMO-EGG-L Large DEMO-EGG-XL Extra-Large DEMO-EGG-M Medium DEMO-EGG-S Small\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"supplier\\\": \\\"Wonka Candy\\\",\\n      \\\"supplier_ids\\\": [\\n        3\\n      ],\\n      \\\"image_ids\\\": [\\n        1,\\n        2\\n      ],\\n      \\\"tags\\\": \\\"candy,chocolate\\\",\\n      \\\"variant_ids\\\": [\\n        4,\\n        5,\\n        6,\\n        7\\n      ],\\n      \\\"vendor\\\": \\\"Wonka Candy\\\"\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.660Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:24.660Z\\\",\\n      \\\"brand\\\": null,\\n      \\\"description\\\": \\\"These everlasting gobstoppers will never run out. Just keep going forever and ever, full flavour guaranteed\\\",\\n      \\\"image_url\\\": null,\\n      \\\"name\\\": \\\"Everlasting Gobstopper\\\",\\n      \\\"opt1\\\": \\\"Flavour\\\",\\n      \\\"opt2\\\": null,\\n      \\\"opt3\\\": null,\\n      \\\"product_type\\\": \\\"Candy\\\",\\n      \\\"quantity\\\": \\\"17\\\",\\n      \\\"search_cache\\\": \\\"DEMO-GOBS-PEA Peach DEMO-GOBS-SNO Snozzberry\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"supplier\\\": \\\"Wonka Candy\\\",\\n      \\\"supplier_ids\\\": [\\n        3\\n      ],\\n      \\\"image_ids\\\": [\\n\\n],\\n      \\\"tags\\\": \\\"candy,summer\\\",\\n      \\\"variant_ids\\\": [\\n        2,\\n        3\\n      ],\\n      \\\"vendor\\\": \\\"Wonka Candy\\\"\\n    }\\n  ]\\n}\\nReturns a list of products you’ve previously created. The products are returned in sorted order, with the most recent products appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of product IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nPossible options are: active, disabled.\\n\\n\\nbrand\\n\\n\\n\\nproduct_type\\n\\n\\n\\ntags\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/products\"},{\"id\":\"create-a-new-product\",\"title\":\"Create a new product\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nproduct = gecko.Product.build({\\n  name: \\\"Everlasting Gobstopper\\\",\\n  opt1: \\\"Colour\\\"\\n})\\nproduct.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/products/ -d '{\\\"product\\\":{\\\"name\\\":\\\"Everlasting Gobstopper\\\",\\\"opt1\\\":\\\"Colour\\\"}}'\\n{\\n  \\\"product\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:24.817Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:24.817Z\\\",\\n    \\\"brand\\\": null,\\n    \\\"description\\\": \\\"All ready for Easter, our giant golden chocolate eggs are just what the doctor ordered, adults and children alike\\\",\\n    \\\"image_url\\\": null,\\n    \\\"name\\\": \\\"Golden Egg\\\",\\n    \\\"opt1\\\": \\\"Size\\\",\\n    \\\"opt2\\\": null,\\n    \\\"opt3\\\": null,\\n    \\\"product_type\\\": \\\"Chocolate\\\",\\n    \\\"quantity\\\": \\\"32.5\\\",\\n    \\\"search_cache\\\": \\\"DEMO-EGG-L Large DEMO-EGG-XL Extra-Large DEMO-EGG-M Medium DEMO-EGG-S Small\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"supplier\\\": \\\"Wonka Candy\\\",\\n    \\\"supplier_ids\\\": [\\n      3\\n    ],\\n    \\\"image_ids\\\": [\\n      1,\\n      2\\n    ],\\n    \\\"tags\\\": \\\"candy,chocolate\\\",\\n    \\\"variant_ids\\\": [\\n      4,\\n      5,\\n      6,\\n      7\\n    ],\\n    \\\"vendor\\\": \\\"Wonka Candy\\\"\\n  }\\n}\\nCreates a new product object.\\nThis endpoint also accepts embedded variants.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nbrand\\nString\\nName of the brand of the product\\n\\n\\n\\ndescription\\nString\\nA brief description of the product\\n\\n\\n\\nname\\nString\\n\\ntrue\\n\\n\\nopt1\\nString\\nCustom product property name eg. 'Size', 'Color'\\n\\n\\n\\nopt2\\nString\\nCustom product property name eg. 'Size', 'Color'\\n\\n\\n\\nopt3\\nString\\nCustom product property name eg. 'Size', 'Color'\\n\\n\\n\\nproduct_type\\nString\\n\\n\\n\\n\\nquantity\\nString\\nSum of the quantities of child variants\\n\\n\\n\\nsupplier deprecated\\nString\\nName of the supplier of the product\\n\\n\\n\\nsupplier_ids\\nArray\\nShould currently only be one ID for backwards compatibility purposes\\n\\n\\n\\ntags\\nArray\\nProduct tags for easier filtering and searching\\n\\n\\n\\nvendor deprecated\\nString\\nWill be removed very soon.\\n\\n\\nVariant\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nproduct_id\\nInteger\\nThe product to which the variant belongs.\\ntrue\\n\\n\\ndefault_ledger_account_id\\nInteger\\nUsed for accounting integrations. (e.g. Revenue Ledger)\\n\\n\\n\\nbuy_price\\nString\\n\\n\\n\\n\\ncomposite\\nBoolean\\nTells whether this variant is a composite (composed of other variants)\\n\\n\\n\\ndescription\\nString\\n\\n\\n\\n\\nhs_code\\nString\\nHarmonized System Code\\n\\n\\n\\ncountry_of_origin\\nString\\nTwo letter country code (e.g. SG, US)\\n\\n\\n\\ninitial_cost_price\\nString\\nThe initial item cost price of the variant, only available when first creating the variant\\n\\n\\n\\ninitial_stock_level\\nString\\nThe initial stock level of the variant, only available when first creating the variant\\n\\n\\n\\ninitial_stock_location_id\\nInteger\\nThe ID of the stock location where initial stock levels should be added, only available when first creating the variant, defaults to your primary stock location\\n\\n\\n\\nkeep_selling\\nBoolean\\nAllow item to continue to be sold, even if it is no longer in stock\\n\\n\\n\\nmanage_stock\\nBoolean\\nFor composite variants, the value of manage_stock will always be true\\n\\n\\n\\nmax_online\\nString\\nIntegrated online store(s) should show current stock levels up to a maximum of this value\\n\\n\\n\\nname\\nString\\n\\n\\n\\n\\nonline_ordering\\nBoolean\\nTells whether variant is for sale on B2B platform\\n\\n\\n\\nopt1\\nString\\n\\n\\n\\n\\nopt2\\nString\\n\\n\\n\\n\\nopt3\\nString\\n\\n\\n\\n\\nposition\\nString\\nDefault sort position of this variant (unique to product)\\n\\n\\n\\npurchasable\\nBoolean\\nTells whether you can create Purchase Order with the variant\\n\\n\\n\\nretail_price\\nString\\nThe recommended retail price\\n\\n\\n\\nsellable\\nString\\nTells whether can be added to sales orders\\n\\n\\n\\nsku\\nString\\nStock Keeping Unit (should be unique)\\n\\n\\n\\nsupplier_code\\nString\\n\\n\\n\\n\\ntaxable\\nBoolean\\nTells whether this variant can be taxed\\n\\n\\n\\nupc\\nString\\nThe barcode or UPC number\\n\\n\\n\\nweight\\nString\\nThe weight value\\n\\n\\n\\nweight_unit\\nString\\nThe weight unit (kg, g, oz or lb)\\n\\n\\n\\nwholesale_price\\nString\\nThe recommended wholesale price for this product\\n\\n\\n\\nimage_ids\\nArray\\nImages assigned to the variant. The order of the Image IDs here is the position of the images on the variant.\\n\\n\\n\\nvariant_prices\\nArray\\nAn array of prices with price list IDs and the price value.\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/products/\"},{\"id\":\"retrieve-a-particular-product\",\"title\":\"Retrieve a particular product\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Product.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/products/1\\n{\\n  \\\"product\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:24.817Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:24.817Z\\\",\\n    \\\"brand\\\": null,\\n    \\\"description\\\": \\\"All ready for Easter, our giant golden chocolate eggs are just what the doctor ordered, adults and children alike\\\",\\n    \\\"image_url\\\": null,\\n    \\\"name\\\": \\\"Golden Egg\\\",\\n    \\\"opt1\\\": \\\"Size\\\",\\n    \\\"opt2\\\": null,\\n    \\\"opt3\\\": null,\\n    \\\"product_type\\\": \\\"Chocolate\\\",\\n    \\\"quantity\\\": \\\"32.5\\\",\\n    \\\"search_cache\\\": \\\"DEMO-EGG-L Large DEMO-EGG-XL Extra-Large DEMO-EGG-M Medium DEMO-EGG-S Small\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"supplier\\\": \\\"Wonka Candy\\\",\\n    \\\"supplier_ids\\\": [\\n      3\\n    ],\\n    \\\"image_ids\\\": [\\n      1,\\n      2\\n    ],\\n    \\\"tags\\\": \\\"candy,chocolate\\\",\\n    \\\"variant_ids\\\": [\\n      4,\\n      5,\\n      6,\\n      7\\n    ],\\n    \\\"vendor\\\": \\\"Wonka Candy\\\"\\n  }\\n}\\nRetrieves the details of an existing product. You need only supply the unique product identifier that was returned upon product creation.HTTP RequestGET https://api.tradegecko.com/products/{RESOURCE_ID}\"},{\"id\":\"update-a-product\",\"title\":\"Update a product\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nproduct = gecko.Product.find(1)\\nproduct.attributes = {\\n  opt2: \\\"Size\\\",\\n  opt3: \\\"Weight\\\"\\n}\\nproduct.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/products/1 -d '{\\\"product\\\":{\\\"opt2\\\":\\\"Size\\\",\\\"opt3\\\":\\\"Weight\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the product gets updated successfully.\\n\\nUpdates the specified product by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the product creation call.HTTP RequestPUT https://api.tradegecko.com/products/{RESOURCE_ID}\"},{\"id\":\"delete-a-product\",\"title\":\"Delete a product\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nproduct = gecko.Product.find(1)\\nproduct.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/products/1\\n\\nResponse\\n\\nReturns 204 status when the product gets deleted successfully.\\n\\nPermanently deletes a product. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/products/{RESOURCE_ID}/\"},{\"id\":\"purchaseorder\",\"title\":\"PurchaseOrder\",\"body\":\"This is an object representing a purchase_order.\"},{\"id\":\"the-purchaseorder-object\",\"title\":\"The PurchaseOrder object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\n\\ntrue\\n\\n\\ndocument_url\\nString\\nShareable URL for resource document\\ntrue\\n\\n\\nbilling_address_id\\nInteger\\nThe billing address for the purchase_order.\\n\\n\\n\\ncompany_id\\nInteger\\nThe company that will be supplying the purchase order\\n\\n\\n\\ncurrency_id\\nInteger\\nThe currency of the purchase_order\\n\\n\\n\\nstock_location_id\\nInteger\\nThe stock location where stock will be delivered\\n\\n\\n\\nsupplier_address_id\\nInteger\\nThe supplier address for the purchase_order.\\n\\n\\n\\ndefault_price_list_id\\nString\\nDefault prices for the purchase_order_line_items (if the variant has a price on this Price List\\n\\n\\n\\ndue_at\\nString\\nDefaults to 14 days from creation\\n\\n\\n\\nemail\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\norder_number\\nString\\n\\n\\n\\n\\npayment_due_at\\nString\\nDefaults to 14 days from creation\\n\\n\\n\\nprocurement_status\\nString\\n\\ntrue\\n\\n\\nreference_number\\nString\\nA reference for the purchase order that isn't the order_number\\n\\n\\n\\ntax_treatment\\nString\\nOne of 'exclusive' or 'inclusive', if not provided defaults to account default.\\n\\n\\n\\nissued_at\\nString\\nDate when purchase was issued.\\n\\n\\n\\nreceived_at\\nString\\n\\ntrue\\n\\n\\ntotal\\nString\\n\\ntrue\\n\\n\\ntags\\nString\\nReference tags for the purchase order, used in filtering.\\n\\n\\n\\ncached_quantity\\nString\\n\\ntrue\\n\\n\\ncached_total  deprecated\\nString\\n\\ntrue\\n\\n\\ndefault_price_type_id  deprecated\\nString\\n\\n\\n\\n\\ntax_type  deprecated\\nString\\n\\n\\n\\n\\npurchase_order_line_item_ids\\nArray\\n\\ntrue\\n\\n\\nprocurement_ids\\nArray\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-purchase_orders\",\"title\":\"List all purchase_orders\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.PurchaseOrder.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_orders/\\n{\\n  \\\"purchase_orders\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-23T11:19:49.857Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-23T11:19:50.427Z\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"document_url\\\": \\\"http://localhost:3000/d/gfPPrlS40mrZOGXXgmOIZcue\\\",\\n      \\\"billing_address_id\\\": 1,\\n      \\\"company_id\\\": 3,\\n      \\\"currency_id\\\": 1,\\n      \\\"stock_location_id\\\": 1,\\n      \\\"supplier_address_id\\\": 4,\\n      \\\"default_price_list_id\\\": \\\"buy\\\",\\n      \\\"due_at\\\": \\\"2015-12-07\\\",\\n      \\\"email\\\": \\\"william@example.com\\\",\\n      \\\"notes\\\": null,\\n      \\\"order_number\\\": \\\"PO0002\\\",\\n      \\\"payment_due_at\\\": \\\"2015-12-07\\\",\\n      \\\"procurement_status\\\": \\\"unprocured\\\",\\n      \\\"reference_number\\\": null,\\n      \\\"tax_treatment\\\": \\\"exclusive\\\",\\n      \\\"issued_at\\\": \\\"2015-11-23\\\",\\n      \\\"received_at\\\": null,\\n      \\\"total\\\": \\\"8.63\\\",\\n      \\\"tags\\\": [\\n\\n],\\n      \\\"cached_quantity\\\": \\\"3.0\\\",\\n      \\\"cached_total\\\": \\\"8.63\\\",\\n      \\\"default_price_type_id\\\": \\\"buy\\\",\\n      \\\"tax_type\\\": \\\"exclusive\\\",\\n      \\\"purchase_order_line_item_ids\\\": [\\n        3,\\n        2\\n      ],\\n      \\\"procurement_ids\\\": [\\n\\n]\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"document_url\\\": \\\"http://localhost:3000/d/RHEDdlXiapBcsQ-CspVHn0i3\\\",\\n      \\\"created_at\\\": \\\"2015-11-23T11:19:07.072Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-23T11:19:07.483Z\\\",\\n      \\\"billing_address_id\\\": 1,\\n      \\\"company_id\\\": 3,\\n      \\\"currency_id\\\": 1,\\n      \\\"stock_location_id\\\": 1,\\n      \\\"supplier_address_id\\\": 4,\\n      \\\"default_price_list_id\\\": \\\"buy\\\",\\n      \\\"due_at\\\": \\\"2015-12-07\\\",\\n      \\\"email\\\": \\\"william@example.com\\\",\\n      \\\"notes\\\": null,\\n      \\\"order_number\\\": \\\"PO0001\\\",\\n      \\\"payment_due_at\\\": \\\"2015-12-07\\\",\\n      \\\"procurement_status\\\": \\\"unprocured\\\",\\n      \\\"reference_number\\\": null,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"tax_treatment\\\": \\\"exclusive\\\",\\n      \\\"issued_at\\\": \\\"2015-11-23\\\",\\n      \\\"received_at\\\": null,\\n      \\\"total\\\": \\\"2.88\\\",\\n      \\\"tags\\\": [\\n\\n],\\n      \\\"cached_quantity\\\": \\\"1.0\\\",\\n      \\\"cached_total\\\": \\\"2.88\\\",\\n      \\\"default_price_type_id\\\": \\\"buy\\\",\\n      \\\"tax_type\\\": \\\"exclusive\\\",\\n      \\\"purchase_order_line_item_ids\\\": [\\n        1\\n      ],\\n      \\\"procurement_ids\\\": [\\n\\n]\\n    }\\n  ]\\n}\\nReturns a list of purchase_orders you’ve previously created. The purchase_orders are returned in sorted order, with the most recent purchase_orders appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of purchase_order IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nPossible options are: active, disabled.\\n\\n\\nbilling_address_id\\n\\n\\n\\ncompany_id\\n\\n\\n\\ncurrency_id\\n\\n\\n\\nstock_location_id\\n\\n\\n\\nsupplier_address_id\\n\\n\\n\\ndue_at\\n\\n\\n\\norder_number\\n\\n\\n\\npayment_due_at\\n\\n\\n\\nissued_at\\n\\n\\n\\ntags\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/purchase_orders\"},{\"id\":\"create-a-new-purchase_order\",\"title\":\"Create a new purchase_order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npurchase_order = gecko.PurchaseOrder.build({\\n  company_id: 1,\\n  issued_at: \\\"2015-11-23T11:19:07.072Z\\\",\\n  billing_address_id: 1,\\n  shipping_address_id: 1\\n})\\npurchase_order.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_orders/ -d '{\\\"purchase_order\\\":{\\\"company_id\\\":1,\\\"issued_at\\\":\\\"2015-11-23T11:19:07.072Z\\\",\\\"billing_address_id\\\":1,\\\"shipping_address_id\\\":1}}'\\n{\\n  \\\"purchase_order\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-23T11:19:49.857Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-23T11:19:50.427Z\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"document_url\\\": \\\"http://localhost:3000/d/gfPPrlS40mrZOGXXgmOIZcue\\\",\\n    \\\"billing_address_id\\\": 1,\\n    \\\"company_id\\\": 3,\\n    \\\"currency_id\\\": 1,\\n    \\\"stock_location_id\\\": 1,\\n    \\\"supplier_address_id\\\": 4,\\n    \\\"default_price_list_id\\\": \\\"buy\\\",\\n    \\\"due_at\\\": \\\"2015-12-07\\\",\\n    \\\"email\\\": \\\"william@example.com\\\",\\n    \\\"notes\\\": null,\\n    \\\"order_number\\\": \\\"PO0002\\\",\\n    \\\"payment_due_at\\\": \\\"2015-12-07\\\",\\n    \\\"procurement_status\\\": \\\"unprocured\\\",\\n    \\\"reference_number\\\": null,\\n    \\\"tax_treatment\\\": \\\"exclusive\\\",\\n    \\\"issued_at\\\": \\\"2015-11-23\\\",\\n    \\\"received_at\\\": null,\\n    \\\"total\\\": \\\"8.63\\\",\\n    \\\"tags\\\": [\\n\\n],\\n    \\\"cached_quantity\\\": \\\"3.0\\\",\\n    \\\"cached_total\\\": \\\"8.63\\\",\\n    \\\"default_price_type_id\\\": \\\"buy\\\",\\n    \\\"tax_type\\\": \\\"exclusive\\\",\\n    \\\"purchase_order_line_item_ids\\\": [\\n      3,\\n      2\\n    ],\\n    \\\"procurement_ids\\\": [\\n\\n]\\n  }\\n}\\nCreates a new purchase_order object.\\nThis endpoint also accepts embedded purchase_order_line_items.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nstatus\\nString\\n\\n\\n\\n\\nbilling_address_id\\nInteger\\nThe billing address for the purchase_order.\\n\\n\\n\\ncompany_id\\nInteger\\nThe company that will be supplying the purchase order\\ntrue\\n\\n\\ncurrency_id\\nInteger\\nThe currency of the purchase_order\\n\\n\\n\\nstock_location_id\\nInteger\\nThe stock location where stock will be delivered\\n\\n\\n\\nsupplier_address_id\\nInteger\\nThe supplier address for the purchase_order.\\n\\n\\n\\ndefault_price_list_id\\nString\\nDefault prices for the purchase_order_line_items (if the variant has a price on this Price List\\n\\n\\n\\ndue_at\\nString\\nDefaults to 14 days from creation\\ntrue\\n\\n\\nemail\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\norder_number\\nString\\n\\n\\n\\n\\npayment_due_at\\nString\\nDefaults to 14 days from creation\\ntrue\\n\\n\\nprocurement_status\\nString\\n\\n\\n\\n\\nreference_number\\nString\\nA reference for the purchase order that isn't the order_number\\n\\n\\n\\ntax_treatment\\nString\\nOne of 'exclusive' or 'inclusive', if not provided defaults to account default.\\ntrue\\n\\n\\nissued_at\\nString\\nDate when purchase was issued.\\ntrue\\n\\n\\nreceived_at\\nString\\n\\n\\n\\n\\ntotal\\nString\\n\\n\\n\\n\\ntags\\nString\\nReference tags for the purchase order, used in filtering.\\n\\n\\n\\ncached_quantity\\nString\\n\\n\\n\\n\\ncached_total deprecated\\nString\\n\\n\\n\\n\\ndefault_price_type_id deprecated\\nString\\n\\n\\n\\n\\ntax_type deprecated\\nString\\n\\n\\n\\nPurchaseOrderLineItem\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\npurchase_order_id\\nInteger\\nThe purchase_order to which the purchase_order_line_item belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the purchase_order_line_item belongs.\\ntrue\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the purchase_order_line_item belongs.\\ntrue\\n\\n\\nprocurement_id\\nInteger\\nIf it has been received, the procurement object this purchase_order_line_item belongs.\\n\\n\\n\\nbase_price\\nString\\n\\n\\n\\n\\nfreeform\\nBoolean\\n\\n\\n\\n\\nimage_url\\nString\\n\\n\\n\\n\\nlabel\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\n\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\ntax_rate_override\\nString\\nOptional tax rate override\\n\\n\\n\\nextra_cost_value\\nString\\n\\n\\n\\n\\ntax_rate deprecated\\nString\\nDeprecated in favour of tax_rate_override\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/purchase_orders/\"},{\"id\":\"retrieve-a-particular-purchase_order\",\"title\":\"Retrieve a particular purchase_order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.PurchaseOrder.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_orders/1\\n{\\n  \\\"purchase_order\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-23T11:19:49.857Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-23T11:19:50.427Z\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"document_url\\\": \\\"http://localhost:3000/d/gfPPrlS40mrZOGXXgmOIZcue\\\",\\n    \\\"billing_address_id\\\": 1,\\n    \\\"company_id\\\": 3,\\n    \\\"currency_id\\\": 1,\\n    \\\"stock_location_id\\\": 1,\\n    \\\"supplier_address_id\\\": 4,\\n    \\\"default_price_list_id\\\": \\\"buy\\\",\\n    \\\"due_at\\\": \\\"2015-12-07\\\",\\n    \\\"email\\\": \\\"william@example.com\\\",\\n    \\\"notes\\\": null,\\n    \\\"order_number\\\": \\\"PO0002\\\",\\n    \\\"payment_due_at\\\": \\\"2015-12-07\\\",\\n    \\\"procurement_status\\\": \\\"unprocured\\\",\\n    \\\"reference_number\\\": null,\\n    \\\"tax_treatment\\\": \\\"exclusive\\\",\\n    \\\"issued_at\\\": \\\"2015-11-23\\\",\\n    \\\"received_at\\\": null,\\n    \\\"total\\\": \\\"8.63\\\",\\n    \\\"tags\\\": [\\n\\n],\\n    \\\"cached_quantity\\\": \\\"3.0\\\",\\n    \\\"cached_total\\\": \\\"8.63\\\",\\n    \\\"default_price_type_id\\\": \\\"buy\\\",\\n    \\\"tax_type\\\": \\\"exclusive\\\",\\n    \\\"purchase_order_line_item_ids\\\": [\\n      3,\\n      2\\n    ],\\n    \\\"procurement_ids\\\": [\\n\\n]\\n  }\\n}\\nRetrieves the details of an existing purchase_order. You need only supply the unique purchase_order identifier that was returned upon purchase_order creation.HTTP RequestGET https://api.tradegecko.com/purchase_orders/{RESOURCE_ID}\"},{\"id\":\"update-a-purchase_order\",\"title\":\"Update a purchase_order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npurchase_order = gecko.PurchaseOrder.find(1)\\npurchase_order.attributes = {\\n  status: \\\"active\\\",\\n  email: \\\"hello@tradegecko.com\\\",\\n  billing_address_id: 2\\n}\\npurchase_order.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_orders/1 -d '{\\\"purchase_order\\\":{\\\"status\\\":\\\"active\\\",\\\"email\\\":\\\"hello@tradegecko.com\\\",\\\"billing_address_id\\\":2}}'\\n\\nResponse\\n\\nReturns 204 status when the purchase_order gets updated successfully.\\n\\nUpdates the specified purchase_order by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the purchase_order creation call.HTTP RequestPUT https://api.tradegecko.com/purchase_orders/{RESOURCE_ID}\"},{\"id\":\"purchase-order-actions\",\"title\":\"Purchase Order actions\",\"body\":\"Use the following endpoints to manage the receiving of the purchase order. POST /purchase_orders/[:purchase_order_id]/actions/[:action]curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_orders/[:purchase_order_id]/actions/[:purchase_order_action]\\n\\n\\nAction\\nDescription\\n\\n\\n\\nreceive\\nCreate a procurement for the purchase order\\n\\n\"},{\"id\":\"delete-a-purchase_order\",\"title\":\"Delete a purchase_order\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npurchase_order = gecko.PurchaseOrder.find(1)\\npurchase_order.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_orders/1\\n\\nResponse\\n\\nReturns 204 status when the purchase_order gets deleted successfully.\\n\\nPermanently deletes a purchase_order. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/purchase_orders/{RESOURCE_ID}/\"},{\"id\":\"purchaseorderlineitem\",\"title\":\"PurchaseOrderLineItem\",\"body\":\"This is an object representing a purchase_order_line_item of a purchase_order. Purchase_orders can\\n  have multiple purchase_order_line_items but a purchase_order_line_item object belongs to only one\\n  Purchase_order.\"},{\"id\":\"the-purchaseorderlineitem-object\",\"title\":\"The PurchaseOrderLineItem object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\npurchase_order_id\\nInteger\\nThe purchase_order to which the purchase_order_line_item belongs.\\n\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the purchase_order_line_item belongs.\\n\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the purchase_order_line_item belongs.\\n\\n\\n\\nprocurement_id\\nInteger\\nIf it has been received, the procurement object this purchase_order_line_item belongs.\\ntrue\\n\\n\\nbase_price\\nString\\n\\ntrue\\n\\n\\nfreeform\\nBoolean\\n\\n\\n\\n\\nimage_url\\nString\\n\\ntrue\\n\\n\\nlabel\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\n\\n\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\ntax_rate_override\\nString\\nOptional tax rate override\\n\\n\\n\\nextra_cost_value\\nString\\n\\ntrue\\n\\n\\ntax_rate  deprecated\\nString\\nDeprecated in favour of tax_rate_override\\n\\n\\n\"},{\"id\":\"list-all-purchase_order_line_items\",\"title\":\"List all purchase_order_line_items\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.PurchaseOrderLineItem.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_order_line_items/\\n{\\n  \\\"purchase_order_line_items\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2015-11-23T11:19:50.405Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-23T11:19:50.405Z\\\",\\n      \\\"procurement_id\\\": null,\\n      \\\"purchase_order_id\\\": 2,\\n      \\\"tax_type_id\\\": 3,\\n      \\\"variant_id\\\": 8,\\n      \\\"base_price\\\": null,\\n      \\\"freeform\\\": false,\\n      \\\"image_url\\\": null,\\n      \\\"label\\\": null,\\n      \\\"position\\\": 0,\\n      \\\"price\\\": \\\"2.5\\\",\\n      \\\"quantity\\\": \\\"2.0\\\",\\n      \\\"tax_rate_override\\\": null,\\n      \\\"extra_cost_value\\\": \\\"0.0\\\",\\n      \\\"tax_rate\\\": null\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-23T11:19:07.469Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-23T11:19:07.469Z\\\",\\n      \\\"procurement_id\\\": null,\\n      \\\"purchase_order_id\\\": 1,\\n      \\\"tax_type_id\\\": 3,\\n      \\\"variant_id\\\": 8,\\n      \\\"base_price\\\": null,\\n      \\\"freeform\\\": false,\\n      \\\"image_url\\\": null,\\n      \\\"label\\\": null,\\n      \\\"position\\\": 0,\\n      \\\"price\\\": \\\"2.5\\\",\\n      \\\"quantity\\\": \\\"1.0\\\",\\n      \\\"tax_rate_override\\\": null,\\n      \\\"extra_cost_value\\\": \\\"0.0\\\",\\n      \\\"tax_rate\\\": null\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-23T11:19:50.297Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-23T11:19:50.297Z\\\",\\n      \\\"procurement_id\\\": null,\\n      \\\"purchase_order_id\\\": 2,\\n      \\\"tax_type_id\\\": 3,\\n      \\\"variant_id\\\": 9,\\n      \\\"base_price\\\": null,\\n      \\\"freeform\\\": false,\\n      \\\"image_url\\\": null,\\n      \\\"label\\\": null,\\n      \\\"position\\\": 1,\\n      \\\"price\\\": \\\"2.5\\\",\\n      \\\"quantity\\\": \\\"1.0\\\",\\n      \\\"tax_rate_override\\\": null,\\n      \\\"extra_cost_value\\\": \\\"0.0\\\",\\n      \\\"tax_rate\\\": null\\n    }\\n  ]\\n}\\nReturns a list of purchase_order_line_items you’ve previously created. The purchase_order_line_items are returned in sorted order, with the most recent purchase_order_line_items appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of purchase_order_line_item IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\npurchase_order_id\\nFilter purchase_order_line_items by order\\n\\n\\nvariant_id\\nFilter purchase_order_line_items by variant\\n\\n\\ntax_type_id\\nFilter purchase_order_line_items by tax_type\\n\\n\\nprocurement_id\\nFilter purchase_order_line_items by procurement\\n\\n\\npurchase_order_status\\nFilter purchase_order_line_items by purchase order status\\n\\nHTTP Request:GET  https://api.tradegecko.com/purchase_order_line_items\"},{\"id\":\"create-a-new-purchase_order_line_item\",\"title\":\"Create a new purchase_order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npurchase_order_line_item = gecko.PurchaseOrderLineItem.build({\\n  quantity: \\\"12.0\\\",\\n  order_id: 1,\\n  tax_type_id: 1,\\n  price: \\\"10.0\\\"\\n})\\npurchase_order_line_item.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_order_line_items/ -d '{\\\"purchase_order_line_item\\\":{\\\"quantity\\\":\\\"12.0\\\",\\\"order_id\\\":1,\\\"tax_type_id\\\":1,\\\"price\\\":\\\"10.0\\\"}}'\\n{\\n  \\\"purchase_order_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-23T11:19:50.405Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-23T11:19:50.405Z\\\",\\n    \\\"procurement_id\\\": null,\\n    \\\"purchase_order_id\\\": 2,\\n    \\\"tax_type_id\\\": 3,\\n    \\\"variant_id\\\": 8,\\n    \\\"base_price\\\": null,\\n    \\\"freeform\\\": false,\\n    \\\"image_url\\\": null,\\n    \\\"label\\\": null,\\n    \\\"position\\\": 0,\\n    \\\"price\\\": \\\"2.5\\\",\\n    \\\"quantity\\\": \\\"2.0\\\",\\n    \\\"tax_rate_override\\\": null,\\n    \\\"extra_cost_value\\\": \\\"0.0\\\",\\n    \\\"tax_rate\\\": null\\n  }\\n}\\nCreates a new purchase_order_line_item object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\npurchase_order_id\\nInteger\\nThe purchase_order to which the purchase_order_line_item belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the purchase_order_line_item belongs.\\ntrue\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the purchase_order_line_item belongs.\\ntrue\\n\\n\\nprocurement_id\\nInteger\\nIf it has been received, the procurement object this purchase_order_line_item belongs.\\n\\n\\n\\nbase_price\\nString\\n\\n\\n\\n\\nfreeform\\nBoolean\\n\\n\\n\\n\\nimage_url\\nString\\n\\n\\n\\n\\nlabel\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\n\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\ntax_rate_override\\nString\\nOptional tax rate override\\n\\n\\n\\nextra_cost_value\\nString\\n\\n\\n\\n\\ntax_rate deprecated\\nString\\nDeprecated in favour of tax_rate_override\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/purchase_order_line_items/\"},{\"id\":\"retrieve-a-particular-purchase_order_line_item\",\"title\":\"Retrieve a particular purchase_order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.PurchaseOrderLineItem.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_order_line_items/1\\n{\\n  \\\"purchase_order_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-23T11:19:50.405Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-23T11:19:50.405Z\\\",\\n    \\\"procurement_id\\\": null,\\n    \\\"purchase_order_id\\\": 2,\\n    \\\"tax_type_id\\\": 3,\\n    \\\"variant_id\\\": 8,\\n    \\\"base_price\\\": null,\\n    \\\"freeform\\\": false,\\n    \\\"image_url\\\": null,\\n    \\\"label\\\": null,\\n    \\\"position\\\": 0,\\n    \\\"price\\\": \\\"2.5\\\",\\n    \\\"quantity\\\": \\\"2.0\\\",\\n    \\\"tax_rate_override\\\": null,\\n    \\\"extra_cost_value\\\": \\\"0.0\\\",\\n    \\\"tax_rate\\\": null\\n  }\\n}\\nRetrieves the details of an existing purchase_order_line_item. You need only supply the unique purchase_order_line_item identifier that was returned upon purchase_order_line_item creation.HTTP RequestGET https://api.tradegecko.com/purchase_order_line_items/{RESOURCE_ID}\"},{\"id\":\"update-a-purchase_order_line_item\",\"title\":\"Update a purchase_order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npurchase_order_line_item = gecko.PurchaseOrderLineItem.find(1)\\npurchase_order_line_item.attributes = {\\n  quantity: \\\"22.0\\\",\\n  price: \\\"12.0\\\"\\n}\\npurchase_order_line_item.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_order_line_items/1 -d '{\\\"purchase_order_line_item\\\":{\\\"quantity\\\":\\\"22.0\\\",\\\"price\\\":\\\"12.0\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the purchase_order_line_item gets updated successfully.\\n\\nUpdates the specified purchase_order_line_item by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the purchase_order_line_item creation call.HTTP RequestPUT https://api.tradegecko.com/purchase_order_line_items/{RESOURCE_ID}\"},{\"id\":\"delete-a-purchase_order_line_item\",\"title\":\"Delete a purchase_order_line_item\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\npurchase_order_line_item = gecko.PurchaseOrderLineItem.find(1)\\npurchase_order_line_item.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/purchase_order_line_items/1\\n\\nResponse\\n\\nReturns 204 status when the purchase_order_line_item gets deleted successfully.\\n\\nPermanently deletes a purchase_order_line_item. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/purchase_order_line_items/{RESOURCE_ID}/\"},{\"id\":\"stockadjustment\",\"title\":\"StockAdjustment\",\"body\":\"This is an object representing a stock_adjustment.\"},{\"id\":\"the-stockadjustment-object\",\"title\":\"The StockAdjustment object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nadjustment_number\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\nreason\\nString\\nOne of supplier (New Products), customer (Returned goods), damaged, shrinkage, promotion or production.\\n\\n\\n\\nreason_label\\nString\\nDisplay label of the stock adjustment's reason (unifies the reason and stock_adjustment_reason_id fields)\\n\\n\\n\\nstock_adjustment_reason_id\\nInteger\\nInternal ID of Custom stock adjustment reasons. See https://go.tradegecko.com/account/stock_adjustment_reasons for your accounts reasons\\n\\n\\n\\nstock_location_id\\nInteger\\nDefaults to account primary_location.\\n\\n\\n\\ncached_quantity\\nString\\nCumulative quantity of all variants being adjusted\\ntrue\\n\\n\\ncached_total\\nString\\nCumulative value of all variants being adjusted\\ntrue\\n\\n\\nstock_adjustment_line_item_ids\\nArray\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-stock_adjustments\",\"title\":\"List all stock_adjustments\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_adjustments/\\n{\\n  \\\"stock_adjustments\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-25T07:27:39.813Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-25T07:27:40.176Z\\\",\\n      \\\"adjustment_number\\\": \\\"SA0002\\\",\\n      \\\"notes\\\": \\\"Reversal of Stock Adjustment #SA0001\\\",\\n      \\\"reason\\\": \\\"damaged\\\",\\n      \\\"stock_location_id\\\": 1,\\n      \\\"cached_quantity\\\": \\\"-15.0\\\",\\n      \\\"cached_total\\\": \\\"37.5\\\",\\n      \\\"stock_adjustment_line_item_ids\\\": [\\n        3,\\n        4\\n      ]\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-25T07:27:20.194Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-25T07:27:20.740Z\\\",\\n      \\\"adjustment_number\\\": \\\"SA0001\\\",\\n      \\\"notes\\\": null,\\n      \\\"reason\\\": \\\"production\\\",\\n      \\\"stock_location_id\\\": 1,\\n      \\\"cached_quantity\\\": \\\"25.0\\\",\\n      \\\"cached_total\\\": \\\"62.5\\\",\\n      \\\"stock_adjustment_line_item_ids\\\": [\\n        1,\\n        2\\n      ]\\n    }\\n  ]\\n}\\nReturns a list of stock_adjustments you’ve previously created. The stock_adjustments are returned in sorted order, with the most recent stock_adjustments appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of stock_adjustment IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nadjustment_number\\n\\n\\n\\nstock_adjustment_reason_id\\n\\n\\n\\nstock_location_id\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/stock_adjustments\"},{\"id\":\"create-a-new-stock_adjustment\",\"title\":\"Create a new stock_adjustment\",\"body\":\"curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_adjustments/ -d '{\\\"stock_adjustment\\\":{\\\"company_id\\\":1,\\\"issued_at\\\":\\\"2015-11-25T07:27:39.813Z\\\",\\\"billing_address_id\\\":1,\\\"shipping_address_id\\\":1}}'\\n{\\n  \\\"stock_adjustment\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-25T07:27:39.813Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-25T07:27:40.176Z\\\",\\n    \\\"adjustment_number\\\": \\\"SA0002\\\",\\n    \\\"notes\\\": \\\"Reversal of Stock Adjustment #SA0001\\\",\\n    \\\"reason\\\": \\\"damaged\\\",\\n    \\\"stock_location_id\\\": 1,\\n    \\\"cached_quantity\\\": \\\"-15.0\\\",\\n    \\\"cached_total\\\": \\\"37.5\\\",\\n    \\\"stock_adjustment_line_item_ids\\\": [\\n      3,\\n      4\\n    ]\\n  }\\n}\\nCreates a new stock_adjustment object.\\nThis endpoint also accepts embedded stock_adjustment_line_items.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nadjustment_number\\nString\\n\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\nreason\\nString\\nOne of supplier (New Products), customer (Returned goods), damaged, shrinkage, promotion or production.\\n\\n\\nStockAdjustmentLineItem\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nstock_adjustment_id\\nInteger\\nThe stock_adjustment to which the resource belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the resource belongs.\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\nRequired only when quantity is greater than 0. For negative quantities, the current Moving Average Cost will be assigned automatically.\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/stock_adjustments/\"},{\"id\":\"retrieve-a-particular-stock_adjustment\",\"title\":\"Retrieve a particular stock_adjustment\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_adjustments/\\n{\\n  \\\"stock_adjustment\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-25T07:27:39.813Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-25T07:27:40.176Z\\\",\\n    \\\"adjustment_number\\\": \\\"SA0002\\\",\\n    \\\"notes\\\": \\\"Reversal of Stock Adjustment #SA0001\\\",\\n    \\\"reason\\\": \\\"damaged\\\",\\n    \\\"stock_location_id\\\": 1,\\n    \\\"cached_quantity\\\": \\\"-15.0\\\",\\n    \\\"cached_total\\\": \\\"37.5\\\",\\n    \\\"stock_adjustment_line_item_ids\\\": [\\n      3,\\n      4\\n    ]\\n  }\\n}\\nRetrieves the details of an existing stock_adjustment. You need only supply the unique stock_adjustment identifier that was returned upon stock_adjustment creation.HTTP RequestGET https://api.tradegecko.com/stock_adjustments/{RESOURCE_ID}\"},{\"id\":\"delete-a-stock_adjustment\",\"title\":\"Delete a stock_adjustment\",\"body\":\"curl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_adjustments/1\\n\\nResponse\\n\\nReturns 204 status when the stock_adjustment gets deleted successfully.\\n\\nPermanently deletes a stock_adjustment. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/stock_adjustments/{RESOURCE_ID}/\"},{\"id\":\"stockadjustmentlineitem\",\"title\":\"StockAdjustmentLineItem\",\"body\":\"This is an object representing a stock_adjustment_line_item of a stock_adjustment. Stock_adjustments can\\n  have multiple stock_adjustment_line_items but a stock_adjustment_line_item object belongs to only one\\n  Stock_adjustment.\"},{\"id\":\"the-stockadjustmentlineitem-object\",\"title\":\"The StockAdjustmentLineItem object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstock_adjustment_id\\nInteger\\nThe stock_adjustment to which the resource belongs.\\n\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the resource belongs.\\n\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\nRequired only when quantity is greater than 0. For negative quantities, the current Moving Average Cost will be assigned automatically.\\n\\n\\n\"},{\"id\":\"list-all-stock_adjustment_line_items\",\"title\":\"List all stock_adjustment_line_items\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_adjustment_line_items/\\n{\\n  \\\"stock_adjustment_line_items\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2015-11-25T07:27:39.967Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-25T07:27:39.967Z\\\",\\n      \\\"stock_adjustment_id\\\": 2,\\n      \\\"variant_id\\\": 8,\\n      \\\"quantity\\\": \\\"-5.0\\\",\\n      \\\"position\\\": 0,\\n      \\\"price\\\": \\\"2.5\\\"\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-25T07:27:20.464Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-25T07:27:20.464Z\\\",\\n      \\\"stock_adjustment_id\\\": 1,\\n      \\\"variant_id\\\": 8,\\n      \\\"quantity\\\": \\\"10.0\\\",\\n      \\\"position\\\": 0,\\n      \\\"price\\\": \\\"2.5\\\"\\n    },\\n    {\\n      \\\"id\\\": 4,\\n      \\\"created_at\\\": \\\"2015-11-25T07:27:40.136Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-25T07:27:40.136Z\\\",\\n      \\\"stock_adjustment_id\\\": 2,\\n      \\\"variant_id\\\": 9,\\n      \\\"quantity\\\": \\\"-10.0\\\",\\n      \\\"position\\\": 1,\\n      \\\"price\\\": \\\"2.5\\\"\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-25T07:27:20.697Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-25T07:27:20.697Z\\\",\\n      \\\"stock_adjustment_id\\\": 1,\\n      \\\"variant_id\\\": 9,\\n      \\\"quantity\\\": \\\"15.0\\\",\\n      \\\"position\\\": 1,\\n      \\\"price\\\": \\\"2.5\\\"\\n    }\\n  ]\\n}\\nReturns a list of stock_adjustment_line_items you’ve previously created. The stock_adjustment_line_items are returned in sorted order, with the most recent stock_adjustment_line_items appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of stock_adjustment_line_item IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstock_adjustment_id\\nFilter resources by stock_adjustment\\n\\n\\nvariant_id\\nFilter resources by variant\\n\\nHTTP Request:GET  https://api.tradegecko.com/stock_adjustment_line_items\"},{\"id\":\"create-a-new-stock_adjustment_line_item\",\"title\":\"Create a new stock_adjustment_line_item\",\"body\":\"curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_adjustment_line_items/ -d '{\\\"stock_adjustment_line_item\\\":{\\\"quantity\\\":\\\"12.0\\\",\\\"stock_adjustment_id\\\":1,\\\"variant_id\\\":1,\\\"price\\\":\\\"10.0\\\"}}'\\n{\\n  \\\"stock_adjustment_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-25T07:27:39.967Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-25T07:27:39.967Z\\\",\\n    \\\"stock_adjustment_id\\\": 2,\\n    \\\"variant_id\\\": 8,\\n    \\\"quantity\\\": \\\"-5.0\\\",\\n    \\\"position\\\": 0,\\n    \\\"price\\\": \\\"2.5\\\"\\n  }\\n}\\nCreates a new stock_adjustment_line_item object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nstock_adjustment_id\\nInteger\\nThe stock_adjustment to which the resource belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the resource belongs.\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nprice\\nString\\nRequired only when quantity is greater than 0. For negative quantities, the current Moving Average Cost will be assigned automatically.\\ntrue\\n\\nHTTP RequestPOST https://api.tradegecko.com/stock_adjustment_line_items/\"},{\"id\":\"retrieve-a-particular-stock_adjustment_line_item\",\"title\":\"Retrieve a particular stock_adjustment_line_item\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_adjustment_line_items/\\n{\\n  \\\"stock_adjustment_line_item\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-25T07:27:39.967Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-25T07:27:39.967Z\\\",\\n    \\\"stock_adjustment_id\\\": 2,\\n    \\\"variant_id\\\": 8,\\n    \\\"quantity\\\": \\\"-5.0\\\",\\n    \\\"position\\\": 0,\\n    \\\"price\\\": \\\"2.5\\\"\\n  }\\n}\\nRetrieves the details of an existing stock_adjustment_line_item. You need only supply the unique stock_adjustment_line_item identifier that was returned upon stock_adjustment_line_item creation.HTTP RequestGET https://api.tradegecko.com/stock_adjustment_line_items/{RESOURCE_ID}\"},{\"id\":\"stocklevel\",\"title\":\"StockLevel\",\"body\":\"This is an object representing a stock_level.\"},{\"id\":\"the-stocklevel-object\",\"title\":\"The StockLevel object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncommitted_stock\\nString\\nStock committed for sale across all locations\\ntrue\\n\\n\\nlocations\\nArray\\nAn array of per-warehouse data about current variant.\\ntrue\\n\\n\\nstock_on_hand\\nString\\nStock on hand across all locations\\ntrue\\n\\n\\nincoming_stock\\nString\\nStock on order across all locations\\ntrue\\n\\n\"},{\"id\":\"list-all-stock_levels\",\"title\":\"List all stock_levels\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.StockLevel.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_levels/\\n{\\n  \\\"stock_levels\\\": [\\n    {\\n      \\\"variant_id\\\": 60,\\n      \\\"committed_stock\\\": \\\"5\\\",\\n      \\\"locations\\\": [\\n        {\\n          \\\"location_id\\\": 3,\\n          \\\"committed\\\": \\\"5\\\",\\n          \\\"incoming\\\": 0,\\n          \\\"stock_on_hand\\\": \\\"30\\\"\\n        }\\n      ],\\n      \\\"stock_on_hand\\\": \\\"30\\\",\\n      \\\"incoming_stock\\\": \\\"0\\\"\\n    },\\n    {\\n      \\\"variant_id\\\": 43,\\n      \\\"committed_stock\\\": \\\"0\\\",\\n      \\\"locations\\\": [\\n        {\\n          \\\"location_id\\\": 3,\\n          \\\"committed\\\": 0,\\n          \\\"incoming\\\": 0,\\n          \\\"stock_on_hand\\\": \\\"75\\\"\\n        }\\n      ],\\n      \\\"stock_on_hand\\\": \\\"75\\\",\\n      \\\"incoming_stock\\\": \\\"0\\\"\\n    }\\n  ]\\n}\\nReturns a list of stock_levels you’ve previously created. The stock_levels are returned in sorted order, with the most recent stock_levels appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of stock_level IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\nHTTP Request:GET  https://api.tradegecko.com/stock_levels\"},{\"id\":\"retrieve-a-particular-stock_level\",\"title\":\"Retrieve a particular stock_level\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.StockLevel.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_levels/1\\n{\\n  \\\"stock_level\\\": {\\n    \\\"variant_id\\\": 60,\\n    \\\"committed_stock\\\": \\\"5\\\",\\n    \\\"locations\\\": [\\n      {\\n        \\\"location_id\\\": 3,\\n        \\\"committed\\\": \\\"5\\\",\\n        \\\"incoming\\\": 0,\\n        \\\"stock_on_hand\\\": \\\"30\\\"\\n      }\\n    ],\\n    \\\"stock_on_hand\\\": \\\"30\\\",\\n    \\\"incoming_stock\\\": \\\"0\\\"\\n  }\\n}\\nRetrieves the details of an existing stock_level. You need only supply the unique stock_level identifier that was returned upon stock_level creation.HTTP RequestGET https://api.tradegecko.com/stock_levels/{RESOURCE_ID}\"},{\"id\":\"stocktransfer\",\"title\":\"StockTransfer\",\"body\":\"This is an object representing a stock_transfer.\"},{\"id\":\"the-stocktransfer-object\",\"title\":\"The StockTransfer object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'received'\\n\\n\\n\\nadjustment_number\\nString\\n\\n\\n\\n\\nreceived_at\\nString\\nAutomatically set when stock transfer status is set to received\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\nsource_location_id\\nInteger\\nOrigin of stock being tranferred\\n\\n\\n\\ndestination_location_id\\nInteger\\nDestination of stock being transferred\\n\\n\\n\\ncached_quantity\\nString\\nCumulative quantity of all variants being transferred\\ntrue\\n\\n\\ntransacted_at\\nString\\n\\n\\n\\n\\nstock_transfer_line_item_ids\\nArray\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-stock_transfers\",\"title\":\"List all stock_transfers\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfers/\\n{\\n  \\\"stock_transfers\\\": [\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-26T04:14:45.572Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-26T04:14:45.606Z\\\",\\n      \\\"adjustment_number\\\": \\\"ST0002\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"received_at\\\": null,\\n      \\\"notes\\\": \\\"Reversal of Stock Transfer #ST0001\\\",\\n      \\\"source_location_id\\\": 3,\\n      \\\"destination_location_id\\\": 1,\\n      \\\"cached_quantity\\\": \\\"8.0\\\",\\n      \\\"transacted_at\\\": null,\\n      \\\"stock_transfer_line_item_ids\\\": [\\n        3,\\n        4\\n      ]\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-26T03:53:17.729Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-26T03:53:21.760Z\\\",\\n      \\\"adjustment_number\\\": \\\"ST0001\\\",\\n      \\\"status\\\": \\\"received\\\",\\n      \\\"received_at\\\": \\\"2015-11-26T03:52:51.000Z\\\",\\n      \\\"notes\\\": null,\\n      \\\"source_location_id\\\": 1,\\n      \\\"destination_location_id\\\": 3,\\n      \\\"cached_quantity\\\": \\\"17.0\\\",\\n      \\\"transacted_at\\\": \\\"2015-11-26T03:52:51.000Z\\\",\\n      \\\"stock_transfer_line_item_ids\\\": [\\n        1,\\n        2\\n      ]\\n    }\\n  ]\\n}\\nReturns a list of stock_transfers you’ve previously created. The stock_transfers are returned in sorted order, with the most recent stock_transfers appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of stock_transfer IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\n\\nstatus\\n\\n\\n\\nadjustment_number\\n\\n\\n\\nreceived_at\\n\\n\\n\\nnotes\\n\\n\\n\\nsource_location_id\\n\\n\\n\\ndestination_location_id\\n\\n\\n\\ncached_quantity\\n\\n\\n\\ntransacted_at\\n\\n\\n\\nstock_transfer_line_item_ids\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/stock_transfers\"},{\"id\":\"create-a-new-stock_transfer\",\"title\":\"Create a new stock_transfer\",\"body\":\"curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfers/ -d '{\\\"stock_transfer\\\":{\\\"company_id\\\":1,\\\"issued_at\\\":\\\"2015-11-26T03:53:17.729Z\\\",\\\"billing_address_id\\\":1,\\\"shipping_address_id\\\":1}}'\\n{\\n  \\\"stock_transfer\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-26T04:14:45.572Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-26T04:14:45.606Z\\\",\\n    \\\"adjustment_number\\\": \\\"ST0002\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"received_at\\\": null,\\n    \\\"notes\\\": \\\"Reversal of Stock Transfer #ST0001\\\",\\n    \\\"source_location_id\\\": 3,\\n    \\\"destination_location_id\\\": 1,\\n    \\\"cached_quantity\\\": \\\"8.0\\\",\\n    \\\"transacted_at\\\": null,\\n    \\\"stock_transfer_line_item_ids\\\": [\\n      3,\\n      4\\n    ]\\n  }\\n}\\nCreates a new stock_transfer object.\\nThis endpoint also accepts embedded stock_transfer_line_items.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'received'\\n\\n\\n\\nadjustment_number\\nString\\n\\n\\n\\n\\nreceived_at\\nString\\nAutomatically set when stock transfer status is set to received\\n\\n\\n\\nnotes\\nString\\n\\n\\n\\n\\nsource_location_id\\nInteger\\nOrigin of stock being tranferred\\ntrue\\n\\n\\ndestination_location_id\\nInteger\\nDestination of stock being transferred\\ntrue\\n\\n\\ntransacted_at\\nString\\n\\n\\n\\n\\nstock_transfer_line_item_ids\\nArray\\n\\n\\n\\nStockTransferLineItem\\n\\nChild Attribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nstock_transfer_id\\nInteger\\nThe stock_transfer to which the resource belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the resource belongs.\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nimage_url\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/stock_transfers/\"},{\"id\":\"retrieve-a-particular-stock_transfer\",\"title\":\"Retrieve a particular stock_transfer\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfers/\\n{\\n  \\\"stock_transfer\\\": {\\n    \\\"id\\\": 2,\\n    \\\"created_at\\\": \\\"2015-11-26T04:14:45.572Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-26T04:14:45.606Z\\\",\\n    \\\"adjustment_number\\\": \\\"ST0002\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"received_at\\\": null,\\n    \\\"notes\\\": \\\"Reversal of Stock Transfer #ST0001\\\",\\n    \\\"source_location_id\\\": 3,\\n    \\\"destination_location_id\\\": 1,\\n    \\\"cached_quantity\\\": \\\"8.0\\\",\\n    \\\"transacted_at\\\": null,\\n    \\\"stock_transfer_line_item_ids\\\": [\\n      3,\\n      4\\n    ]\\n  }\\n}\\nRetrieves the details of an existing stock_transfer. You need only supply the unique stock_transfer identifier that was returned upon stock_transfer creation.HTTP RequestGET https://api.tradegecko.com/stock_transfers/{RESOURCE_ID}\"},{\"id\":\"stock-transfer-actions\",\"title\":\"Stock Transfer actions\",\"body\":\"Use the following endpoints to manage the receiving or reverting of the stock transfer. POST /stock_transfers/[:stock_transfer_id]/actions/[:action]curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfers/[:stock_transfer_id]/actions/[:stock_transfer_action]\\n\\n\\nAction\\nDescription\\n\\n\\n\\nreceive\\nReceive the stock transfer\\n\\n\\nrevert\\nRevert the stock transfer\\n\\n\"},{\"id\":\"delete-a-stock_transfer\",\"title\":\"Delete a stock_transfer\",\"body\":\"curl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfers/1\\n\\nResponse\\n\\nReturns 204 status when the stock_transfer gets deleted successfully.\\n\\nPermanently deletes a stock_transfer. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/stock_transfers/{RESOURCE_ID}/\"},{\"id\":\"stocktransferlineitem\",\"title\":\"StockTransferLineItem\",\"body\":\"This is an object representing a stock_transfer_line_item of a stock_transfer. Stock_transfers can\\n  have multiple stock_transfer_line_items but a stock_transfer_line_item object belongs to only one\\n  Stock_transfer.\"},{\"id\":\"the-stocktransferlineitem-object\",\"title\":\"The StockTransferLineItem object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstock_transfer_id\\nInteger\\nThe stock_transfer to which the resource belongs.\\n\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the resource belongs.\\n\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nimage_url\\nString\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-stock_transfer_line_items\",\"title\":\"List all stock_transfer_line_items\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfer_line_items/\\n{\\n  \\\"stock_transfer_line_items\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-26T03:53:17.761Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-26T03:53:17.761Z\\\",\\n      \\\"stock_transfer_id\\\": 1,\\n      \\\"variant_id\\\": 8,\\n      \\\"quantity\\\": \\\"8.0\\\",\\n      \\\"position\\\": 0,\\n      \\\"image_url\\\": null\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-26T03:53:17.775Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-26T03:53:17.775Z\\\",\\n      \\\"stock_transfer_id\\\": 1,\\n      \\\"variant_id\\\": 9,\\n      \\\"quantity\\\": \\\"9.0\\\",\\n      \\\"position\\\": 1,\\n      \\\"image_url\\\": null\\n    }\\n  ]\\n}\\nReturns a list of stock_transfer_line_items you’ve previously created. The stock_transfer_line_items are returned in sorted order, with the most recent stock_transfer_line_items appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of stock_transfer_line_item IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstock_transfer_id\\nFilter resources by stock_transfer\\n\\n\\nvariant_id\\nFilter resources by variant\\n\\nHTTP Request:GET  https://api.tradegecko.com/stock_transfer_line_items\"},{\"id\":\"create-a-new-stock_transfer_line_item\",\"title\":\"Create a new stock_transfer_line_item\",\"body\":\"curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfer_line_items/ -d '{\\\"stock_transfer_line_item\\\":{\\\"quantity\\\":\\\"12.0\\\",\\\"stock_transfer_id\\\":1,\\\"variant_id\\\":1,\\\"price\\\":\\\"10.0\\\"}}'\\n{\\n  \\\"stock_transfer_line_item\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-26T03:53:17.761Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-26T03:53:17.761Z\\\",\\n    \\\"stock_transfer_id\\\": 1,\\n    \\\"variant_id\\\": 8,\\n    \\\"quantity\\\": \\\"8.0\\\",\\n    \\\"position\\\": 0,\\n    \\\"image_url\\\": null\\n  }\\n}\\nCreates a new stock_transfer_line_item object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nstock_transfer_id\\nInteger\\nThe stock_transfer to which the resource belongs.\\ntrue\\n\\n\\nvariant_id\\nInteger\\nThe variant to which the resource belongs.\\ntrue\\n\\n\\nquantity\\nString\\n\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nimage_url\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/stock_transfer_line_items/\"},{\"id\":\"retrieve-a-particular-stock_transfer_line_item\",\"title\":\"Retrieve a particular stock_transfer_line_item\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfer_line_items/\\n{\\n  \\\"stock_transfer_line_item\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-26T03:53:17.761Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-26T03:53:17.761Z\\\",\\n    \\\"stock_transfer_id\\\": 1,\\n    \\\"variant_id\\\": 8,\\n    \\\"quantity\\\": \\\"8.0\\\",\\n    \\\"position\\\": 0,\\n    \\\"image_url\\\": null\\n  }\\n}\\nRetrieves the details of an existing stock_transfer_line_item. You need only supply the unique stock_transfer_line_item identifier that was returned upon stock_transfer_line_item creation.HTTP RequestGET https://api.tradegecko.com/stock_transfer_line_items/{RESOURCE_ID}\"},{\"id\":\"delete-a-stock_transfer_line_item\",\"title\":\"Delete a stock_transfer_line_item\",\"body\":\"curl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/stock_transfer_line_items/1\\n\\nResponse\\n\\nReturns 204 status when the stock_transfer_line_item gets deleted successfully.\\n\\nPermanently deletes a stock_transfer_line_item. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/stock_transfer_line_items/{RESOURCE_ID}/\"},{\"id\":\"taxtype\",\"title\":\"TaxType\",\"body\":\"This is an object representing a tax_type.\"},{\"id\":\"the-taxtype-object\",\"title\":\"The TaxType object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'\\ntrue\\n\\n\\ncode\\nString\\n\\n\\n\\n\\nimported_from\\nString\\nSource location (e.g. Quickbooks)\\ntrue\\n\\n\\nname\\nString\\nDisplay name\\n\\n\\n\\neffective_rate\\nString\\nComputed rate of child tax_components\\ntrue\\n\\n\\ntax_components\\nArray\\nAn array of Tax Components that the tax rate is composed of\\n\\n\\n\"},{\"id\":\"list-all-tax_types\",\"title\":\"List all tax_types\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.TaxType.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_types/\\n{\\n  \\\"tax_types\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"code\\\": \\\"RETAIL\\\",\\n      \\\"imported_from\\\": null,\\n      \\\"name\\\": \\\"Retail\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"quickbooks_online_id\\\": null,\\n      \\\"xero_online_id\\\": null,\\n      \\\"effective_rate\\\": \\\"10.0\\\",\\n      \\\"tax_component_ids\\\": [\\n        3\\n      ]\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"code\\\": \\\"SALES\\\",\\n      \\\"imported_from\\\": null,\\n      \\\"name\\\": \\\"Sales Tax\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"quickbooks_online_id\\\": null,\\n      \\\"xero_online_id\\\": null,\\n      \\\"effective_rate\\\": \\\"15.0\\\",\\n      \\\"tax_component_ids\\\": [\\n        2\\n      ]\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"code\\\": \\\"TAX EXEMPT\\\",\\n      \\\"imported_from\\\": null,\\n      \\\"name\\\": \\\"Tax Exempt\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"quickbooks_online_id\\\": null,\\n      \\\"xero_online_id\\\": null,\\n      \\\"effective_rate\\\": \\\"0.0\\\",\\n      \\\"tax_component_ids\\\": [\\n        1\\n      ]\\n    }\\n  ]\\n}\\nReturns a list of tax_types you’ve previously created. The tax_types are returned in sorted order, with the most recent tax_types appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of tax_type IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\nHTTP Request:GET  https://api.tradegecko.com/tax_types\"},{\"id\":\"create-a-new-tax_type\",\"title\":\"Create a new tax_type\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ntax_type = gecko.TaxType.build({\\n  name: \\\"Retail\\\",\\n  code: \\\"RETAIL\\\",\\n  tax_components: [\\n    {\\n      position: 0,\\n      label: \\\"Retail GST\\\",\\n      rate: 10,\\n      compound: false\\n    }\\n  ]\\n})\\ntax_type.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_types/ -d '{\\\"tax_type\\\":{\\\"name\\\":\\\"Retail\\\",\\\"code\\\":\\\"RETAIL\\\",\\\"tax_components\\\":[{\\\"position\\\":0,\\\"label\\\":\\\"Retail GST\\\",\\\"rate\\\":10,\\\"compound\\\":false}]}}'\\n{\\n  \\\"tax_type\\\": {\\n    \\\"id\\\": 3,\\n    \\\"code\\\": \\\"RETAIL\\\",\\n    \\\"imported_from\\\": null,\\n    \\\"name\\\": \\\"Retail\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"quickbooks_online_id\\\": null,\\n    \\\"xero_online_id\\\": null,\\n    \\\"effective_rate\\\": \\\"10.0\\\",\\n    \\\"tax_component_ids\\\": [\\n      3\\n    ]\\n  }\\n}\\nCreates a new tax_type object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ncode\\nString\\n\\n\\n\\n\\nname\\nString\\nDisplay name\\ntrue\\n\\n\\ntax_components\\nArray\\nAn array of Tax Components that the tax rate is composed of\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/tax_types/\"},{\"id\":\"retrieve-a-particular-tax_type\",\"title\":\"Retrieve a particular tax_type\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.TaxType.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_types/1\\n{\\n  \\\"tax_type\\\": {\\n    \\\"id\\\": 3,\\n    \\\"code\\\": \\\"RETAIL\\\",\\n    \\\"imported_from\\\": null,\\n    \\\"name\\\": \\\"Retail\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"quickbooks_online_id\\\": null,\\n    \\\"xero_online_id\\\": null,\\n    \\\"effective_rate\\\": \\\"10.0\\\",\\n    \\\"tax_component_ids\\\": [\\n      3\\n    ]\\n  }\\n}\\nRetrieves the details of an existing tax_type. You need only supply the unique tax_type identifier that was returned upon tax_type creation.HTTP RequestGET https://api.tradegecko.com/tax_types/{RESOURCE_ID}\"},{\"id\":\"update-a-tax_type\",\"title\":\"Update a tax_type\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ntax_type = gecko.TaxType.find(1)\\ntax_type.attributes = {\\n  name: \\\"Wholesale\\\",\\n  code: \\\"WHOLESALE\\\"\\n}\\ntax_type.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_types/1 -d '{\\\"tax_type\\\":{\\\"name\\\":\\\"Wholesale\\\",\\\"code\\\":\\\"WHOLESALE\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the tax_type gets updated successfully.\\n\\nUpdates the specified tax_type by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the tax_type creation call.HTTP RequestPUT https://api.tradegecko.com/tax_types/{RESOURCE_ID}\"},{\"id\":\"delete-a-tax_type\",\"title\":\"Delete a tax_type\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ntax_type = gecko.TaxType.find(1)\\ntax_type.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_types/1\\n\\nResponse\\n\\nReturns 204 status when the tax_type gets deleted successfully.\\n\\nPermanently deletes a tax_type. It cannot be undone.\\n  This tax_type will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/tax_types/{RESOURCE_ID}/\"},{\"id\":\"taxcomponent\",\"title\":\"TaxComponent\",\"body\":\"This is an object representing a tax_component of a tax_type. Tax_types can\\n  have multiple tax_components but a tax_component object belongs to only one\\n  Tax_type.\"},{\"id\":\"the-taxcomponent-object\",\"title\":\"The TaxComponent object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the tax_component belongs.\\n\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nlabel\\nString\\nDisplay name\\n\\n\\n\\nrate\\nString\\nTax Rate\\n\\n\\n\\ncompound\\nString\\n\\n\\n\\n\"},{\"id\":\"list-all-tax_components\",\"title\":\"List all tax_components\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_components/\\n{\\n  \\\"tax_components\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"tax_type_id\\\": 3,\\n      \\\"position\\\": 1,\\n      \\\"label\\\": \\\"GST\\\",\\n      \\\"rate\\\": \\\"15.0\\\"\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"tax_type_id\\\": 2,\\n      \\\"position\\\": 1,\\n      \\\"label\\\": \\\"GST\\\",\\n      \\\"rate\\\": \\\"15.0\\\"\\n    },\\n    {\\n      \\\"id\\\": 1,\\n      \\\"tax_type_id\\\": 1,\\n      \\\"position\\\": 1,\\n      \\\"label\\\": \\\"GST\\\",\\n      \\\"rate\\\": \\\"0.0\\\"\\n    }\\n  ]\\n}\\nReturns a list of tax_components you’ve previously created. The tax_components are returned in sorted order, with the most recent tax_components appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of tax_component IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ntax_type_id\\n\\n\\n\\nposition\\n\\n\\n\\nlabel\\n\\n\\n\\nrate\\n\\n\\n\\ncompound\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/tax_components\"},{\"id\":\"create-a-new-tax_component\",\"title\":\"Create a new tax_component\",\"body\":\"curl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_components/ -d '{\\\"tax_component\\\":{\\\"quantity\\\":\\\"12.0\\\",\\\"order_id\\\":1,\\\"tax_type_id\\\":1,\\\"price\\\":\\\"10.0\\\"}}'\\n{\\n  \\\"tax_component\\\": {\\n    \\\"id\\\": 3,\\n    \\\"tax_type_id\\\": 3,\\n    \\\"position\\\": 1,\\n    \\\"label\\\": \\\"GST\\\",\\n    \\\"rate\\\": \\\"15.0\\\"\\n  }\\n}\\nCreates a new tax_component object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\ntax_type_id\\nInteger\\nThe tax_type to which the tax_component belongs.\\ntrue\\n\\n\\nposition\\nInteger\\n\\n\\n\\n\\nlabel\\nString\\nDisplay name\\n\\n\\n\\nrate\\nString\\nTax Rate\\n\\n\\n\\ncompound\\nString\\n\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/tax_components/\"},{\"id\":\"retrieve-a-particular-tax_component\",\"title\":\"Retrieve a particular tax_component\",\"body\":\"curl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_components/\\n{\\n  \\\"tax_component\\\": {\\n    \\\"id\\\": 3,\\n    \\\"tax_type_id\\\": 3,\\n    \\\"position\\\": 1,\\n    \\\"label\\\": \\\"GST\\\",\\n    \\\"rate\\\": \\\"15.0\\\"\\n  }\\n}\\nRetrieves the details of an existing tax_component. You need only supply the unique tax_component identifier that was returned upon tax_component creation.HTTP RequestGET https://api.tradegecko.com/tax_components/{RESOURCE_ID}\"},{\"id\":\"update-a-tax_component\",\"title\":\"Update a tax_component\",\"body\":\"curl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com//1 -d '{\\\"tax_component\\\":{\\\"quantity\\\":\\\"22.0\\\",\\\"price\\\":\\\"12.0\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the tax_component gets updated successfully.\\n\\nUpdates the specified tax_component by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the tax_component creation call.HTTP RequestPUT https://api.tradegecko.com//{RESOURCE_ID}\"},{\"id\":\"delete-a-tax_component\",\"title\":\"Delete a tax_component\",\"body\":\"curl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/tax_components/1\\n\\nResponse\\n\\nReturns 204 status when the tax_component gets deleted successfully.\\n\\nPermanently deletes a tax_component. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/tax_components/{RESOURCE_ID}/\"},{\"id\":\"user\",\"title\":\"User\",\"body\":\"This is an object representing a user.\"},{\"id\":\"the-user-object\",\"title\":\"The User object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'\\ntrue\\n\\n\\naction_items_email\\nString\\nFrequency of action items email [off, daily, weekly]\\n\\n\\n\\navatar_url\\nString\\nThis image is not processed (so it accepts gifs!)\\n\\n\\n\\nbilling_contact\\nBoolean\\nTells whether user is billing_contact for the current account\\n\\n\\n\\nemail\\nString\\n\\n\\n\\n\\nfirst_name\\nString\\n\\n\\n\\n\\nlast_name\\nString\\n\\n\\n\\n\\nlast_sign_in_at\\nString\\n\\n\\n\\n\\nlocation\\nString\\n\\n\\n\\n\\nlogin_id\\nInteger\\nThe current login identifier.\\ntrue\\n\\n\\nmobile\\nString\\n\\n\\n\\n\\nnotification_email\\nBoolean\\n\\n\\n\\n\\npermissions\\nArray\\nPermissions available to user.\\n\\n\\n\\nphone_number\\nString\\n\\n\\n\\n\\nposition\\nString\\nRole in the company\\n\\n\\n\\nsales_report_email\\nBoolean\\n\\n\\n\\n\\naccount_id\\nString\\nThe current account identifier.\\ntrue\\n\\n\"},{\"id\":\"list-all-users\",\"title\":\"List all users\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.User.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/users/\\n{\\n  \\\"users\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:23.877Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:22:23.920Z\\\",\\n      \\\"action_items_email\\\": \\\"weekly\\\",\\n      \\\"avatar_url\\\": \\\"/assets/avatars/avatar1-70fa2b37c7341a16d9ef72fc6b0f961c253965e9c395fc063ad0165bc65b7167.png\\\",\\n      \\\"billing_contact\\\": true,\\n      \\\"email\\\": \\\"example@tradegecko.com\\\",\\n      \\\"first_name\\\": \\\"Gordon\\\",\\n      \\\"last_name\\\": \\\"Gecko\\\",\\n      \\\"last_sign_in_at\\\": \\\"2015-11-17T06:35:25.521Z\\\",\\n      \\\"location\\\": null,\\n      \\\"login_id\\\": 1,\\n      \\\"mobile\\\": null,\\n      \\\"notification_email\\\": true,\\n      \\\"permissions\\\": [\\n        \\\"read_reports\\\",\\n        \\\"write_stocks\\\",\\n        \\\"write_orders\\\",\\n        \\\"write_products\\\",\\n        \\\"write_settings\\\",\\n        \\\"write_companies\\\",\\n        \\\"read_buy_prices\\\"\\n      ],\\n      \\\"phone_number\\\": null,\\n      \\\"position\\\": null,\\n      \\\"sales_report_email\\\": true,\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"account_id\\\": 1\\n    }\\n  ]\\n}\\nReturns a list of users you’ve previously created. The users are returned in sorted order, with the most recent users appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of user IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\n\\nlogin_id\\n\\n\\n\\naccount_id\\n\\n\\nHTTP Request:GET  https://api.tradegecko.com/users\"},{\"id\":\"retrieve-a-particular-user\",\"title\":\"Retrieve a particular user\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.User.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/users/1\\n{\\n  \\\"user\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:23.877Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:23.920Z\\\",\\n    \\\"action_items_email\\\": \\\"weekly\\\",\\n    \\\"avatar_url\\\": \\\"/assets/avatars/avatar1-70fa2b37c7341a16d9ef72fc6b0f961c253965e9c395fc063ad0165bc65b7167.png\\\",\\n    \\\"billing_contact\\\": true,\\n    \\\"email\\\": \\\"example@tradegecko.com\\\",\\n    \\\"first_name\\\": \\\"Gordon\\\",\\n    \\\"last_name\\\": \\\"Gecko\\\",\\n    \\\"last_sign_in_at\\\": \\\"2015-11-17T06:35:25.521Z\\\",\\n    \\\"location\\\": null,\\n    \\\"login_id\\\": 1,\\n    \\\"mobile\\\": null,\\n    \\\"notification_email\\\": true,\\n    \\\"permissions\\\": [\\n      \\\"read_reports\\\",\\n      \\\"write_stocks\\\",\\n      \\\"write_orders\\\",\\n      \\\"write_products\\\",\\n      \\\"write_settings\\\",\\n      \\\"write_companies\\\",\\n      \\\"read_buy_prices\\\"\\n    ],\\n    \\\"phone_number\\\": null,\\n    \\\"position\\\": null,\\n    \\\"sales_report_email\\\": true,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"account_id\\\": 1\\n  }\\n}\\nRetrieves the details of an existing user. You need only supply the unique user identifier that was returned upon user creation.HTTP RequestGET https://api.tradegecko.com/users/{RESOURCE_ID}\"},{\"id\":\"get-current-user\",\"title\":\"Get current user\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.User.current\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/users/current\\n{\\n  \\\"user\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:23.877Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:22:23.920Z\\\",\\n    \\\"action_items_email\\\": \\\"weekly\\\",\\n    \\\"avatar_url\\\": \\\"/assets/avatars/avatar1-70fa2b37c7341a16d9ef72fc6b0f961c253965e9c395fc063ad0165bc65b7167.png\\\",\\n    \\\"billing_contact\\\": true,\\n    \\\"email\\\": \\\"example@tradegecko.com\\\",\\n    \\\"first_name\\\": \\\"Gordon\\\",\\n    \\\"last_name\\\": \\\"Gecko\\\",\\n    \\\"last_sign_in_at\\\": \\\"2015-11-17T06:35:25.521Z\\\",\\n    \\\"location\\\": null,\\n    \\\"login_id\\\": 1,\\n    \\\"mobile\\\": null,\\n    \\\"notification_email\\\": true,\\n    \\\"permissions\\\": [\\n      \\\"read_reports\\\",\\n      \\\"write_stocks\\\",\\n      \\\"write_orders\\\",\\n      \\\"write_products\\\",\\n      \\\"write_settings\\\",\\n      \\\"write_companies\\\",\\n      \\\"read_buy_prices\\\"\\n    ],\\n    \\\"phone_number\\\": null,\\n    \\\"position\\\": null,\\n    \\\"sales_report_email\\\": true,\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"account_id\\\": 1\\n  }\\n}\\nRetrieves the details of the current user.HTTP RequestGET https://api.tradegecko.com/users/current\"},{\"id\":\"update-a-user\",\"title\":\"Update a user\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nuser = gecko.User.find(1)\\nuser.attributes = {\\n  first_name: \\\"Gordon\\\"\\n}\\nuser.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/users/1 -d '{\\\"user\\\":{\\\"first_name\\\":\\\"Gordon\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the user gets updated successfully.\\n\\nUpdates the specified user by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the user creation call.HTTP RequestPUT https://api.tradegecko.com/users/{RESOURCE_ID}\"},{\"id\":\"delete-a-user\",\"title\":\"Delete a user\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nuser = gecko.User.find(1)\\nuser.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/users/1\\n\\nResponse\\n\\nReturns 204 status when the user gets deleted successfully.\\n\\nPermanently deletes a user. It cannot be undone.\\n  This user will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/users/{RESOURCE_ID}/\"},{\"id\":\"variant\",\"title\":\"Variant\",\"body\":\"This is an object representing a variant of a product. Products can\\n  have multiple variants but a variant object belongs to only one\\n  Product.\"},{\"id\":\"the-variant-object\",\"title\":\"The Variant object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\n\\ntrue\\n\\n\\nupdated_at\\nString\\n\\ntrue\\n\\n\\nstatus\\nString\\nTells whether the resource is 'active' or 'archived'\\ntrue\\n\\n\\nproduct_id\\nInteger\\nThe product to which the variant belongs.\\n\\n\\n\\ndefault_ledger_account_id\\nInteger\\nUsed for accounting integrations. (e.g. Revenue Ledger)\\n\\n\\n\\nbuy_price\\nString\\n\\n\\n\\n\\ncommitted_stock\\nString\\nStock committed for sale across all locations\\ntrue\\n\\n\\nincoming_stock\\nString\\nStock on order across all locations\\ntrue\\n\\n\\ncomposite\\nBoolean\\nTells whether this variant is a composite (composed of other variants)\\n\\n\\n\\ndescription\\nString\\n\\n\\n\\n\\nhs_code\\nString\\nHarmonized System Code\\n\\n\\n\\ncountry_of_origin\\nString\\nTwo letter country code (e.g. SG, US)\\n\\n\\n\\ninitial_cost_price\\nString\\nThe initial item cost price of the variant, only available when first creating the variant\\n\\n\\n\\ninitial_stock_level\\nString\\nThe initial stock level of the variant, only available when first creating the variant\\n\\n\\n\\ninitial_stock_location_id\\nInteger\\nThe ID of the stock location where initial stock levels should be added, only available when first creating the variant, defaults to your primary stock location\\n\\n\\n\\nkeep_selling\\nBoolean\\nAllow item to continue to be sold, even if it is no longer in stock\\n\\n\\n\\nlast_cost_price\\nString\\nLast purchase price paid for this variant\\ntrue\\n\\n\\nmanage_stock\\nBoolean\\nFor composite variants, the value of manage_stock will always be true\\n\\n\\n\\nmax_online\\nString\\nIntegrated online store(s) should show current stock levels up to a maximum of this value\\n\\n\\n\\nmoving_average_cost\\nString\\nAverage cost price paid for this variant\\ntrue\\n\\n\\nname\\nString\\n\\n\\n\\n\\nonline_ordering\\nBoolean\\nTells whether variant is for sale on B2B platform\\n\\n\\n\\nopt1\\nString\\n\\n\\n\\n\\nopt2\\nString\\n\\n\\n\\n\\nopt3\\nString\\n\\n\\n\\n\\nposition\\nString\\nDefault sort position of this variant (unique to product)\\n\\n\\n\\nproduct_name\\nString\\nprovided by the product to which the variant belongs\\ntrue\\n\\n\\nproduct_status\\nString\\nprovided by the product to which the variant belongs\\ntrue\\n\\n\\nproduct_type\\nString\\nprovided by the product to which the variant belongs\\ntrue\\n\\n\\npurchasable\\nBoolean\\nTells whether you can create Purchase Order with the variant\\n\\n\\n\\nretail_price\\nString\\nThe recommended retail price\\n\\n\\n\\nsellable\\nString\\nTells whether can be added to sales orders\\n\\n\\n\\nsku\\nString\\nStock Keeping Unit (should be unique)\\n\\n\\n\\nstock_on_hand\\nString\\nStock on hand across all locations\\ntrue\\n\\n\\nsupplier_code\\nString\\n\\n\\n\\n\\ntaxable\\nBoolean\\nTells whether this variant can be taxed\\n\\n\\n\\nupc\\nString\\nThe barcode or UPC number\\n\\n\\n\\nweight\\nString\\nThe weight value\\n\\n\\n\\nweight_unit\\nString\\nThe weight unit (kg, g, oz or lb)\\n\\n\\n\\nwholesale_price\\nString\\nThe recommended wholesale price for this product\\n\\n\\n\\nimage_ids\\nArray\\nImages assigned to the variant. The order of the Image IDs here is the position of the images on the variant.\\n\\n\\n\\nvariant_prices\\nArray\\nAn array of prices with price list IDs and the price value.\\n\\n\\n\\nlocations\\nArray\\nAn array of per-warehouse data about current variant.\\ntrue\\n\\n\\nprices  deprecated\\nHash\\n\\ntrue\\n\\n\\nstock_levels  deprecated\\nHash\\n\\ntrue\\n\\n\\ncommitted_stock_levels  deprecated\\nHash\\n\\ntrue\\n\\n\"},{\"id\":\"list-all-variants\",\"title\":\"List all variants\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Variant.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/variants/\\n{\\n  \\\"variants\\\": [\\n    {\\n      \\\"id\\\": 3,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.772Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:34:04.502Z\\\",\\n      \\\"product_id\\\": 1,\\n      \\\"default_ledger_account_id\\\": null,\\n      \\\"buy_price\\\": \\\"4.5\\\",\\n      \\\"committed_stock\\\": \\\"3\\\",\\n      \\\"incoming_stock\\\": \\\"0\\\",\\n      \\\"hs_code\\\": \\\"110100\\\",\\n      \\\"country_of_origin\\\": \\\"SG\\\",\\n      \\\"composite\\\": null,\\n      \\\"description\\\": null,\\n      \\\"keep_selling\\\": false,\\n      \\\"last_cost_price\\\": \\\"5.0\\\",\\n      \\\"manage_stock\\\": true,\\n      \\\"max_online\\\": null,\\n      \\\"moving_average_cost\\\": \\\"5\\\",\\n      \\\"name\\\": \\\"Peach\\\",\\n      \\\"online_ordering\\\": true,\\n      \\\"opt1\\\": \\\"Peach\\\",\\n      \\\"opt2\\\": null,\\n      \\\"opt3\\\": null,\\n      \\\"position\\\": 2,\\n      \\\"product_name\\\": \\\"Everlasting Gobstopper\\\",\\n      \\\"product_status\\\": \\\"active\\\",\\n      \\\"product_type\\\": \\\"Candy\\\",\\n      \\\"retail_price\\\": \\\"22.0\\\",\\n      \\\"sellable\\\": true,\\n      \\\"sku\\\": \\\"DEMO-GOBS-PEA\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"stock_on_hand\\\": \\\"10\\\",\\n      \\\"supplier_code\\\": null,\\n      \\\"taxable\\\": true,\\n      \\\"upc\\\": null,\\n      \\\"weight\\\": null,\\n      \\\"weight_unit\\\": null,\\n      \\\"weight_value\\\": null,\\n      \\\"wholesale_price\\\": \\\"12.0\\\",\\n      \\\"image_ids\\\": [\\n\\n],\\n      \\\"variant_prices\\\": [\\n        {\\n          \\\"price_list_id\\\": \\\"retail\\\",\\n          \\\"value\\\": \\\"22.0\\\"\\n        },\\n        {\\n          \\\"price_list_id\\\": \\\"wholesale\\\",\\n          \\\"value\\\": \\\"12.0\\\"\\n        },\\n        {\\n          \\\"price_list_id\\\": \\\"buy\\\",\\n          \\\"value\\\": \\\"4.5\\\"\\n        }\\n      ],\\n      \\\"locations\\\": [\\n        {\\n          \\\"location_id\\\": 1,\\n          \\\"stock_on_hand\\\": \\\"10\\\",\\n          \\\"committed\\\": \\\"3\\\",\\n          \\\"incoming\\\": null,\\n          \\\"bin_location\\\": null,\\n          \\\"reorder_point\\\": null\\n        }\\n      ],\\n      \\\"prices\\\": {\\n        \\\"retail\\\": \\\"22.0\\\",\\n        \\\"wholesale\\\": \\\"12.0\\\",\\n        \\\"buy\\\": \\\"4.5\\\"\\n      },\\n      \\\"stock_levels\\\": {\\n        \\\"1\\\": \\\"10.0\\\"\\n      },\\n      \\\"committed_stock_levels\\\": {\\n        \\\"1\\\": \\\"3.0\\\"\\n      }\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2015-11-02T01:22:24.796Z\\\",\\n      \\\"updated_at\\\": \\\"2015-11-02T01:34:04.474Z\\\",\\n      \\\"product_id\\\": 1,\\n      \\\"default_ledger_account_id\\\": null,\\n      \\\"buy_price\\\": \\\"4.5\\\",\\n      \\\"committed_stock\\\": \\\"0\\\",\\n      \\\"incoming_stock\\\": \\\"0\\\",\\n      \\\"hs_code\\\": \\\"110100\\\",\\n      \\\"country_of_origin\\\": \\\"SG\\\",\\n      \\\"composite\\\": null,\\n      \\\"description\\\": null,\\n      \\\"keep_selling\\\": false,\\n      \\\"last_cost_price\\\": \\\"6.0\\\",\\n      \\\"manage_stock\\\": true,\\n      \\\"max_online\\\": null,\\n      \\\"moving_average_cost\\\": \\\"6\\\",\\n      \\\"name\\\": \\\"Snozzberry\\\",\\n      \\\"online_ordering\\\": true,\\n      \\\"opt1\\\": \\\"Snozzberry\\\",\\n      \\\"opt2\\\": null,\\n      \\\"opt3\\\": null,\\n      \\\"position\\\": 3,\\n      \\\"product_name\\\": \\\"Everlasting Gobstopper\\\",\\n      \\\"product_status\\\": \\\"active\\\",\\n      \\\"product_type\\\": \\\"Candy\\\",\\n      \\\"retail_price\\\": \\\"24.0\\\",\\n      \\\"sellable\\\": true,\\n      \\\"sku\\\": \\\"DEMO-GOBS-SNO\\\",\\n      \\\"status\\\": \\\"active\\\",\\n      \\\"stock_on_hand\\\": \\\"10\\\",\\n      \\\"supplier_code\\\": null,\\n      \\\"taxable\\\": true,\\n      \\\"upc\\\": null,\\n      \\\"weight\\\": null,\\n      \\\"weight_unit\\\": null,\\n      \\\"weight_value\\\": null,\\n      \\\"wholesale_price\\\": \\\"12.0\\\",\\n      \\\"image_ids\\\": [\\n\\n],\\n      \\\"variant_prices\\\": [\\n        {\\n          \\\"price_list_id\\\": \\\"retail\\\",\\n          \\\"value\\\": \\\"24.0\\\"\\n        },\\n        {\\n          \\\"price_list_id\\\": \\\"wholesale\\\",\\n          \\\"value\\\": \\\"12.0\\\"\\n        },\\n        {\\n          \\\"price_list_id\\\": \\\"buy\\\",\\n          \\\"value\\\": \\\"4.5\\\"\\n        }\\n      ],\\n      \\\"locations\\\": [\\n        {\\n          \\\"location_id\\\": 1,\\n          \\\"stock_on_hand\\\": \\\"10\\\",\\n          \\\"committed\\\": null,\\n          \\\"incoming\\\": null,\\n          \\\"bin_location\\\": null,\\n          \\\"reorder_point\\\": null\\n        }\\n      ],\\n      \\\"prices\\\": {\\n        \\\"retail\\\": \\\"24.0\\\",\\n        \\\"wholesale\\\": \\\"12.0\\\",\\n        \\\"buy\\\": \\\"4.5\\\"\\n      },\\n      \\\"stock_levels\\\": {\\n        \\\"1\\\": 10\\n      },\\n      \\\"committed_stock_levels\\\": {\\n      }\\n    }\\n  ]\\n}\\nReturns a list of variants you’ve previously created. The variants are returned in sorted order, with the most recent variants appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of variant IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nstatus\\nDefault is active\\n\\n\\nproduct_id\\n\\n\\n\\nsku\\nfind product variant by SKU\\n\\nHTTP Request:GET  https://api.tradegecko.com/variants\"},{\"id\":\"create-a-new-variant\",\"title\":\"Create a new variant\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nvariant = gecko.Variant.build({\\n  product_id: 1,\\n  initial_cost_price: 25,\\n  initial_stock_level: 100,\\n  initial_stock_location_id: 1,\\n  retail_price: \\\"10.0\\\",\\n  name: \\\"Sample Variant\\\",\\n  sku: \\\"SV1234\\\"\\n})\\nvariant.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/variants/ -d '{\\\"variant\\\":{\\\"product_id\\\":1,\\\"initial_cost_price\\\":25,\\\"initial_stock_level\\\":100,\\\"initial_stock_location_id\\\":1,\\\"retail_price\\\":\\\"10.0\\\",\\\"name\\\":\\\"Sample Variant\\\",\\\"sku\\\":\\\"SV1234\\\"}}'\\n{\\n  \\\"variant\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:24.772Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:34:04.502Z\\\",\\n    \\\"product_id\\\": 1,\\n    \\\"default_ledger_account_id\\\": null,\\n    \\\"buy_price\\\": \\\"4.5\\\",\\n    \\\"committed_stock\\\": \\\"3\\\",\\n    \\\"incoming_stock\\\": \\\"0\\\",\\n    \\\"hs_code\\\": \\\"110100\\\",\\n    \\\"country_of_origin\\\": \\\"SG\\\",\\n    \\\"composite\\\": null,\\n    \\\"description\\\": null,\\n    \\\"keep_selling\\\": false,\\n    \\\"last_cost_price\\\": \\\"5.0\\\",\\n    \\\"manage_stock\\\": true,\\n    \\\"max_online\\\": null,\\n    \\\"moving_average_cost\\\": \\\"5\\\",\\n    \\\"name\\\": \\\"Peach\\\",\\n    \\\"online_ordering\\\": true,\\n    \\\"opt1\\\": \\\"Peach\\\",\\n    \\\"opt2\\\": null,\\n    \\\"opt3\\\": null,\\n    \\\"position\\\": 2,\\n    \\\"product_name\\\": \\\"Everlasting Gobstopper\\\",\\n    \\\"product_status\\\": \\\"active\\\",\\n    \\\"product_type\\\": \\\"Candy\\\",\\n    \\\"retail_price\\\": \\\"22.0\\\",\\n    \\\"sellable\\\": true,\\n    \\\"sku\\\": \\\"DEMO-GOBS-PEA\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"stock_on_hand\\\": \\\"10\\\",\\n    \\\"supplier_code\\\": null,\\n    \\\"taxable\\\": true,\\n    \\\"upc\\\": null,\\n    \\\"weight\\\": null,\\n    \\\"weight_unit\\\": null,\\n    \\\"weight_value\\\": null,\\n    \\\"wholesale_price\\\": \\\"12.0\\\",\\n    \\\"image_ids\\\": [\\n\\n],\\n    \\\"variant_prices\\\": [\\n      {\\n        \\\"price_list_id\\\": \\\"retail\\\",\\n        \\\"value\\\": \\\"22.0\\\"\\n      },\\n      {\\n        \\\"price_list_id\\\": \\\"wholesale\\\",\\n        \\\"value\\\": \\\"12.0\\\"\\n      },\\n      {\\n        \\\"price_list_id\\\": \\\"buy\\\",\\n        \\\"value\\\": \\\"4.5\\\"\\n      }\\n    ],\\n    \\\"locations\\\": [\\n      {\\n        \\\"location_id\\\": 1,\\n        \\\"stock_on_hand\\\": \\\"10\\\",\\n        \\\"committed\\\": \\\"3\\\",\\n        \\\"incoming\\\": null,\\n        \\\"bin_location\\\": null,\\n        \\\"reorder_point\\\": null\\n      }\\n    ],\\n    \\\"prices\\\": {\\n      \\\"retail\\\": \\\"22.0\\\",\\n      \\\"wholesale\\\": \\\"12.0\\\",\\n      \\\"buy\\\": \\\"4.5\\\"\\n    },\\n    \\\"stock_levels\\\": {\\n      \\\"1\\\": \\\"10.0\\\"\\n    },\\n    \\\"committed_stock_levels\\\": {\\n      \\\"1\\\": \\\"3.0\\\"\\n    }\\n  }\\n}\\nCreates a new variant object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nproduct_id\\nInteger\\nThe product to which the variant belongs.\\ntrue\\n\\n\\ndefault_ledger_account_id\\nInteger\\nUsed for accounting integrations. (e.g. Revenue Ledger)\\n\\n\\n\\nbuy_price\\nString\\n\\n\\n\\n\\ncomposite\\nBoolean\\nTells whether this variant is a composite (composed of other variants)\\n\\n\\n\\ndescription\\nString\\n\\n\\n\\n\\nhs_code\\nString\\nHarmonized System Code\\n\\n\\n\\ncountry_of_origin\\nString\\nTwo letter country code (e.g. SG, US)\\n\\n\\n\\ninitial_cost_price\\nString\\nThe initial item cost price of the variant, only available when first creating the variant\\n\\n\\n\\ninitial_stock_level\\nString\\nThe initial stock level of the variant, only available when first creating the variant\\n\\n\\n\\ninitial_stock_location_id\\nInteger\\nThe ID of the stock location where initial stock levels should be added, only available when first creating the variant, defaults to your primary stock location\\n\\n\\n\\nkeep_selling\\nBoolean\\nAllow item to continue to be sold, even if it is no longer in stock\\n\\n\\n\\nmanage_stock\\nBoolean\\nFor composite variants, the value of manage_stock will always be true\\n\\n\\n\\nmax_online\\nString\\nIntegrated online store(s) should show current stock levels up to a maximum of this value\\n\\n\\n\\nname\\nString\\n\\n\\n\\n\\nonline_ordering\\nBoolean\\nTells whether variant is for sale on B2B platform\\n\\n\\n\\nopt1\\nString\\n\\n\\n\\n\\nopt2\\nString\\n\\n\\n\\n\\nopt3\\nString\\n\\n\\n\\n\\nposition\\nString\\nDefault sort position of this variant (unique to product)\\n\\n\\n\\npurchasable\\nBoolean\\nTells whether you can create Purchase Order with the variant\\n\\n\\n\\nretail_price\\nString\\nThe recommended retail price\\n\\n\\n\\nsellable\\nString\\nTells whether can be added to sales orders\\n\\n\\n\\nsku\\nString\\nStock Keeping Unit (should be unique)\\n\\n\\n\\nsupplier_code\\nString\\n\\n\\n\\n\\ntaxable\\nBoolean\\nTells whether this variant can be taxed\\n\\n\\n\\nupc\\nString\\nThe barcode or UPC number\\n\\n\\n\\nweight\\nString\\nThe weight value\\n\\n\\n\\nweight_unit\\nString\\nThe weight unit (kg, g, oz or lb)\\n\\n\\n\\nwholesale_price\\nString\\nThe recommended wholesale price for this product\\n\\n\\n\\nimage_ids\\nArray\\nImages assigned to the variant. The order of the Image IDs here is the position of the images on the variant.\\n\\n\\n\\nvariant_prices\\nArray\\nAn array of prices with price list IDs and the price value.\\n\\n\\nHTTP RequestPOST https://api.tradegecko.com/variants/\"},{\"id\":\"retrieve-a-particular-variant\",\"title\":\"Retrieve a particular variant\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Variant.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/variants/1\\n{\\n  \\\"variant\\\": {\\n    \\\"id\\\": 3,\\n    \\\"created_at\\\": \\\"2015-11-02T01:22:24.772Z\\\",\\n    \\\"updated_at\\\": \\\"2015-11-02T01:34:04.502Z\\\",\\n    \\\"product_id\\\": 1,\\n    \\\"default_ledger_account_id\\\": null,\\n    \\\"buy_price\\\": \\\"4.5\\\",\\n    \\\"committed_stock\\\": \\\"3\\\",\\n    \\\"incoming_stock\\\": \\\"0\\\",\\n    \\\"hs_code\\\": \\\"110100\\\",\\n    \\\"country_of_origin\\\": \\\"SG\\\",\\n    \\\"composite\\\": null,\\n    \\\"description\\\": null,\\n    \\\"keep_selling\\\": false,\\n    \\\"last_cost_price\\\": \\\"5.0\\\",\\n    \\\"manage_stock\\\": true,\\n    \\\"max_online\\\": null,\\n    \\\"moving_average_cost\\\": \\\"5\\\",\\n    \\\"name\\\": \\\"Peach\\\",\\n    \\\"online_ordering\\\": true,\\n    \\\"opt1\\\": \\\"Peach\\\",\\n    \\\"opt2\\\": null,\\n    \\\"opt3\\\": null,\\n    \\\"position\\\": 2,\\n    \\\"product_name\\\": \\\"Everlasting Gobstopper\\\",\\n    \\\"product_status\\\": \\\"active\\\",\\n    \\\"product_type\\\": \\\"Candy\\\",\\n    \\\"retail_price\\\": \\\"22.0\\\",\\n    \\\"sellable\\\": true,\\n    \\\"sku\\\": \\\"DEMO-GOBS-PEA\\\",\\n    \\\"status\\\": \\\"active\\\",\\n    \\\"stock_on_hand\\\": \\\"10\\\",\\n    \\\"supplier_code\\\": null,\\n    \\\"taxable\\\": true,\\n    \\\"upc\\\": null,\\n    \\\"weight\\\": null,\\n    \\\"weight_unit\\\": null,\\n    \\\"weight_value\\\": null,\\n    \\\"wholesale_price\\\": \\\"12.0\\\",\\n    \\\"image_ids\\\": [\\n\\n],\\n    \\\"variant_prices\\\": [\\n      {\\n        \\\"price_list_id\\\": \\\"retail\\\",\\n        \\\"value\\\": \\\"22.0\\\"\\n      },\\n      {\\n        \\\"price_list_id\\\": \\\"wholesale\\\",\\n        \\\"value\\\": \\\"12.0\\\"\\n      },\\n      {\\n        \\\"price_list_id\\\": \\\"buy\\\",\\n        \\\"value\\\": \\\"4.5\\\"\\n      }\\n    ],\\n    \\\"locations\\\": [\\n      {\\n        \\\"location_id\\\": 1,\\n        \\\"stock_on_hand\\\": \\\"10\\\",\\n        \\\"committed\\\": \\\"3\\\",\\n        \\\"incoming\\\": null,\\n        \\\"bin_location\\\": null,\\n        \\\"reorder_point\\\": null\\n      }\\n    ],\\n    \\\"prices\\\": {\\n      \\\"retail\\\": \\\"22.0\\\",\\n      \\\"wholesale\\\": \\\"12.0\\\",\\n      \\\"buy\\\": \\\"4.5\\\"\\n    },\\n    \\\"stock_levels\\\": {\\n      \\\"1\\\": \\\"10.0\\\"\\n    },\\n    \\\"committed_stock_levels\\\": {\\n      \\\"1\\\": \\\"3.0\\\"\\n    }\\n  }\\n}\\nRetrieves the details of an existing variant. You need only supply the unique variant identifier that was returned upon variant creation.HTTP RequestGET https://api.tradegecko.com/variants/{RESOURCE_ID}\"},{\"id\":\"update-a-variant\",\"title\":\"Update a variant\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nvariant = gecko.Variant.find(1)\\nvariant.attributes = {\\n  retail_price: \\\"12.0\\\",\\n  name: \\\"Sample Variant\\\",\\n  sku: \\\"SV1234\\\"\\n}\\nvariant.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/variants/1 -d '{\\\"variant\\\":{\\\"retail_price\\\":\\\"12.0\\\",\\\"name\\\":\\\"Sample Variant\\\",\\\"sku\\\":\\\"SV1234\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the variant gets updated successfully.\\n\\nUpdates the specified variant by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the variant creation call.HTTP RequestPUT https://api.tradegecko.com/variants/{RESOURCE_ID}\"},{\"id\":\"delete-a-variant\",\"title\":\"Delete a variant\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nvariant = gecko.Variant.find(1)\\nvariant.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/variants/1\\n\\nResponse\\n\\nReturns 204 status when the variant gets deleted successfully.\\n\\nPermanently deletes a variant. It cannot be undone.\\n  This variant will no longer be available for future Sales Order.HTTP RequestDELETE https://api.tradegecko.com/variants/{RESOURCE_ID}/\"},{\"id\":\"webhook\",\"title\":\"Webhook\",\"body\":\"This is an object representing a webhook.\"},{\"id\":\"the-webhook-object\",\"title\":\"The Webhook object\",\"body\":\"\\n\\nAttribute\\nType\\nDescription\\nReadonly\\n\\n\\n\\nid\\nInteger\\nA unique identifier for the resource.\\ntrue\\n\\n\\ncreated_at\\nString\\nDate and Time when the webhook was created.\\ntrue\\n\\n\\nupdated_at\\nString\\nDate and Time when the webhook was last updated.\\ntrue\\n\\n\\nevent\\nString\\nEvent which fires the webhook from TradeGecko to the specified address.\\n\\n\\n\\naddress\\nString\\nURI where a POST request will be sent everytime an event occurs in TradeGecko\\n\\n\\n\"},{\"id\":\"list-all-webhooks\",\"title\":\"List all webhooks\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\n\\ngecko.Webhook.where(limit: 25, status: 'active')\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/webhooks/\\n{\\n  \\\"webhooks\\\": [\\n    {\\n      \\\"id\\\": 1,\\n      \\\"created_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n      \\\"updated_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n      \\\"event\\\": \\\"product.create\\\",\\n      \\\"address\\\": \\\"https://mywebsite.com/webhooks\\\",\\n      \\\"oauth_application_id\\\": 1\\n    },\\n    {\\n      \\\"id\\\": 2,\\n      \\\"created_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n      \\\"updated_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n      \\\"event\\\": \\\"product.update\\\",\\n      \\\"address\\\": \\\"https://mywebsite.com/webhooks\\\",\\n      \\\"oauth_application_id\\\": 1\\n    }\\n  ]\\n}\\nReturns a list of webhooks you’ve previously created. The webhooks are returned in sorted order, with the most recent webhooks appearing first.Filters\\n\\nArguments\\nDescription\\n\\n\\n\\nids\\nAn array of webhook IDs. See Getting Started for examples.\\n\\n\\nlimit\\nused for pagination (default is 50)\\n\\n\\npage\\nused for pagination (default is 1)\\n\\n\\ncreated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\ncreated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_min\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\n\\nupdated_at_max\\nISO 8601 format (e.g. 2020-01-08T00:00:00.00Z)\\n\\nHTTP Request:GET  https://api.tradegecko.com/webhooks\"},{\"id\":\"create-a-new-webhook\",\"title\":\"Create a new webhook\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nwebhook = gecko.Webhook.build({\\n  address: \\\"https://mywebsite.com/webhooks\\\",\\n  event: \\\"product.create\\\"\\n})\\nwebhook.save\\ncurl -X POST -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/webhooks/ -d '{\\\"webhook\\\":{\\\"address\\\":\\\"https://mywebsite.com/webhooks\\\",\\\"event\\\":\\\"product.create\\\"}}'\\n{\\n  \\\"webhook\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n    \\\"updated_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n    \\\"event\\\": \\\"product.create\\\",\\n    \\\"address\\\": \\\"https://mywebsite.com/webhooks\\\",\\n    \\\"oauth_application_id\\\": 1\\n  }\\n}\\nCreates a new webhook object.Arguments\\n\\nAttribute\\nType\\nDescription\\nRequired\\n\\n\\n\\nevent\\nString\\nEvent which fires the webhook from TradeGecko to the specified address.\\ntrue\\n\\n\\naddress\\nString\\nURI where a POST request will be sent everytime an event occurs in TradeGecko\\ntrue\\n\\nList of Available Events\\n\\nResource\\nEvent\\n\\n\\n\\naccount\\naccount.update\\n\\n\\naddresss\\naddress.create, address.update\\n\\n\\nchannel\\nchannel.destroy\\n\\n\\ncompany\\ncompany.create, company.update, company.destroy\\n\\n\\ncontact\\ncontact.create, contact.update\\n\\n\\ndocument_theme\\ndocument_theme.update\\n\\n\\nfulfillment\\nfulfillment.create, fulfillment.fulfilled\\n\\n\\nfulfillment_return\\nfulfillment_return.create, fulfillment_return.received\\n\\n\\ninvoice\\ninvoice.create, invoice.destroy\\n\\n\\nlocation\\nlocation.create, location.update\\n\\n\\norder\\norder.create, order.finalized, order.fulfilled\\n\\n\\npayment\\npayment.create\\n\\n\\nproduct\\nproduct.create, product.destroy\\n\\n\\nprocurement\\nprocurement.create\\n\\n\\npurchase_order\\npurchase_order.create, purchase_order.received\\n\\n\\nstock_adjustment\\nstock_adjustment.create\\n\\n\\nstock_transfer\\nstock_transfer.create\\n\\n\\nvariant\\nvariant.create, variant.stock_level_update\\n\\n\\nimage\\nimage.create\\n\\nHTTP RequestPOST https://api.tradegecko.com/webhooks/\"},{\"id\":\"retrieve-a-particular-webhook\",\"title\":\"Retrieve a particular webhook\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\ngecko.Webhook.find(1)\\ncurl -X GET -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/webhooks/1\\n{\\n  \\\"webhook\\\": {\\n    \\\"id\\\": 1,\\n    \\\"created_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n    \\\"updated_at\\\": \\\"2018-09-24T11:12:49.244Z\\\",\\n    \\\"event\\\": \\\"product.create\\\",\\n    \\\"address\\\": \\\"https://mywebsite.com/webhooks\\\",\\n    \\\"oauth_application_id\\\": 1\\n  }\\n}\\nRetrieves the details of an existing webhook. You need only supply the unique webhook identifier that was returned upon webhook creation.HTTP RequestGET https://api.tradegecko.com/webhooks/{RESOURCE_ID}\"},{\"id\":\"update-a-webhook\",\"title\":\"Update a webhook\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nwebhook = gecko.Webhook.find(1)\\nwebhook.attributes = {\\n  address: \\\"https://mynewwebsite.com/webhooks\\\",\\n  event: \\\"product.create\\\"\\n}\\nwebhook.save\\ncurl -X PUT -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/webhooks/1 -d '{\\\"webhook\\\":{\\\"address\\\":\\\"https://mynewwebsite.com/webhooks\\\",\\\"event\\\":\\\"product.create\\\"}}'\\n\\nResponse\\n\\nReturns 204 status when the webhook gets updated successfully.\\n\\nUpdates the specified webhook by setting the values of the parameters passed.Any parameters not provided will be left unchanged.\\nThis request accepts the same arguments as the webhook creation call.HTTP RequestPUT https://api.tradegecko.com/webhooks/{RESOURCE_ID}\"},{\"id\":\"delete-a-webhook\",\"title\":\"Delete a webhook\",\"body\":\"require 'gecko-ruby'\\ngecko = Gecko::Client.new(<OAUTH_ID>, <OAUTH_SECRET>)\\naccess_token = OAuth2::AccessToken.new(gecko.oauth_client, <ACCESS_TOKEN>)\\ngecko.access_token = access_token\\nwebhook = gecko.Webhook.find(1)\\nwebhook.destroy\\ncurl -X DELETE -H \\\"Content-type: application/json\\\" -H \\\"Authorization: Bearer <ACCESS_TOKEN>\\\"\\nhttps://api.tradegecko.com/webhooks/1\\n\\nResponse\\n\\nReturns 204 status when the webhook gets deleted successfully.\\n\\nPermanently deletes a webhook. It cannot be undone.HTTP RequestDELETE https://api.tradegecko.com/webhooks/{RESOURCE_ID}/\"},{\"id\":\"libraries\",\"title\":\"Libraries\",\"body\":\"\\nOfficial Rubygem\\nOfficial Omniauth strategy\\nExample Rails App w/ Omniauth\\n\"}]"
  window.tokens = JSON.parse(tokenString);
  