{
  "openapi": "3.0.3",
  "paths": {
    "/v2.0/admin/members": {
      "get": {
        "operationId": "get_admin_members",
        "summary": "List members",
        "description": "Returns all members for a given merchant. Merchant is pulled from the public API key for security reasons.<br><br>\n    Pagination is supported by passing limit and lastCustomerId values as query parameters. You will get a lastCustomerId value in the response of the previous request, which can be used for the next.",
        "parameters": [
          {
            "name": "limit",
            "required": true,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "lastCustomerId",
            "required": true,
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Members"
        ]
      },
      "post": {
        "operationId": "create_admin_members",
        "summary": "Create a free-tier member",
        "description": "This endpoint is used to create a free tier member. You can also provide a credit value to add credits to the new members account.<br>\n    The `overrideSpendThreshold` parameter allows you to add customers to a spend based tier, and the `keepInSpendBasedTier` parameter<br>\n    ensures that the member won't be downgraded if they don't hit the spend minimum.<br><br>\n    NOTE: This endpoint will downgrade a customer specified to a lower tier if that is the tier provided to the endpoint!",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateFreeTierMember"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Members"
        ]
      }
    },
    "/v2.0/admin/members/{id}": {
      "get": {
        "operationId": "get_admin_members_ById",
        "summary": "Get a member",
        "description": "Returns a single member for a given merchant. Merchant is pulled from the public API key for security reasons.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number which you would like to retrieve.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Members"
        ]
      },
      "patch": {
        "operationId": "update_admin_members_ById",
        "summary": "Update a member",
        "description": "This endpoint is used to update a member. It takes a member ID and uses your public API key to match the customer to your account. As of now, all fields in the update schema are required, so it is not possible to update a single field at a time.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number which you would like to update.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateMemberDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Members"
        ]
      }
    },
    "/v2.0/admin/members/{id}/credits": {
      "get": {
        "operationId": "get_admin_members_ById_credits",
        "summary": "List a member's credits",
        "description": "Returns all credits for one customer. API key is used to match the customer to your account for security reasons. Ensure that the customer ID is included in the request path.<br><br>\n    Pagination is supported by passing limit and lastCreditEntry values as query parameters. You will get a lastCreditEntry value in the response of the previous request, which can be used for the next. Ensure that the lastCreditEntry value passed to the server is  encoded.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "required": false,
            "in": "query",
            "description": "The number of credits to return (for pagination).",
            "schema": {
              "type": "number"
            }
          },
          {
            "name": "lastCreditEntry",
            "required": false,
            "in": "query",
            "description": "The last credit entry from the previous request.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Credits"
        ]
      },
      "post": {
        "operationId": "create_admin_members_ById_credits",
        "summary": "Issue credits to a member",
        "description": "This method forwards the credit creation request to our backend. Returns the success status of the request against backend service. Like the other endpoints that make requests against our backend, the changes may not take effect immediately.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreditDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Credits"
        ]
      }
    },
    "/v2.0/admin/members/{id}/credits/expiration": {
      "patch": {
        "operationId": "update_admin_members_ById_credits_expiration",
        "summary": "Update a credit's expiration date",
        "description": "Changes the expiration date of a single credit ledger entry. The entry is identified by its sk\n    (in the form `${customerId}#${timestamp}`). The new expiration date is rounded down to the top\n    of the hour and must be more than 1 hour in the future; the entry's current expiration must\n    also be more than 1 hour away. If the customer has an active redemption code whose end date is\n    after the new expiration date, the request is rejected. This forwards to our backend.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateCreditExpirationDto"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Credits"
        ]
      }
    },
    "/v2.0/admin/members/{id}/cancellation": {
      "post": {
        "operationId": "create_admin_members_ById_cancellation",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "overrideCancelPolicy",
            "required": false,
            "in": "query",
            "description": "Whether or not to override the default merchant cancellation policy. Defaults to true, meaning the customer will be immediately cancelled.",
            "schema": {
              "default": true,
              "type": "boolean"
            }
          },
          {
            "name": "source",
            "required": false,
            "in": "query",
            "description": "The source of the cancellation, either \"MERCHANT\" or \"FAILURE\". Defaults to \"MERCHANT\".",
            "schema": {
              "default": "MERCHANT",
              "enum": [
                "FAILURE",
                "MERCHANT"
              ],
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Cancellation"
        ],
        "summary": "Request a membership cancellation"
      }
    },
    "/v2.0/admin/members/{id}/reactivation": {
      "post": {
        "operationId": "create_admin_members_ById_reactivation",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Reactivation"
        ],
        "summary": "Reactivate a membership"
      }
    },
    "/v2.0/admin/members/{id}/sbt": {
      "get": {
        "operationId": "get_admin_members_ById_sbt",
        "summary": "Get a member's periodic spend",
        "description": "Returns a single customers periodic spend. Includes monthly, quarterly, semi-annual, annual, and all-time spend.<br><br>\n    If the `data` field in the return body is undefined, the customer has no eligible SBT spend history (or the customer does not exist).<br><br>\n    You can use this endpoint to track a customers progress towards the next tier.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customerId to query.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Tiers"
        ]
      }
    },
    "/v2.0/admin/members/{id}/change-tier": {
      "post": {
        "operationId": "create_admin_members_ById_changeTier",
        "summary": "Change a member's tier",
        "description": "This endpoint allows merchants to upgrade or downgrade a customer by specifying a new tierId.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeTierDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Change Tier"
        ]
      }
    },
    "/v2.0/admin/members/{id}/change-renewal-date": {
      "post": {
        "operationId": "create_admin_members_ById_changeRenewalDate",
        "summary": "Change a member's renewal date",
        "description": "This endpoint allows merchants to change the renewal (next billing) date\nof a customer's paid subscription. The customer must be an active member\non a paid tier.\n\nNote: the change is applied asynchronously. A successful response means\nthe request was accepted — it may take a few moments before the new date\nis reflected on the subscription contract and the member record.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/ChangeRenewalDateDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Members"
        ]
      }
    },
    "/v2.0/admin/benefits": {
      "get": {
        "operationId": "get_admin_benefits",
        "summary": "List benefits",
        "description": "This endpoint will return all benefits for a merchant. It will return an array of benefits. Each benefit will have a `type` field that will identify the type of benefit.",
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Benefits"
        ]
      }
    },
    "/v2.0/admin/benefits/{type}": {
      "get": {
        "operationId": "get_admin_benefits_ByType",
        "summary": "Get a benefit",
        "description": "This endpoint will return one specific benefit given a benefit type. Note that the benefit type is a string character. For a list of all benefit types, look at the default type value in each schema.",
        "parameters": [
          {
            "name": "type",
            "required": true,
            "in": "path",
            "description": "The benefit type.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Benefits"
        ]
      },
      "patch": {
        "operationId": "update_admin_benefits_ByType",
        "summary": "Update a benefit",
        "description": "This endpoint will take a benefit type and any other values in the relevant schema and send a request to our backend to update the benefit with the new information. Keep in mind that, like with the POST method, this is a request against our backend. Thus, the effect will not be immediate.",
        "parameters": [
          {
            "name": "type",
            "required": true,
            "in": "path",
            "description": "The benefit identification name/type.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/SignupStoreCreditsDto"
                  },
                  {
                    "$ref": "#/components/schemas/RecurringStoreCreditsDto"
                  },
                  {
                    "$ref": "#/components/schemas/CreditsforOrdersDto"
                  },
                  {
                    "$ref": "#/components/schemas/AnniversaryCreditsDto"
                  },
                  {
                    "$ref": "#/components/schemas/StoreCreditsforReferralDto"
                  },
                  {
                    "$ref": "#/components/schemas/FreeShippingDto"
                  },
                  {
                    "$ref": "#/components/schemas/MemberOnlyDiscountDto"
                  },
                  {
                    "$ref": "#/components/schemas/SignupDiscountDto"
                  },
                  {
                    "$ref": "#/components/schemas/MemberPricingDto"
                  },
                  {
                    "$ref": "#/components/schemas/EarlyAccessCampaignDto"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Benefits"
        ]
      }
    },
    "/v2.0/admin/merchant": {
      "get": {
        "operationId": "get_admin_merchant",
        "summary": "Get merchant settings",
        "description": "Returns all internal merchant information associated with the API key.",
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Merchant"
        ]
      },
      "patch": {
        "operationId": "update_admin_merchant",
        "summary": "Update merchant settings",
        "description": "Updates specific merchant settings, based on the provided fields. Fields not provided will not be updated.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateMerchantDto"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Merchant"
        ]
      }
    },
    "/v2.0/admin/webhooks": {
      "post": {
        "operationId": "create_admin_webhooks",
        "summary": "Register a webhook",
        "description": "Generates a security token and places an entry with the token and the callback URL in our backend. The token is used to verify that the request is coming from Inveterate within your app, when the callback URL is triggered. Ensure that you save the token.<br><br>\n    The callback URL will be triggered when one of the following events occurs:\n\n    `merchant.updated`\n    `merchant.reinstall`\n    `customer.created`\n    `customer.updated`\n    `customer.credits.updated`\n    `customer.ordered`\n    `customer.cancellation_requested`\n    `customer.confirmed_cancellation`",
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Webhooks"
        ]
      },
      "get": {
        "operationId": "get_admin_webhooks",
        "summary": "List webhooks",
        "description": "Returns all webhooks for a given merchant. Merchant is pulled from the public API key for security reasons.",
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Webhooks"
        ]
      },
      "delete": {
        "operationId": "delete_admin_webhooks",
        "summary": "Delete a webhook",
        "description": "Deletes a webhook for a given merchant. Merchant is pulled from the public API key for security reasons. The effects of this method are both immediate (data deleted from webhooks database) and eventual (request against backend service to confirm webhook deletion).",
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Webhooks"
        ]
      }
    },
    "/v2.0/admin/tiers": {
      "get": {
        "operationId": "get_admin_tiers",
        "summary": "List tiers",
        "description": "Returns all tiers/segments for a given merchant. Merchant is pulled from the public API key for security reasons.",
        "parameters": [
          {
            "name": "includeBenefits",
            "required": false,
            "in": "query",
            "description": "Whether or not to include benefits in the response.",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Tiers"
        ]
      }
    },
    "/v2.0/admin/tiers/{id}": {
      "get": {
        "operationId": "get_admin_tiers_ById",
        "summary": "Get a tier",
        "description": "Returns a single tier/segment for a given merchant. Merchant is pulled from the public API key for security reasons.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The tier segment ID.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "includeBenefits",
            "required": false,
            "in": "query",
            "description": "Whether or not to include benefits in the response.",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Tiers"
        ]
      }
    },
    "/v2.0/admin/tiers/{id}/benefits": {
      "get": {
        "operationId": "get_admin_tiers_ById_benefits",
        "summary": "List a tier's benefits",
        "description": "This endpoint will return all benefits for a merchant under a given tier. It will return an array of benefits. Each benefit will have a `type` field that will identify the type of benefit.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The tier segment ID.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Tiers"
        ]
      }
    },
    "/v2.0/admin/tiers/{id}/benefits/{type}": {
      "get": {
        "operationId": "get_admin_tiers_ById_benefits_ByType",
        "summary": "Get a tier's benefit",
        "description": "This endpoint will return one specific benefit given a benefit type and segment ID. Note that the benefit type is a string character. For a list of all benefit types, look at the default type value in each schema.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The tier segment ID.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "type",
            "required": true,
            "in": "path",
            "description": "The benefit type.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Tiers"
        ]
      },
      "patch": {
        "operationId": "update_admin_tiers_ById_benefits_ByType",
        "summary": "Update a tier's benefit",
        "description": "This endpoint will take a benefit type, segment ID, and any other values in the relevant schema and send a request to our backend to update the benefit with the new information. Keep in mind that, like with the POST method, this is a request against our backend. Thus, the effect will not be immediate.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The tier segment ID.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "type",
            "required": true,
            "in": "path",
            "description": "The benefit identification name/type.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "oneOf": [
                  {
                    "$ref": "#/components/schemas/SignupStoreCreditsDto"
                  },
                  {
                    "$ref": "#/components/schemas/RecurringStoreCreditsDto"
                  },
                  {
                    "$ref": "#/components/schemas/CreditsforOrdersDto"
                  },
                  {
                    "$ref": "#/components/schemas/AnniversaryCreditsDto"
                  },
                  {
                    "$ref": "#/components/schemas/StoreCreditsforReferralDto"
                  },
                  {
                    "$ref": "#/components/schemas/FreeShippingDto"
                  },
                  {
                    "$ref": "#/components/schemas/MemberOnlyDiscountDto"
                  },
                  {
                    "$ref": "#/components/schemas/SignupDiscountDto"
                  },
                  {
                    "$ref": "#/components/schemas/MemberPricingDto"
                  },
                  {
                    "$ref": "#/components/schemas/EarlyAccessCampaignDto"
                  }
                ]
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Tiers"
        ]
      }
    },
    "/v2.0/admin/tiers/{id}/campaigns": {
      "get": {
        "operationId": "get_admin_tiers_ById_campaigns",
        "summary": "List a tier's campaigns",
        "description": "Returns all campaigns belonging to a specific Tier identified by its `segmentId`",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The tier segment ID.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Tiers"
        ]
      }
    },
    "/v2.0/admin/webhook-subscriptions": {
      "post": {
        "operationId": "create_admin_webhookSubscriptions",
        "summary": "Create a webhook subscription",
        "description": "Creates a new webhook subscription for the merchant",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreateWebhookSubscriptionDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Webhooks"
        ]
      },
      "delete": {
        "operationId": "delete_admin_webhookSubscriptions",
        "summary": "Delete a webhook subscription",
        "description": "Removes an existing webhook subscription",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/DeleteWebhookSubscriptionDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Webhooks"
        ]
      },
      "put": {
        "operationId": "update_admin_webhookSubscriptions",
        "summary": "Update a webhook subscription",
        "description": "Updates an existing webhook subscription configuration",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/UpdateWebhookSubscriptionDto"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Webhooks"
        ]
      },
      "get": {
        "operationId": "get_admin_webhookSubscriptions",
        "summary": "List webhook subscriptions",
        "description": "Returns all webhook subscriptions for the merchant",
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Admin - Webhooks"
        ]
      }
    },
    "/v2.0/storefront/auth": {
      "post": {
        "operationId": "create_storefront_auth",
        "summary": "Authenticate a member",
        "description": "Authenticates a user and returns a JWT token. This token is used to authenticate the user for all other storefront requests. JWTs expire after 2 hours.",
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/RequestAuthDto"
              }
            }
          }
        },
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "201": {
            "description": "",
            "content": {
              "application/json": {
                "schema": {
                  "type": "object"
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Authentication"
        ]
      }
    },
    "/v2.0/storefront/members/{id}": {
      "get": {
        "operationId": "get_storefront_members_ById",
        "summary": "Get a member",
        "description": "Returns all member data for a given member that is a part of your store. Merchant is pulled from the public API key for security reasons. Make sure to include the customer ID in the request path.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Members"
        ]
      }
    },
    "/v2.0/storefront/members/{id}/credits": {
      "get": {
        "operationId": "get_storefront_members_ById_credits",
        "summary": "List a member's credits",
        "description": "Returns all credits for one customer. API key is used to match the customer to your account for security reasons. Ensure that the customer ID is included in the request path.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "limit",
            "required": true,
            "in": "query",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "lastCreditEntry",
            "required": true,
            "in": "query",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Credits"
        ]
      }
    },
    "/v2.0/storefront/members/{id}/credits/redemption": {
      "post": {
        "operationId": "create_storefront_members_ById_credits_redemption",
        "summary": "Redeem credits",
        "description": "Forwards a redemption request to the Inveterate backend. Returns the success status of the request against the backend service. Like the other endpoints that make requests against our backend, the changes may not take effect immediately.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "requestBody": {
          "required": true,
          "content": {
            "application/json": {
              "schema": {
                "$ref": "#/components/schemas/CreditDto"
              }
            }
          }
        },
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Redemption"
        ]
      }
    },
    "/v2.0/storefront/members/{id}/cancellation": {
      "post": {
        "operationId": "create_storefront_members_ById_cancellation",
        "summary": "Request a membership cancellation",
        "description": "This method forwards the cancellation creation request to our backend. Returns the success status of the request against backend service. Like the other endpoints that make requests against our backend, the changes may not take effect immediately.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Cancellation"
        ]
      }
    },
    "/v2.0/storefront/members/{id}/payment-method": {
      "patch": {
        "operationId": "update_storefront_members_ById_paymentMethod",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID number.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "201": {
            "description": "Returned upon successful request made to our backend. Requests that return this code may take a small amount of time after successful API return to fully update.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Request sent successfully",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Payment Method"
        ],
        "summary": "Update a member's payment method"
      }
    },
    "/v2.0/storefront/benefits": {
      "get": {
        "operationId": "get_storefront_benefits",
        "summary": "List benefits",
        "description": "Returns all benefits for a given merchant. Merchant is pulled from the public API key for security reasons.",
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Benefits"
        ]
      }
    },
    "/v2.0/storefront/benefits/{id}": {
      "get": {
        "operationId": "get_storefront_benefits_ById",
        "summary": "Get a benefit",
        "description": "Returns a single benefit for a given merchant. Merchant is pulled from the public API key for security reasons. The benefit ID is the type of benefit. For a list of possible benefit types, see the default values in the schema list.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The benefit ID name/type.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Benefits"
        ]
      }
    },
    "/v2.0/storefront/tiers/{id}": {
      "get": {
        "operationId": "get_storefront_tiers_ById",
        "summary": "Get a tier",
        "description": "Returns a single tier/segment for a given merchant and customer. Merchant is pulled from the public API key for security reasons.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID.",
            "schema": {
              "type": "string"
            }
          },
          {
            "name": "includeBenefits",
            "required": false,
            "in": "query",
            "description": "Whether or not to include benefits in the response.",
            "schema": {
              "type": "boolean"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Tiers"
        ]
      }
    },
    "/v2.0/storefront/tiers/{id}/benefits": {
      "get": {
        "operationId": "get_storefront_tiers_ById_benefits",
        "summary": "List a tier's benefits",
        "description": "This endpoint will return all benefits for a merchant under a given tier. It will return an array of benefits. Each benefit will have a `type` field that will identify the type of benefit.",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Tiers"
        ]
      }
    },
    "/v2.0/storefront/tiers/{id}/campaigns": {
      "get": {
        "operationId": "get_storefront_tiers_ById_campaigns",
        "summary": "List a tier's campaigns",
        "description": "Returns all campaigns belonging to the Tier the customer belongs to (customer identified with `customerId` parameter)",
        "parameters": [
          {
            "name": "id",
            "required": true,
            "in": "path",
            "description": "The customer ID.",
            "schema": {
              "type": "string"
            }
          }
        ],
        "responses": {
          "200": {
            "description": "Returned upon successful direct action to our database. Action is immediate.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "Success",
                  "data": {
                    "id": 1,
                    "name": "John Doe"
                  }
                }
              }
            }
          },
          "400": {
            "description": "Returned upon a malformed request. Check your API key, URL parameters, and body parameters when this error is returned. Generally, if you see this error, that also means NO action was taken on our backend.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Bad Request",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          },
          "500": {
            "description": "Returned for all other errors. Generally these come from our backend. Some multipart functions may execute somewhat and then fail, causing some data to be updated.",
            "content": {
              "application/json": {
                "schema": {
                  "$ref": "#/components/schemas/ResponseBodyDto"
                },
                "example": {
                  "message": "ERROR: Internal error",
                  "data": {
                    "name": "err name",
                    "message": "err message"
                  }
                }
              }
            }
          }
        },
        "tags": [
          "Storefront - Tiers"
        ]
      }
    }
  },
  "info": {
    "title": "Memberships API",
    "description": "The Memberships API powers membership, credits, tiers, and benefits for your storefront. It exposes two families of endpoints: **Admin** endpoints for managing members, benefits, tiers, merchant settings, and webhooks server-to-server; and **Storefront** endpoints for member-facing experiences such as authentication, viewing credits, and redemptions.\n\nAuthenticate every request with your private API key in the `X-Inveterate-Api-Key` header (see the security scheme below). The same key authenticates both Admin and Storefront endpoints.",
    "termsOfService": "https://useonward.com/terms-and-conditions",
    "contact": {
      "email": "help@useonward.com"
    },
    "version": "2.0.0"
  },
  "tags": [
    {
      "name": "Admin - Members",
      "x-displayName": "Members",
      "description": "Server-to-server Members endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Credits",
      "x-displayName": "Credits",
      "description": "Server-to-server Credits endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Cancellation",
      "x-displayName": "Cancellation",
      "description": "Server-to-server Cancellation endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Reactivation",
      "x-displayName": "Reactivation",
      "description": "Server-to-server Reactivation endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Tiers",
      "x-displayName": "Tiers",
      "description": "Server-to-server Tiers endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Change Tier",
      "x-displayName": "Change Tier",
      "description": "Server-to-server Change Tier endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Benefits",
      "x-displayName": "Benefits",
      "description": "Server-to-server Benefits endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Merchant",
      "x-displayName": "Merchant",
      "description": "Server-to-server Merchant endpoints, authenticated with your private API key."
    },
    {
      "name": "Admin - Webhooks",
      "x-displayName": "Webhooks",
      "description": "Server-to-server Webhooks endpoints, authenticated with your private API key."
    },
    {
      "name": "Storefront - Authentication",
      "x-displayName": "Authentication",
      "description": "Member-facing Authentication endpoints for your storefront."
    },
    {
      "name": "Storefront - Members",
      "x-displayName": "Members",
      "description": "Member-facing Members endpoints for your storefront."
    },
    {
      "name": "Storefront - Credits",
      "x-displayName": "Credits",
      "description": "Member-facing Credits endpoints for your storefront."
    },
    {
      "name": "Storefront - Redemption",
      "x-displayName": "Redemption",
      "description": "Member-facing Redemption endpoints for your storefront."
    },
    {
      "name": "Storefront - Cancellation",
      "x-displayName": "Cancellation",
      "description": "Member-facing Cancellation endpoints for your storefront."
    },
    {
      "name": "Storefront - Payment Method",
      "x-displayName": "Payment Method",
      "description": "Member-facing Payment Method endpoints for your storefront."
    },
    {
      "name": "Storefront - Benefits",
      "x-displayName": "Benefits",
      "description": "Member-facing Benefits endpoints for your storefront."
    },
    {
      "name": "Storefront - Tiers",
      "x-displayName": "Tiers",
      "description": "Member-facing Tiers endpoints for your storefront."
    }
  ],
  "servers": [
    {
      "url": "https://public.inveterateapi.com"
    }
  ],
  "components": {
    "schemas": {
      "ResponseBodyDto": {
        "type": "object",
        "properties": {
          "message": {
            "type": "string",
            "description": "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."
          },
          "data": {
            "type": "object",
            "description": "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."
          }
        },
        "required": [
          "message",
          "data"
        ]
      },
      "UpdateMemberDto": {
        "type": "object",
        "properties": {
          "firstName": {
            "type": "string",
            "description": "The customer's first name."
          },
          "lastName": {
            "type": "string",
            "description": "The customer's last name."
          },
          "notes": {
            "type": "string",
            "description": "Internal notes for this customer. Only viewable by the merchant."
          },
          "phoneNumber": {
            "type": "string",
            "description": "The customer's phone number."
          },
          "birthday": {
            "type": "string",
            "description": "The customer's date of birth in YYYY-MM-DD format, e.g \"1988-04-01\""
          }
        },
        "required": [
          "firstName",
          "lastName",
          "notes",
          "phoneNumber",
          "birthday"
        ]
      },
      "CreateFreeTierMember": {
        "type": "object",
        "properties": {
          "customerId": {
            "type": "string",
            "description": "The customerId to add to the specified free tier."
          },
          "referrals": {
            "type": "string",
            "description": "The signify whether or not the customer was referred. NOTE: NOT to be used to indicate the referring customer."
          },
          "segmentId": {
            "type": "string",
            "description": "The segmentId of the tier you want to add this customer to."
          },
          "overrideSpendThreshold": {
            "type": "boolean",
            "description": "Whether or not to override the spend required to add a customer to a spend based tier."
          },
          "keepInSpendBasedTier": {
            "type": "boolean",
            "description": "Whether or not you want to keep this customer in the spend based tier despite not meeting the spend threshold."
          },
          "credits": {
            "type": "number",
            "minimum": 1,
            "description": "Especially for member creation requests, if you would like to add some credits to the specified customer."
          },
          "birthday": {
            "type": "string",
            "description": "The customer's date of birth in YYYY-MM-DD format, e.g \"1988-04-01\""
          }
        },
        "required": [
          "customerId",
          "referrals",
          "segmentId",
          "overrideSpendThreshold",
          "keepInSpendBasedTier",
          "credits",
          "birthday"
        ]
      },
      "CreditDto": {
        "type": "object",
        "properties": {
          "amount": {
            "type": "number",
            "description": "The amount of credits to be added to or removed from the customer's account. It can't be zero"
          },
          "note": {
            "type": "string",
            "description": "Optional note to be associated with this credit transaction"
          },
          "force": {
            "type": "boolean",
            "description": "When force: true is included with a negative credit amount, this will disable any active credit redemption discount codes when necessary."
          }
        },
        "required": [
          "amount"
        ]
      },
      "UpdateCreditExpirationDto": {
        "type": "object",
        "properties": {
          "sk": {
            "type": "string",
            "description": "The sort key (sk) of the credit ledger entry to update, in the form `${customerId}#${timestamp}`."
          },
          "expirationDate": {
            "type": "string",
            "description": "The new expiration date as an ISO-8601 date-time string (e.g. 2024-06-06T05:00:00.000Z). It is rounded down to the top of the hour and must be more than 1 hour in the future."
          }
        },
        "required": [
          "sk",
          "expirationDate"
        ]
      },
      "ChangeTierDto": {
        "type": "object",
        "properties": {
          "tierId": {
            "type": "string",
            "description": "The ID of the tier to which the customer will be moved."
          },
          "nextBillingDate": {
            "type": "string",
            "description": "The next billing date can be specified if the customer is changed to a paid tier. Format: YYYY-MM-DD"
          }
        },
        "required": [
          "tierId",
          "nextBillingDate"
        ]
      },
      "ChangeRenewalDateDto": {
        "type": "object",
        "properties": {
          "nextBillingDate": {
            "type": "string",
            "description": "The new renewal (next billing) date for the customer paid subscription. Must be a future date. Format: YYYY-MM-DD"
          }
        },
        "required": [
          "nextBillingDate"
        ]
      },
      "SignupStoreCreditsDto": {
        "type": "object",
        "properties": {
          "creditAmount": {
            "type": "number",
            "description": "The amount to be awarded upon sign-up."
          },
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "days": {
            "type": "number",
            "description": "The number of days to delay the credit award."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance only)."
          },
          "type": {
            "type": "object",
            "default": "SIGNUP_STORE_CREDITS",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "creditAmount",
          "name",
          "days",
          "description",
          "type"
        ]
      },
      "RecurringStoreCreditsDto": {
        "type": "object",
        "properties": {
          "creditAmount": {
            "type": "number",
            "description": "The amount to be awarded each recurrence."
          },
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance only)."
          },
          "frequency": {
            "type": "number",
            "description": "How often (in days) you want to award this credit."
          },
          "type": {
            "type": "object",
            "default": "SCHEDULED_STORE_CREDITS",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "creditAmount",
          "name",
          "description",
          "frequency",
          "type"
        ]
      },
      "CreditsforOrdersDto": {
        "type": "object",
        "properties": {
          "internalTitle": {
            "type": "string",
            "description": "The internal identifier, leave default."
          },
          "type": {
            "type": "object",
            "default": "CREDITS_FOR_ORDERS",
            "description": "This is an internal identifier, leave default."
          },
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance only)."
          },
          "enabled": {
            "type": "boolean",
            "description": "Whether this benefit is enabled or not."
          },
          "rule": {
            "type": "string",
            "enum": [
              "PERCENTAGE_BACK_ON_PURCHASE",
              "EARN_EVERY_ORDER",
              "SPEND_AND_EARN"
            ],
            "description": "Which credit rule: \"PERCENTAGE_BACK_ON_PURCHASE\", \"EARN_EVERY_ORDER\", or \"SPEND_AND_EARN\"."
          },
          "rewardValue": {
            "type": "number",
            "description": "The amount of credits (or percent) to give as an award."
          },
          "excludeInveterateMembershipProducts": {
            "type": "boolean",
            "description": "Whether or not to include the membership product for credit."
          },
          "minimumPurchaseAmount": {
            "type": "number",
            "description": "The minimum individual purchase amount to award credit for orders."
          },
          "maximumRewardValue": {
            "type": "string",
            "description": "The discount code to use for this benefit."
          },
          "allowRefunds": {
            "type": "boolean",
            "description": "Whether or not this benefit is displayed on the landing page."
          },
          "appliesTo": {
            "type": "string",
            "enum": [
              "ALL_PRODUCTS",
              "SPECIFIC_PRODUCTS",
              "SPECIFIC_COLLECTIONS"
            ],
            "description": "Which products or collections this benefit applies to: \"ALL_PRODUCTS\", \"SPECIFIC_PRODUCTS\", or \"SPECIFIC_COLLECTIONS\"."
          },
          "applicableTo": {
            "description": "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\").",
            "type": "array",
            "items": {
              "type": "string"
            }
          }
        },
        "required": [
          "internalTitle",
          "type",
          "name",
          "description",
          "enabled",
          "rule",
          "rewardValue",
          "excludeInveterateMembershipProducts",
          "minimumPurchaseAmount",
          "maximumRewardValue",
          "allowRefunds",
          "appliesTo",
          "applicableTo"
        ]
      },
      "AnniversaryCreditsDto": {
        "type": "object",
        "properties": {
          "creditAmount": {
            "type": "number",
            "description": "The amount of credits to award on anniversary."
          },
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance only)."
          },
          "type": {
            "type": "object",
            "default": "ANNIVERSARY_CREDITS",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "creditAmount",
          "name",
          "description",
          "type"
        ]
      },
      "StoreCreditsforReferralDto": {
        "type": "object",
        "properties": {
          "creditAmount": {
            "type": "number",
            "description": "The amount of credits to award on referral."
          },
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance only)."
          },
          "type": {
            "type": "object",
            "default": "REFERRALS",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "creditAmount",
          "name",
          "description",
          "type"
        ]
      },
      "FreeShippingDto": {
        "type": "object",
        "properties": {
          "shippingType": {
            "type": "string",
            "enum": [
              "DISCOUNT_CODE",
              "SCRIPT"
            ],
            "description": "Which shipping type: \"DISCOUNT_CODE\" or \"SCRIPT\"."
          },
          "code": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "minRequirements": {
            "type": "string",
            "enum": [
              "ITEM_QUANTITY",
              "PURCHASE_AMOUNT",
              "NONE"
            ],
            "description": "Which minumum requirements: \"ITEM_QUANTITY\", \"PURCHASE_AMOUNT\", or \"NONE\"."
          },
          "isRatesExcluded": {
            "type": "boolean",
            "description": "Whether or not to include purchases with shipping rates over a certain value."
          },
          "maximumShippingPrice": {
            "type": "number",
            "description": "The maximum shipping rate over which shipping is not free (only with previous value true)."
          },
          "minimumQuantity": {
            "type": "number",
            "description": "If minRequirements is \"ITEM_QUANTITY\", include this field to indicate minimum number of items."
          },
          "minimumSubtotal": {
            "type": "number",
            "description": "If minRequirements is \"PURCHASE_AMOUNT\", include this field to indicate the minumum purchase amount."
          },
          "countryType": {
            "type": "string",
            "enum": [
              "ALL",
              "SPECIFIC"
            ],
            "description": "Which country type: \"ALL\" or \"SPECIFIC\"."
          },
          "countries": {
            "description": "If previous value is \"SPECIFIC\", this field contains the specific countries in the format: { \"label\": \"United States\", \"value\": \"United States\" }",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "type": {
            "type": "object",
            "default": "FREE_SHIPPING",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "shippingType",
          "code",
          "minRequirements",
          "isRatesExcluded",
          "maximumShippingPrice",
          "minimumQuantity",
          "minimumSubtotal",
          "countryType",
          "countries",
          "type"
        ]
      },
      "MemberOnlyDiscountDto": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance)."
          },
          "type": {
            "type": "object",
            "default": "DISCOUNTS",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "name",
          "description",
          "type"
        ]
      },
      "SignupDiscountDto": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance)."
          },
          "discountType": {
            "type": "string",
            "enum": [
              "percentage",
              "fixed"
            ],
            "description": "Which discount type: \"percentage\" or \"fixed\"."
          },
          "value": {
            "type": "number",
            "description": "The fixed or percentage award value."
          },
          "collectionIds": {
            "description": "If using collections, this is a string array of Shopify Collection IDs (i.e. \"gid://shopify/Collection/266717724758\").",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "productIds": {
            "description": "If using products, this is a string array of Shopify Product IDs (i.e. \"gid://shopify/Product/266717724758\").",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "minimumSubtotal": {
            "type": "number",
            "description": "The minimum subtotal for an individual purchase to qualify (null if using quantity)."
          },
          "minimumQuantity": {
            "type": "number",
            "description": "The minimum quantity of items in an individual purchase to qualify (null if using subtotal)."
          },
          "oneUsePerCustomer": {
            "type": "boolean",
            "description": "Whether or not this discount is single use per customer."
          },
          "hasExpiration": {
            "type": "boolean",
            "description": "Whether or not this discount expires."
          },
          "expirationDays": {
            "type": "number",
            "description": "If the previous value is true, this is the quantity, in days, before this discount expires."
          },
          "type": {
            "type": "object",
            "default": "SIGNUP_DISCOUNTS",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "name",
          "description",
          "discountType",
          "value",
          "collectionIds",
          "productIds",
          "minimumSubtotal",
          "minimumQuantity",
          "oneUsePerCustomer",
          "hasExpiration",
          "expirationDays",
          "type"
        ]
      },
      "MemberPricingDto": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "description": {
            "type": "string",
            "description": "The description of this benefit (appearance)."
          },
          "collectionId": {
            "type": "string",
            "description": "The Shopify collection ID link to apply this benefit to."
          },
          "defaultDiscountPercentage": {
            "type": "number",
            "description": "The discount in pricing to apply to the collection."
          },
          "type": {
            "type": "object",
            "default": "MEMBER_ONLY_PRICING",
            "description": "This is an internal identifier, leave default."
          }
        },
        "required": [
          "name",
          "description",
          "collectionId",
          "defaultDiscountPercentage",
          "type"
        ]
      },
      "EarlyAccessCampaignDto": {
        "type": "object",
        "properties": {
          "name": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          },
          "collectionIds": {
            "description": "The Shopify collection IDs to apply this benefit to.",
            "type": "array",
            "items": {
              "type": "string"
            }
          },
          "startDate": {
            "type": "string",
            "description": "The Shopify discount code ID to apply to the collection."
          },
          "endDate": {
            "type": "string",
            "description": "The end date that takes the format: YYYY-MM-DD HH:MM:SS +00:00"
          }
        },
        "required": [
          "name",
          "collectionIds",
          "startDate",
          "endDate"
        ]
      },
      "CreditDiscountCombinations": {
        "type": "object",
        "properties": {
          "productDiscounts": {
            "type": "boolean",
            "default": null,
            "description": "Whether or not to allow discount combinations with product discounts."
          },
          "orderDiscounts": {
            "type": "boolean",
            "default": null,
            "description": "Whether or not to allow discount combinations with order discounts."
          },
          "shippingDiscounts": {
            "type": "boolean",
            "default": null,
            "description": "Whether or not to allow discount combinations with shipping discounts."
          }
        },
        "required": [
          "productDiscounts",
          "orderDiscounts",
          "shippingDiscounts"
        ]
      },
      "UpdateMerchantDto": {
        "type": "object",
        "properties": {
          "creditExpirationEnabled": {
            "type": "boolean",
            "description": "Whether or not expiring credits is enabled."
          },
          "creditsEnabled": {
            "type": "boolean",
            "description": "Whether or not credits are enabled."
          },
          "creditDiscountCombinations": {
            "description": "The merchant's credit discount combinations settings. Fields will default to existing settings OR false if not provided.",
            "allOf": [
              {
                "$ref": "#/components/schemas/CreditDiscountCombinations"
              }
            ]
          },
          "uniqueDiscountCodes": {
            "type": "string",
            "enum": [
              "one_time_purchase",
              "subscription",
              "both"
            ],
            "description": "Whether unique discount codes are enabled for one_time_purchase, subscription, or both."
          },
          "generalDiscountCodes": {
            "type": "string",
            "enum": [
              "one_time_purchase",
              "subscription",
              "both"
            ],
            "description": "Whether general discount codes are enabled for one_time_purchase, subscription, or both."
          },
          "signUpDiscounts": {
            "type": "string",
            "enum": [
              "one_time_purchase",
              "subscription",
              "both"
            ],
            "description": "Whether signup discounts are enabled for one_time_purchase, subscription, or both."
          },
          "creditExpirationDays": {
            "type": "number",
            "minimum": 1,
            "description": "The number of days until credits expire after they are created."
          }
        },
        "required": [
          "creditExpirationEnabled",
          "creditsEnabled",
          "creditDiscountCombinations",
          "uniqueDiscountCodes",
          "generalDiscountCodes",
          "signUpDiscounts",
          "creditExpirationDays"
        ]
      },
      "CreateWebhookSubscriptionDto": {
        "type": "object",
        "properties": {
          "topic": {
            "enum": [
              "customer.joined.paid_tier",
              "customer.joined.free_tier",
              "customer.joined.free_trial",
              "customer.joined.lifetime_tier",
              "customer.changed_tier",
              "customer.ordered",
              "customer.payment_succeeded",
              "customer.payment_failed",
              "customer_billing.attempt.failed",
              "customer.credits.updated",
              "customer.credits.expired",
              "customer.cancelled",
              "customer.pending_cancellation",
              "customer.updated",
              "customer.payment_methods.updated"
            ],
            "type": "string",
            "description": "The subscription topic (will be used as sort key).",
            "example": "customer.joined.paid_tier"
          },
          "callbackUrl": {
            "type": "string",
            "description": "The callback URL that will be called when one of the webhooks is triggered."
          },
          "name": {
            "type": "string",
            "description": "The subscription name."
          }
        },
        "required": [
          "topic",
          "callbackUrl",
          "name"
        ]
      },
      "DeleteWebhookSubscriptionDto": {
        "type": "object",
        "properties": {
          "topic": {
            "enum": [
              "customer.joined.paid_tier",
              "customer.joined.free_tier",
              "customer.joined.free_trial",
              "customer.joined.lifetime_tier",
              "customer.changed_tier",
              "customer.ordered",
              "customer.payment_succeeded",
              "customer.payment_failed",
              "customer_billing.attempt.failed",
              "customer.credits.updated",
              "customer.credits.expired",
              "customer.cancelled",
              "customer.pending_cancellation",
              "customer.updated",
              "customer.payment_methods.updated"
            ],
            "type": "string",
            "description": "The subscription topic to delete",
            "example": "customer.joined.paid_tier"
          },
          "id": {
            "type": "string",
            "description": "The subscription ID."
          }
        },
        "required": [
          "topic",
          "id"
        ]
      },
      "UpdateWebhookSubscriptionDto": {
        "type": "object",
        "properties": {
          "topic": {
            "enum": [
              "customer.joined.paid_tier",
              "customer.joined.free_tier",
              "customer.joined.free_trial",
              "customer.joined.lifetime_tier",
              "customer.changed_tier",
              "customer.ordered",
              "customer.payment_succeeded",
              "customer.payment_failed",
              "customer_billing.attempt.failed",
              "customer.credits.updated",
              "customer.credits.expired",
              "customer.cancelled",
              "customer.pending_cancellation",
              "customer.updated",
              "customer.payment_methods.updated"
            ],
            "type": "string",
            "description": "The subscription topic to update.",
            "example": "customer.joined.paid_tier"
          },
          "callbackUrl": {
            "type": "string",
            "description": "The callback URL that will be called when one of the webhooks is triggered."
          },
          "name": {
            "type": "string",
            "description": "The subscription name."
          },
          "id": {
            "type": "string",
            "description": "The subscription ID."
          }
        },
        "required": [
          "topic",
          "id"
        ]
      },
      "RequestAuthDto": {
        "type": "object",
        "properties": {
          "merchantId": {
            "type": "string",
            "description": "Your merchantId. You can obtain this by calling the `GET merchant` endpoint."
          },
          "usrEmail": {
            "type": "string",
            "description": "The amount to be awarded upon sign-up."
          },
          "usrPasswd": {
            "type": "string",
            "description": "The name (appearance only) of this benefit."
          }
        },
        "required": [
          "merchantId",
          "usrEmail",
          "usrPasswd"
        ]
      }
    },
    "securitySchemes": {
      "api_key": {
        "type": "apiKey",
        "in": "header",
        "name": "X-Inveterate-Api-Key",
        "description": "Your private Inveterate API key, sent on every request. The same key authenticates both Admin and Storefront endpoints. API keys are private and should never be exposed in front-end code."
      }
    }
  },
  "x-tagGroups": [
    {
      "name": "Admin",
      "tags": [
        "Admin - Members",
        "Admin - Credits",
        "Admin - Cancellation",
        "Admin - Reactivation",
        "Admin - Tiers",
        "Admin - Change Tier",
        "Admin - Benefits",
        "Admin - Merchant",
        "Admin - Webhooks"
      ]
    },
    {
      "name": "Storefront",
      "tags": [
        "Storefront - Authentication",
        "Storefront - Members",
        "Storefront - Credits",
        "Storefront - Redemption",
        "Storefront - Cancellation",
        "Storefront - Payment Method",
        "Storefront - Benefits",
        "Storefront - Tiers"
      ]
    }
  ],
  "security": [
    {
      "api_key": []
    }
  ]
}