# Schemas

**CreateMemberDto**

| merchantId\*                | string    |
| --------------------------- | --------- |
| customerId\*                | string    |
| accountState\*              | string    |
| anonymized\*                | boolean   |
| contractId\*                | number    |
| createdAt\*                 | string    |
| credit\*                    | number    |
| creditsEarned\*             | number    |
| email\*                     | string    |
| firstName\*                 | string    |
| joinedAt\*                  | string    |
| lastCreditRedemptionAt\*    | string    |
| lastName\*                  | string    |
| lastPurchaseAt\*            | string    |
| notes\*                     | string    |
| numberOfCreditRedemptions\* | number    |
| orderCount\*                | number    |
| orderIds\*                  | \[number] |
| paymentId\*                 | number    |
| phoneNumber\*               | string    |
| referrals\*                 | number    |
| referredBy\*                | number    |
| revenue\*                   | number    |
| status\*                    | string    |
| totalSpend\*                | number    |
| updatedAt\*                 | string    |

**ResponseBodyDto**

| message\* | <p>string</p><p>The message associated with the response. Generally, the message only confirms the requested action. In the case of errors, the message will give insight into the source of the error.</p> |
| --------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| data\*    | The data associated with the response. Data is only returned from errors if the error originates from our backend to give further insight into the nature of the error.                                     |

**UpdateMemberDto**

| firstName\*   | <p>string</p><p>The customer's first name.</p>                                       |
| ------------- | ------------------------------------------------------------------------------------ |
| lastName\*    | <p>string</p><p>The customer's last name.</p>                                        |
| notes\*       | <p>string</p><p>Internal notes for this customer. Only viewable by the merchant.</p> |
| phoneNumber\* | <p>string</p><p>The customer's phone number.</p>                                     |

**CreateCreditDto**

| amount\* | <p>number<br>minimum: 1</p><p>The amount of credits to add to the customer's account.</p> |
| -------- | ----------------------------------------------------------------------------------------- |

**SignupStoreCreditsDto**

| creditAmount\* | <p>number</p><p>The amount to be awarded upon sign-up.</p>             |
| -------------- | ---------------------------------------------------------------------- |
| name\*         | <p>string</p><p>The name (appearance only) of this benefit.</p>        |
| days\*         | <p>number</p><p>The number of days to delay the credit award.</p>      |
| description\*  | <p>string</p><p>The description of this benefit (appearance only).</p> |
| type\*         | This is an internal identifier, leave default.                         |

**RecurringStoreCreditsDto**

| creditAmount\* | <p>number</p><p>The amount to be awarded each recurrence.</p>          |
| -------------- | ---------------------------------------------------------------------- |
| name\*         | <p>string</p><p>The name (appearance only) of this benefit.</p>        |
| description\*  | <p>string</p><p>The description of this benefit (appearance only).</p> |
| frequency\*    | <p>number</p><p>How often (in days) you want to award this credit.</p> |
| type\*         | This is an internal identifier, leave default.                         |

**CreditsforOrdersDto**

