{ "operationId": "getPurchaseOrder", "method": "GET", "path": "/PurchaseOrders/{PurchaseOrderID}", "summary": "Xero Retrieves a specific purchase order using a unique purchase order Id", "requestExamples": [], "responseExamples": [ { "status": "200", "contentType": "application/json", "example": { "Id": "53a8c7a5-92e8-475b-a037-acf7c55c3afd", "Status": "OK", "ProviderName": "Provider Name Example", "DateTimeUTC": "/Date(1553626110950)/", "PurchaseOrders": [ { "PurchaseOrderID": "15369a9f-17b6-4235-83c4-0029256d1c37", "PurchaseOrderNumber": "PO-0006", "DateString": "2019-03-26 00:00:00", "Date": "/Date(1553558400000+0000)/", "DeliveryDateString": "2019-03-28 00:00:00", "DeliveryDate": "/Date(1553731200000+0000)/", "DeliveryAddress": "101 Grafton Road\nRoseneath\nWellington\n6011\nNew Zealand", "AttentionTo": "CEO", "Telephone": "64 123-2222", "DeliveryInstructions": "Drop off at front door", "HasErrors": false, "IsDiscounted": true, "TotalDiscount": 250.0, "SentToContact": false, "Reference": "foobar", "Type": "PURCHASEORDER", "CurrencyRate": 1.0, "CurrencyCode": "NZD", "Contact": { "ContactID": "430fa14a-f945-44d3-9f97-5df5e28441b8", "ContactStatus": "ACTIVE", "Name": "Liam Gallagher", "FirstName": "Liam", "LastName": "Gallagher", "EmailAddress": "liam@rockstar.com", "BankAccountDetails": "", "Addresses": [ null, { "AddressType": "POBOX", "City": "Anytown", "Region": "NY", "PostalCode": "10101", "Country": "USA", "AttentionTo": "" } ], "Phones": [ { "PhoneType": "DEFAULT", "PhoneNumber": "222-2222", "PhoneAreaCode": "212", "PhoneCountryCode": "" }, null, { "PhoneType": "FAX", "PhoneNumber": "333-2233", "PhoneAreaCode": "212", "PhoneCountryCode": "" }, { "PhoneType": "MOBILE", "PhoneNumber": "444-3433", "PhoneAreaCode": "212", "PhoneCountryCode": "" } ], "UpdatedDateUTC": "/Date(1553672800957+0000)/", "ContactGroups": [ { "ContactGroupID": "17b44ed7-4389-4162-91cb-3dd5766e4e22", "Name": "Oasis", "Status": "ACTIVE", "Contacts": [], "HasValidationErrors": false } ], "IsSupplier": true, "IsCustomer": true, "DefaultCurrency": "NZD", "SalesTrackingCategories": [], "PurchasesTrackingCategories": [], "ContactPersons": [], "HasValidationErrors": false }, "BrandingThemeID": "414d4a87-46d6-4cfc-ab42-4e29d22e5076", "Status": "DRAFT", "LineAmountTypes": "Exclusive", "LineItems": [ { "ItemCode": "123", "Description": "Brand new Fender Strats", "UnitAmount": 2500.0, "TaxType": "INPUT2", "TaxAmount": 337.5, "LineAmount": 2250.0, "AccountCode": "630", "Tracking": [ { "Name": "Simpsons", "Option": "Homer", "TrackingCategoryID": "6a68adde-f210-4465-b0a9-0d8cc6f50762", "TrackingOptionID": "94faf12f-f65c-4331-8004-b0b7c5a2da23" } ], "Quantity": 1.0, "DiscountRate": 10.0, "LineItemID": "8a9d3eca-e052-43bc-9b87-221d0648c045" } ], "SubTotal": 2250.0, "TotalTax": 337.5, "Total": 2587.5, "UpdatedDateUTC": "/Date(1553626029823+0000)/", "HasAttachments": true, "Attachments": [ { "AttachmentID": "7d94ccdc-ef7b-4806-87ac-8442f25e593b", "FileName": "HelloWorld.png", "Url": "https://api.xero.com/api.xro/2.0/PurchaseOrders/15369a9f-17b6-4235-83c4-0029256d1c37/Attachments/HelloWorld.png", "MimeType": "image/png", "ContentLength": 76091 } ] } ] } } ] }