ReturnGO Get Eligible Policies

Finds the return policies an order item is eligible for, based on the customer's return reason

This action checks which ReturnGO return policies a single order line item is eligible for, based on the customer's return reason. Use it before "ReturnGO Create RMA By Policy" action so that you pass a valid Policy Name when creating the RMA.

This action does not create or change any RMA.

  • The action checks one line item per call. To check several items, run it once for each item.
  • If the item isn't eligible for any policy, Eligible Policy Names and Eligible Policies are both Null. One check on Eligible Policy Names is enough to branch your flow.
🚧

Supported return reasons

Return Reason Name must be one of the following values, written exactly as shown. Any other value returns a 404 error.

  • Ordered multiple products / sizes
  • Changed my mind
  • Item is damaged or faulty
  • Does not fit
  • Not as described
  • Received wrong item
  • Arrived too late
  • Order withdrawal
❗️

£0 items have no eligible policies

By default, ReturnGO doesn't allow £0 items to be returned, except for exchanges, so no return policy is available for them. If an order was placed with a 100% discount, the list of eligible policies will be empty (Eligible Policy Names is Null) and the item cannot be returned.

Inputs

In order to use the action in your flow you need to provide it with the following inputs:

InputTypeDescription
API SecretStringAuthentication key (sent as the x-api-key header).
Shop NameStringThis refers to the x-shop-name header in the API. The shop to operate on, e.g. example.myshopify.com.

To find your shop URL, click on the "copy" icon next to your store name at the top of the ReturnGO dashboard.
Order IDStringThe platform's internal order ID. This is not the customer-facing order name (e.g. for Shopify, use the order id, not order_name / #1234).
Shop Line Item IDStringThe ID of the line item on the order that the customer wants to return.
QuantityNumberThe number of units from this line item the customer wants to return.
Return Reason NameStringThe customer's reason for returning this item. Must be one of the supported return reasons listed above, or the action returns a 404 error.
Safe ModeOptional BooleanIf set to True, errors (order not found, invalid return reason, auth failures, rate limits, server errors, timeouts) are returned in the Error output and the flow keeps running. If False, an error stops the flow. Defaults to False.

Outputs

OutputTypeDescription
Success?BooleanTrue if the API call was successful; False if it failed.
Eligible Policy NamesListThe internal names of the policies this item is eligible for, given the return reason. Pick one and pass it as Policy Name to ReturnGO Create RMA By Policy. Null if no eligible policy was found (e.g. for £0 items).
Eligible PoliciesListThe raw returnOptions entries returned by ReturnGO for the item (each containing the returnedLineItem and its availablePolicyNames). Null if no eligible policy was found.
ErrorStringThe error message when the call fails and Safe Mode is enabled, including ReturnGO's reason when available. Null on a successful call.

A 404 error can mean either that the order wasn't found or that Return Reason Name isn't one of the supported values. If the order ID is correct, check the return reason.

This action uses the following ReturnGO endpoint:

  • POST /rma/getEligiblePolicies

https://static.returngo.ai/api-doc/returngo-api-swagger.html


Did this page help you?