| internalTitle\*                       | <p>string</p><p>The internal identifier, leave default.</p>                                                                                                                                                                |
| ------------------------------------- | -------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------- |
| type\*                                | This is an internal identifier, leave default.                                                                                                                                                                             |
| description:                          | This is an internal identifier, leave default.                                                                                                                                                                             |
| name\*                                | <p>string</p><p>The name (appearance only) of this benefit.</p>                                                                                                                                                            |
| description\*                         | <p>string</p><p>The description of this benefit (appearance only).</p>                                                                                                                                                     |
| enabled\*                             | <p>boolean</p><p>Whether this benefit is enabled or not.</p>                                                                                                                                                               |
| rule\*                                | <p>string</p><p>Which credit rule: "PERCENTAGE\_BACK\_ON\_PURCHASE", "EARN\_EVERY\_ORDER", or "SPEND\_AND\_EARN".</p><p>Enum:<br>\[ PERCENTAGE\_BACK\_ON\_PURCHASE, EARN\_EVERY\_ORDER, SPEND\_AND\_EARN ]</p>             |
| rewardValue\*                         | <p>number</p><p>The amount of credits (or percent) to give as an award.</p>                                                                                                                                                |
| excludeInveterateMembershipProducts\* | <p>boolean</p><p>Whether or not to include the membership product for credit.</p>                                                                                                                                          |
| minimumPurchaseAmount\*               | <p>number</p><p>The minimum individual purchase amount to award credit for orders.</p>                                                                                                                                     |
| maximumRewardValue\*                  | <p>string</p><p>The discount code to use for this benefit.</p>                                                                                                                                                             |
| allowRefunds\*                        | <p>boolean</p><p>Whether or not this benefit is displayed on the landing page.</p>                                                                                                                                         |
| appliesTo\*                           | <p>string</p><p>Which products or collections this benefit applies to: "ALL\_PRODUCTS", "SPECIFIC\_PRODUCTS", or "SPECIFIC\_COLLECTIONS".</p><p>Enum:<br>\[ ALL\_PRODUCTS, SPECIFIC\_PRODUCTS, SPECIFIC\_COLLECTIONS ]</p> |
| applicableTo\*                        | <p>If appliesTo is either of the latter two values, this is a string array of Shopify Product IDs or Collection IDs (i.e. "gid://shopify/Collection/266717724758").</p><p>string]</p>                                      |

**AnniversaryCreditsDto**

| creditAmount\* | <p>number</p><p>The amount of credits to award on anniversary.</p>     |
| -------------- | ---------------------------------------------------------------------- |
| name\*         | <p>string</p><p>The name (appearance only) of this benefit.</p>        |
| description\*  | <p>string</p><p>The description of this benefit (appearance only).</p> |
| type\*         | This is an internal identifier, leave default.                         |

**StoreCreditsforReferralDto**

| creditAmount\* | <p>number</p><p>The amount of credits to award on referral.</p>        |
| -------------- | ---------------------------------------------------------------------- |
| name\*         | <p>string</p><p>The name (appearance only) of this benefit.</p>        |
| description\*  | <p>string</p><p>The description of this benefit (appearance only).</p> |
| type\*         | This is an internal identifier, leave default.                         |

**FreeShippingDto**

| shippingType\*         | <p>string</p><p>Which shipping type: "DISCOUNT\_CODE" or "SCRIPT".</p><p>Enum:<br>\[ DISCOUNT\_CODE, SCRIPT ]</p>                                           |
| ---------------------- | ----------------------------------------------------------------------------------------------------------------------------------------------------------- |
| code\*                 | <p>string</p><p>The name (appearance only) of this benefit.</p>                                                                                             |
| minRequirements\*      | <p>string</p><p>Which minumum requirements: "ITEM\_QUANTITY", "PURCHASE\_AMOUNT", or "NONE".</p><p>Enum:<br>\[ ITEM\_QUANTITY, PURCHASE\_AMOUNT, NONE ]</p> |
| isRatesExcluded\*      | <p>boolean</p><p>Whether or not to include purchases with shipping rates over a certain value.</p>                                                          |
| maximumShippingPrice\* | <p>number</p><p>The maximum shipping rate over which shipping is not free (only with previous value true).</p>                                              |
| minimumQuantity\*      | <p>number</p><p>If minRequirements is "ITEM\_QUANTITY", include this field to indicate minimum number of items.</p>                                         |
| minimumSubtotal\*      | <p>number</p><p>If minRequirements is "PURCHASE\_AMOUNT", include this field to indicate the minumum purchase amount.</p>                                   |
| countryType\*          | <p>string</p><p>Which country type: "ALL" or "SPECIFIC".</p><p>Enum:<br>\[ ALL, SPECIFIC ]</p>                                                              |
| countries\*            | If previous value is "SPECIFIC", this field contains the specific countries in the format: { "label": "United States", "value": "United States" }           |
| type\*                 | This is an internal identifier, leave default.                                                                                                              |
| description:           | This is an internal identifier, leave default.                                                                                                              |

