Edit line

This endpoint allows you to update the quantity, pricing, selling plan, and custom attributes of a subscription line item.

Token scope - Read & write subscription contracts

Rate limit - Global pool (i.e. 10 requests per second per domain)

Body parameters explained

  • pricingType- The pricing type to be applied to the subscription line item.
    • SELLING_PLAN - The line item price is derived from the selling plan associated with the subscription.
    • CUSTOM - Allows you to apply a custom discount to the line item using the customDiscount object. The discounted price is calculated based on the discount configuration provided.
  • customDiscount - The custom discount to be associated with the line which is being edited.
    • For PERCENTAGE, provide a whole number (for example, 15 for a 15% discount). Decimal values are not supported due to Shopify limitations.
    • For FIXED_PRICE, provide the fixed amount to be deducted from the line item price.
    • For PRICE, provide the final price that should be charged for the line item.
  • sellingPlanGroupId - The sellingPlanGroupId refers to the selling plan group ID associated with the variant that will be added.
    • If the sellingPlanGroupId is not provided, the system will assign the plan based on the priority of the available selling plan groups.
    • If the provided sellingPlanGroupId is invalid or does not exist, an error will be thrown.
Path Params
string
required

The unique identifier of the subscription contract in Loop.

string
required

The unique identifier of a line in a subscription.

Body Params
integer
required

New quantity of a particular line in a subscription contract.

int32

The selling plan group ID to be applied to the subscription line item.

string
enum

The pricing type to be applied to the subscription line item.

Allowed:
customDiscount
array of objects

The custom discount configuration to be applied when pricingType is set to CUSTOM.

customDiscount
Response
200
Language
Credentials
Header
LoadingLoading…
Response
Click Try It! to start a request and see the response here!