Arlo

REST Auth API: CreditNotes

CreditNote resources represent the reversal of an Order. They follow largely the same structure, with lines, billing details and payments.

Individual line items are represented by CreditNoteLines.

CreditNote instance resource

Resource URI

/api/2012-02-01/auth/resources/creditnotes/{CreditNoteID}/

General structure

<CreditNote>
  <CreditNoteID>665</CreditNoteID>
  <UniqueIdentifier>22b3fab4-ef56-4d70-9ce0-a7cc3c1a26cd</UniqueIdentifier>
  <Code>CRD-302-1</Code>
  <ReferenceCode>Ref 128/12</ReferenceCode>
  <Date>2015-01-01</Date>
  <LineAmountsTaxInclusive>false</LineAmountsTaxInclusive>
  <SubTotal>1800.00</SubTotal>
  <TotalTax>225.00</TotalTax>
  <Total>2025.00</Total>
  <CurrencyCode>NZD</CurrencyCode>
  <MarkedAsCreditNoteSentDateTime>2011-10-17T03:51:29.577Z</MarkedAsCreditNoteSentDateTime>
  <MarkedAsPaidDateTime>2011-10-17T03:51:29.577Z</MarkedAsPaidDateTime>
  <Status>Approved</Status>
  <CreatedDateTime>2011-10-17T03:51:29.577Z</CreatedDateTime>
  <LastModifiedDateTime>2011-10-19T02:55:42.412Z</LastModifiedDateTime>
  <Link rel="self" type="application/xml" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillToContact" type="application/xml" title="BillToContact" href="https://demo.arlo.co/api/2012-02-01/auth/resources/contacts/18220/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillToOrganisation" type="application/xml" title="BillToOrganisation" href="https://demo.arlo.co/api/2012-02-01/auth/resources/organisations/99001/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillingAddress" type="application/xml" title="BillingAddress" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/billingaddress/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/Region" type="application/xml" title="Region" href="https://demo.arlo.co/api/2012-02-01/auth/resources/regions/4/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/Lines" type="application/xml" title="Lines" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/lines/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/PaymentReferences" type="application/xml" title="PaymentReferences" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/paymentreferences/"/>
</CreditNote>

Resource properties

Property Description
CreditNoteID An integer value that uniquely identifies this resource within the platform.
UniqueIdentifier A GUID value that uniquely identifies this resource across any platform.
Code A string representing a code of the credit note.
ReferenceCode A custom reference code (such as a purchase number), up to 256 characters.
Date The date of the credit note.
LineAmountsTaxInclusive Determines whether line amounts for the credit note are tax inclusive.
SubTotal The total of the credit note, excluding any tax amount.
TotalTax The total amount of tax for all lines on the credit note.
Total The total of the credit note, including tax.
CurrencyCode Three-letter alpha code of the currency the credit note has been created in.
MarkedAsCreditNoteSentDateTime A UTC DateTime value indicating when an invoice for the credit note was recorded as sent. Omitted if no invoice has been sent.
MarkedAsPaidDateTime A UTC DateTime value indicating when the credit note was marked as fully paid. Omitted if the credit note has not been fully paid.
CancelledDateTime A UTC DateTime value indicating when the credit note was cancelled. Omitted if the credit note has not been cancelled.
Status An CreditNoteStatus value representing the current state of this credit note, such as awaiting approval, expired, completed or cancelled.
CreatedDateTime A UTC DateTime value indicating when this resource was created. This value is read-only.
LastModifiedDateTime A UTC DateTime value indicating when this resource was last modified. This value is read-only.

HTTP GET

Returns a representation of an CreditNote, including the properties and links above.

Optional parameters
Parameter Description
expand Expression referencing Link elements to expand when generating the response. See link expansion.
Example

GET /api/2012-02-01/auth/resources/creditnotes/302/

<CreditNote>
  <CreditNoteID>302</CreditNoteID>
  <UniqueIdentifier>22b3fab4-ef56-4d70-9ce0-a7cc3c1a26cd</UniqueIdentifier>
  <Code>CRD-231-1</Code>
  <ReferenceCode>Ref 128/12</ReferenceCode>
  <Date>2015-01-01</Date>
  <LineAmountsTaxInclusive>false</LineAmountsTaxInclusive>
  <SubTotal>1800.00</SubTotal>
  <TotalTax>225.00</TotalTax>
  <Total>2025.00</Total>
  <CurrencyCode>NZD</CurrencyCode>
  <ApprovedDateTime>2011-10-17T03:51:29.577Z</ApprovedDateTime>
  <MarkedAsCreditNoteSentDateTime>2011-10-17T03:51:29.577Z</MarkedAsCreditNoteSentDateTime>
  <MarkedAsPaidDateTime>2011-10-17T03:51:29.577Z</MarkedAsPaidDateTime>
  <Status>Approved</Status>
  <CreatedDateTime>2011-10-17T03:51:29.577Z</CreatedDateTime>
  <LastModifiedDateTime>2011-10-19T02:55:42.412Z</LastModifiedDateTime>
  <Link rel="self" type="application/xml" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillToContact" type="application/xml" title="BillToContact" href="https://demo.arlo.co/api/2012-02-01/auth/resources/contacts/18220/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillToOrganisation" type="application/xml" title="BillToOrganisation" href="https://demo.arlo.co/api/2012-02-01/auth/resources/organisations/99001/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillingAddress" type="application/xml" title="BillingAddress" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/billingaddress/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/Region" type="application/xml" title="Region" href="https://demo.arlo.co/api/2012-02-01/auth/resources/regions/4/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/Lines" type="application/xml" title="Lines" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/lines/"/>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/PaymentReferences" type="application/xml" title="PaymentReferences" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/paymentreferences/"/>