**MemberOnlyDiscountDto**

| name\*        | <p>string</p><p>The name (appearance only) of this benefit.</p>   |
| ------------- | ----------------------------------------------------------------- |
| description\* | <p>string</p><p>The description of this benefit (appearance).</p> |
| type\*        | This is an internal identifier, leave default.                    |
| description:  | This is an internal identifier, leave default.                    |

**SignupDiscountDto**

| name\*              | <p>string</p><p>The name (appearance only) of this benefit.</p>                                                                            |
| ------------------- | ------------------------------------------------------------------------------------------------------------------------------------------ |
| description\*       | <p>string</p><p>The description of this benefit (appearance).</p>                                                                          |
| discountType\*      | <p>string</p><p>Which discount type: "percentage" or "fixed".</p><p>Enum:<br>\[ percentage, fixed ]</p>                                    |
| value\*             | <p>number</p><p>The fixed or percentage award value.</p>                                                                                   |
| collectionIds\*     | <p>If using collections, this is a string array of Shopify Collection IDs (i.e. "gid://shopify/Collection/266717724758").</p><p>string</p> |
| productIds\*        | <p>If using products, this is a string array of Shopify Product IDs (i.e. "gid://shopify/Product/266717724758").</p><p>string</p>          |
| minimumSubtotal\*   | <p>number</p><p>The minimum subtotal for an individual purchase to qualify (null if using quantity).</p>                                   |
| minimumQuantity\*   | <p>number</p><p>The minimum quantity of items in an individual purchase to qualify (null if using subtotal).</p>                           |
| oneUsePerCustomer\* | <p>boolean</p><p>Whether or not this discount is single use per customer.</p>                                                              |
| hasExpiration\*     | <p>boolean</p><p>Whether or not this discount expires.</p>                                                                                 |
| expirationDays\*    | <p>number</p><p>If the previous value is true, this is the quantity, in days, before this discount expires.</p>                            |
| type\*              | This is an internal identifier, leave default.                                                                                             |

**MemberPricingDto**

| name\*                      | <p>string</p><p>The name (appearance only) of this benefit.</p>              |
| --------------------------- | ---------------------------------------------------------------------------- |
| description\*               | <p>string</p><p>The description of this benefit (appearance).</p>            |
| collectionId\*              | <p>string</p><p>The Shopify collection ID link to apply this benefit to.</p> |
| defaultDiscountPercentage\* | <p>number</p><p>The discount in pricing to apply to the collection.</p>      |
| type\*                      | This is an internal identifier, leave default.                               |

**EarlyAccessCampaignDto**

| name\*          | <p>string</p><p>The name (appearance only) of this benefit.</p>                    |
| --------------- | ---------------------------------------------------------------------------------- |
| collectionIds\* | The Shopify collection IDs to apply this benefit to.                               |
| startDate\*     | <p>string</p><p>The Shopify discount code ID to apply to the collection.</p>       |
| endDate\*       | <p>string</p><p>The end date that takes the format: YYYY-MM-DD HH:MM:SS +00:00</p> |

**WebhookDto**

| merchantId\*   | <p>string</p><p>The ID of the merchant that owns this webhook.</p>                              |
| -------------- | ----------------------------------------------------------------------------------------------- |
| id\*           | <p>string</p><p>The ID of the webhook.</p>                                                      |
| createdByApp\* | <p>string</p><p>The entity that is requesting the webhook creation.</p>                         |
| dateCreated\*  | <p>string</p><p>The date the webhook was created.</p>                                           |
| dateUpdated\*  | <p>string</p><p>The date the webhook was last updated.</p>                                      |
| name\*         | <p>string</p><p>The name associated with the callback URL.</p>                                  |
| callbackUrl\*  | <p>string</p><p>The callback URL that will be called when one of the webhooks is triggered.</p> |
| token\*        | <p>string</p><p>The token associated with the webhook.</p>                                      |


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://help.inveterate.com/dev/api-reference-docs/public-api-2.0-reference/schemas.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
