@avvyr/storefront-sdk - v0.19.0
    Preparing search index...

    Class ReturnsResource

    Index
    • Link to download a return's label (PDF), with the return's public token. 404 when there is none.

      Parameters

      • token: string

      Returns string

    • Attach photos to a return that already exists, addressed by the publicToken returned from create.

      Photos go up after the return is created, never during the form. An abandoned form would otherwise leave files behind with no case to belong to. The return is still awaiting a decision at this point, so the photos reach whoever handles the claim.

      Compress before calling: the API caps each file at 5 MB and re-encodes to webp anyway.

      Parameters

      Returns Promise<UploadReturnAttachmentsResponse>

    • Validate a return request (get returnable items + returnToken)

      Parameters

      • orderNumber: string
      • email: string

      Returns Promise<ValidateReturnResponse>