</CreditNote>

HTTP POST

Not supported.

HTTP PUT

Not supported.

HTTP DELETE

Not supported.

CreditNote collection resource

The CreditNote collection resource represents the set of CreditNote resources on the platform.

Resource URI

/api/2012-02-01/auth/resources/creditnotes/

HTTP GET

Returns a representation of the collection as a set of Link elements which can be followed to access individual CreditNote resources, or link expansion can be used via the expand query parameter to inline the entities with the HTTP GET response. See querying collections for general information on handling resource collections.

Optional parameters
Parameter Description
expand Expression referencing Link elements to expand when generating the response. See link expansion.
filter A filter expression to apply to the collection. See collection filters. The following properties (and link titles) may be used in filter expressions:
  • UniqueIdentifier
  • Code
  • ReferenceCode
  • Status
  • CreatedDateTime
  • LastModifiedDateTime
orderby A sort expression to apply to the collection. See collection sorting. The following properties may be used in sort expressions:
  • CreditNoteID
  • CreatedDateTime
  • LastModifiedDateTime
skip Returns a subset of records from the collection, starting at index N+1 specified by this parameter. The skip and top parameters are generally used for collection paging.
top Returns a subset of records from the collection, starting at index 0 or index skip, and returns the first N records. The skip and top parameters are generally used for collection paging.
Example 1

Retrieve a collection of CreditNote links with the default parameters, and no link expansion.

GET /api/2012-02-01/auth/resources/creditnotes/

<CreditNotes>
	<Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/1/"/>
	<Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/2/"/>
	<Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/3/"/>
	<Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/4/"/>
	<Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/5/"/>
	<Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/6/"/>
	<Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/7/"/>
	...
    <Link rel="next" type="application/xml" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/?skip=100"/>
	<Link rel="self" type="application/xml" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/"/>
</CreditNotes>
Example 2

Retrieve a collection of CreditNote links with the default parameters, with CreditNote link expansion.

GET /api/2012-02-01/auth/resources/creditnotes/?expand=CreditNote

<CreditNotes>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/9001/">
    <CreditNote>
      <CreditNoteID>302</CreditNoteID>
      <UniqueIdentifier>22b3fab4-ef56-4d70-9ce0-a7cc3c1a26cd</UniqueIdentifier>
      <Code>CRD-231-1</Code>
      <ReferenceCode>Ref 128/12</ReferenceCode>
      <Date>2015-01-01</Date>
      <LineAmountsTaxInclusive>false</LineAmountsTaxInclusive>
      <SubTotal>1800.00</SubTotal>
      <TotalTax>225.00</TotalTax>
      <Total>2025.00</Total>
      <CurrencyCode>NZD</CurrencyCode>
      <Status>Cancelled</Status>
      <CancelledDateTime>2011-10-17T03:51:29.577Z</CancelledDateTime>
      <CreatedDateTime>2011-10-17T03:51:29.577Z</CreatedDateTime>
      <LastModifiedDateTime>2011-10-19T02:55:42.412Z</LastModifiedDateTime>
      <Link rel="self" type="application/xml" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/"/>
      <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillToContact" type="application/xml" title="BillToContact" href="https://demo.arlo.co/api/2012-02-01/auth/resources/contacts/18220/"/>
      <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillToOrganisation" type="application/xml" title="BillToOrganisation" href="https://demo.arlo.co/api/2012-02-01/auth/resources/organisations/99001/"/>
      <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/BillingAddress" type="application/xml" title="BillingAddress" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/billingaddress/"/>
      <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/Region" type="application/xml" title="Region" href="https://demo.arlo.co/api/2012-02-01/auth/resources/regions/4/"/>
      <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/Lines" type="application/xml" title="Lines" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/lines/"/>
      <Link rel="http://schemas.arlo.co/api/2012/02/auth/related/PaymentReferences" type="application/xml" title="PaymentReferences" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/302/paymentreferences/"/>
    </CreditNote>
  </Link>
  <Link rel="http://schemas.arlo.co/api/2012/02/auth/CreditNote" type="application/xml" title="CreditNote" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/9002/">
    <CreditNote>
    ...
    </CreditNote>
  </Link>
  ...
  <Link rel="next" type="application/xml" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/?expand=CreditNote&skip=100"/>
  <Link rel="self" type="application/xml" href="https://demo.arlo.co/api/2012-02-01/auth/resources/creditnotes/?expand=CreditNote"/>
</CreditNotes>

HTTP POST

Not supported.

HTTP PUT

Not supported.

HTTP DELETE

Not supported.