{"openapi": "3.1.0", "info": {"title": "Ponch", "version": "1.0.0", "description": "Digital loyalty stamp card platform"}, "paths": {"/api/auth/register": {"post": {"operationId": "apps_merchants_api_register", "summary": "Register", "parameters": [], "responses": {"201": {"description": "Created", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/TokenPair"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Auth"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/RegisterIn"}}}, "required": true}}}, "/api/auth/login": {"post": {"operationId": "apps_merchants_api_login", "summary": "Login", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/TokenPair"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "401": {"description": "Unauthorized", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Auth"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/LoginIn"}}}, "required": true}}}, "/api/auth/refresh": {"post": {"operationId": "apps_merchants_api_refresh_token", "summary": "Refresh Token", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/TokenPair"}}}}, "401": {"description": "Unauthorized", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Auth"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/RefreshIn"}}}, "required": true}}}, "/api/auth/switch-company": {"post": {"operationId": "apps_merchants_api_switch_company", "summary": "Switch Company", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/TokenPair"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Auth"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/SwitchCompanyIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}}, "/api/auth/logout": {"post": {"operationId": "apps_merchants_api_logout", "summary": "Logout", "parameters": [], "responses": {"204": {"description": "No Content"}}, "tags": ["Auth"], "security": [{"MerchantJWTAuth": []}]}}, "/api/auth/api-keys": {"post": {"operationId": "apps_merchants_api_create_api_key", "summary": "Create Api Key", "parameters": [], "responses": {"201": {"description": "Created", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/APIKeyCreatedOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Auth"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/APIKeyCreateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}, "get": {"operationId": "apps_merchants_api_list_api_keys", "summary": "List Api Keys", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/APIKeyOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Auth"], "security": [{"MerchantJWTAuth": []}]}}, "/api/auth/api-keys/{key_id}/revoke": {"post": {"operationId": "apps_merchants_api_revoke_api_key", "summary": "Revoke Api Key", "parameters": [{"in": "path", "name": "key_id", "schema": {"title": "Key Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/APIKeyOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Auth"], "security": [{"MerchantJWTAuth": []}]}}, "/api/auth/api-keys/{key_id}": {"delete": {"operationId": "apps_merchants_api_delete_api_key", "summary": "Delete Api Key", "parameters": [{"in": "path", "name": "key_id", "schema": {"title": "Key Id", "type": "string"}, "required": true}], "responses": {"204": {"description": "No Content"}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Auth"], "security": [{"MerchantJWTAuth": []}]}}, "/api/merchants/me": {"get": {"operationId": "apps_merchants_api_get_merchant", "summary": "Get Merchant", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/MerchantOut"}}}}}, "tags": ["Merchants"], "security": [{"MerchantJWTAuth": []}]}}, "/api/merchants/me/profile": {"get": {"operationId": "apps_merchants_api_get_profile", "summary": "Get Profile", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProfileOut"}}}}}, "tags": ["Merchants"], "security": [{"MerchantJWTAuth": []}]}, "patch": {"operationId": "apps_merchants_api_update_profile", "summary": "Update Profile", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProfileOut"}}}}}, "tags": ["Merchants"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/ProfileUpdateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}}, "/api/merchants/me/password": {"post": {"operationId": "apps_merchants_api_change_password", "summary": "Change Password", "parameters": [], "responses": {"204": {"description": "No Content"}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Merchants"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/PasswordChangeIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}}, "/api/merchants/me/staff": {"post": {"operationId": "apps_merchants_api_add_staff", "summary": "Add Staff", "parameters": [], "responses": {"201": {"description": "Created", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StaffOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "description": "Inline-create a new staff User + StaffMember in one call.\n\nA v1 deliberate restriction: this endpoint *only* creates new Users \u2014 it\nnever attaches existing ones. An owner could otherwise silently associate\nany User in the database with their Company (or, combined with the\npassword-reset path, take over that User's account). Adding an\nalready-existing user as staff needs an explicit consent flow (v2).", "tags": ["Merchants"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/StaffCreateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}, "get": {"operationId": "apps_merchants_api_list_staff", "summary": "List Staff", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/StaffOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Merchants"], "security": [{"MerchantJWTAuth": []}]}}, "/api/merchants/me/staff/{staff_id}": {"patch": {"operationId": "apps_merchants_api_update_staff", "summary": "Update Staff", "parameters": [{"in": "path", "name": "staff_id", "schema": {"title": "Staff Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StaffOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Merchants"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/StaffUpdateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}, "delete": {"operationId": "apps_merchants_api_remove_staff", "summary": "Remove Staff", "parameters": [{"in": "path", "name": "staff_id", "schema": {"title": "Staff Id", "type": "string"}, "required": true}], "responses": {"204": {"description": "No Content"}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Merchants"], "security": [{"MerchantJWTAuth": []}]}}, "/api/merchants/me/staff/{staff_id}/reset-password": {"post": {"operationId": "apps_merchants_api_reset_staff_password_endpoint", "summary": "Reset Staff Password Endpoint", "parameters": [{"in": "path", "name": "staff_id", "schema": {"title": "Staff Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StaffPasswordResetOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "description": "Reset a credential-only staff member's password; returns the new temp\npassword once. Mirrors the dashboard's owner-only reset and its guard:\nonly allowed for users exclusive to this company.", "tags": ["Merchants"], "security": [{"MerchantJWTAuth": []}]}}, "/api/companies/": {"get": {"operationId": "apps_merchants_api_list_companies", "summary": "List Companies", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/CompanyOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Companies"], "security": [{"MerchantJWTAuth": []}]}, "post": {"operationId": "apps_merchants_api_create_company", "summary": "Create Company", "parameters": [], "responses": {"201": {"description": "Created", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CompanyOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Companies"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/CompanyIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}}, "/api/companies/{company_id}": {"get": {"operationId": "apps_merchants_api_get_company", "summary": "Get Company", "parameters": [{"in": "path", "name": "company_id", "schema": {"title": "Company Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CompanyOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Companies"], "security": [{"MerchantJWTAuth": []}]}, "patch": {"operationId": "apps_merchants_api_update_company", "summary": "Update Company", "parameters": [{"in": "path", "name": "company_id", "schema": {"title": "Company Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CompanyOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Companies"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/CompanyUpdateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}, "delete": {"operationId": "apps_merchants_api_delete_company", "summary": "Delete Company", "parameters": [{"in": "path", "name": "company_id", "schema": {"title": "Company Id", "type": "string"}, "required": true}], "responses": {"204": {"description": "No Content"}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Companies"], "security": [{"MerchantJWTAuth": []}]}}, "/api/billing/plans": {"get": {"operationId": "apps_billing_api_list_plans", "summary": "List Plans", "parameters": [{"in": "query", "name": "currency", "schema": {"default": "USD", "title": "Currency", "type": "string"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/PlanOut"}, "title": "Response", "type": "array"}}}}}, "description": "Public pricing page: plans offered to new signups, with every interval\n(monthly/annual) priced in the requested presentment currency.", "tags": ["Billing"]}}, "/api/billing/subscription": {"get": {"operationId": "apps_billing_api_get_subscription", "summary": "Get Subscription", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/SubscriptionOut"}}}}}, "tags": ["Billing"], "security": [{"MerchantJWTAuth": []}]}}, "/api/billing/webhooks/stripe": {"post": {"operationId": "apps_billing_api_stripe_webhook", "summary": "Stripe Webhook", "parameters": [], "responses": {"200": {"description": "OK"}}, "description": "Inbound Stripe webhook. Verify signature (bad \u2192 400, Stripe won't retry\n4xx) \u2192 persist (dedupe on event id) \u2192 process inline (eager deploy). Returns\n200 when processed/duplicate, 5xx on a processing failure so Stripe's native\nretry re-drives it. `replay_stripe_events` is a manual break-glass only.", "tags": ["Billing"]}}, "/api/stores/": {"get": {"operationId": "apps_merchants_api_list_stores", "summary": "List Stores", "parameters": [{"in": "query", "name": "limit", "schema": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Limit"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/StoreOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Stores"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}, "post": {"operationId": "apps_merchants_api_create_store", "summary": "Create Store", "parameters": [], "responses": {"201": {"description": "Created", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StoreOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Stores"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/StoreIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}}, "/api/stores/{store_id}": {"get": {"operationId": "apps_merchants_api_get_store", "summary": "Get Store", "parameters": [{"in": "path", "name": "store_id", "schema": {"title": "Store Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StoreOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Stores"], "security": [{"MerchantJWTAuth": []}]}, "patch": {"operationId": "apps_merchants_api_update_store", "summary": "Update Store", "parameters": [{"in": "path", "name": "store_id", "schema": {"title": "Store Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StoreOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Stores"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/StoreUpdateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}, "delete": {"operationId": "apps_merchants_api_delete_store", "summary": "Delete Store", "parameters": [{"in": "path", "name": "store_id", "schema": {"title": "Store Id", "type": "string"}, "required": true}], "responses": {"204": {"description": "No Content"}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Stores"], "security": [{"MerchantJWTAuth": []}]}}, "/api/stores/{store_id}/logo": {"post": {"operationId": "apps_merchants_api_upload_store_logo", "summary": "Upload Store Logo", "parameters": [{"in": "path", "name": "store_id", "schema": {"title": "Store Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StoreOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Stores"], "requestBody": {"content": {"multipart/form-data": {"schema": {"properties": {"logo": {"format": "binary", "title": "Logo", "type": "string"}}, "required": ["logo"], "title": "FileParams", "type": "object"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}}, "/api/cards/": {"post": {"operationId": "apps_cards_api_create_template", "summary": "Create Template", "parameters": [], "responses": {"201": {"description": "Created", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CardTemplateOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Card Templates"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/CardTemplateCreateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}, "get": {"operationId": "apps_cards_api_list_templates", "summary": "List Templates", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/CardTemplateOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Card Templates"], "security": [{"MerchantJWTAuth": []}]}}, "/api/cards/{slug}": {"get": {"operationId": "apps_cards_api_get_template", "summary": "Get Template", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CardTemplateOut"}}}}}, "tags": ["Card Templates"], "security": [{"MerchantJWTAuth": []}]}, "patch": {"operationId": "apps_cards_api_update_template", "summary": "Update Template", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CardTemplateOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Card Templates"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/CardTemplateUpdateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}, "delete": {"operationId": "apps_cards_api_deactivate_template", "summary": "Deactivate Template", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}], "responses": {"204": {"description": "No Content"}}, "tags": ["Card Templates"], "security": [{"MerchantJWTAuth": []}]}}, "/api/cards/{slug}/publish": {"post": {"operationId": "apps_cards_api_publish_template", "summary": "Publish Template", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CardTemplateOut"}}}}}, "tags": ["Card Templates"], "security": [{"MerchantJWTAuth": []}]}}, "/api/cards/{slug}/images": {"get": {"operationId": "apps_cards_api_get_template_images", "summary": "Get Template Images", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/TemplateImagesOut"}}}}}, "tags": ["Card Templates"], "security": [{"MerchantJWTAuth": []}]}, "post": {"operationId": "apps_cards_api_upload_template_images", "summary": "Upload Template Images", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/TemplateImagesOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Card Templates"], "requestBody": {"content": {"multipart/form-data": {"schema": {"properties": {"logo_image": {"anyOf": [{"format": "binary", "type": "string"}, {"type": "null"}], "title": "Logo Image"}, "icon_image": {"anyOf": [{"format": "binary", "type": "string"}, {"type": "null"}], "title": "Icon Image"}, "strip_image": {"anyOf": [{"format": "binary", "type": "string"}, {"type": "null"}], "title": "Strip Image"}, "google_logo": {"anyOf": [{"format": "binary", "type": "string"}, {"type": "null"}], "title": "Google Logo"}, "google_hero_image": {"anyOf": [{"format": "binary", "type": "string"}, {"type": "null"}], "title": "Google Hero Image"}}, "title": "FileParams", "type": "object"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}]}}, "/api/cards/{slug}/enrollment-url": {"get": {"operationId": "apps_cards_api_get_enrollment_url", "summary": "Get Enrollment Url", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/EnrollmentUrlOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Card Templates"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/stamp-cards/": {"get": {"operationId": "apps_stamping_api_list_stamp_cards", "summary": "List Stamp Cards", "parameters": [{"in": "query", "name": "status", "schema": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Status"}, "required": false}, {"in": "query", "name": "template_slug", "schema": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Template Slug"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/StampCardOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Stamp Cards"], "security": [{"MerchantJWTAuth": []}]}}, "/api/stamp-cards/{card_id}": {"get": {"operationId": "apps_stamping_api_get_stamp_card", "summary": "Get Stamp Card", "parameters": [{"in": "path", "name": "card_id", "schema": {"title": "Card Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StampCardOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Stamp Cards"], "security": [{"MerchantJWTAuth": []}]}}, "/api/stamp-cards/{card_id}/events": {"get": {"operationId": "apps_stamping_api_get_stamp_events", "summary": "Get Stamp Events", "parameters": [{"in": "path", "name": "card_id", "schema": {"title": "Card Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/StampEventOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Stamp Cards"], "security": [{"MerchantJWTAuth": []}]}}, "/api/stamp-cards/{card_id}/rewards": {"get": {"operationId": "apps_stamping_api_get_rewards", "summary": "Get Rewards", "parameters": [{"in": "path", "name": "card_id", "schema": {"title": "Card Id", "type": "string"}, "required": true}, {"in": "query", "name": "status", "schema": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Status"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/RewardOut"}, "title": "Response", "type": "array"}}}}}, "description": "Reward history for a card, newest first. Pending rewards are the ones the\nmerchant still owes; filter with ``?status=pending`` to see just those.", "tags": ["Stamp Cards"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/stamping/nonce": {"post": {"operationId": "apps_stamping_api_issue_nonce", "summary": "Issue Nonce", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/NonceOut"}}}}, "401": {"description": "Unauthorized", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Stamping"], "security": [{"MerchantJWTAuth": []}]}}, "/api/stamping/stamp": {"post": {"operationId": "apps_stamping_api_stamp", "summary": "Stamp", "parameters": [{"in": "query", "name": "force", "schema": {"default": false, "title": "Force", "type": "boolean"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StampResultOut"}}}}, "401": {"description": "Unauthorized", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "403": {"description": "Forbidden", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "410": {"description": "Gone", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "429": {"description": "Too Many Requests", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Stamping"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/StampIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/stamping/redeem": {"post": {"operationId": "apps_stamping_api_redeem", "summary": "Redeem", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StampCardOut"}}}}, "401": {"description": "Unauthorized", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "403": {"description": "Forbidden", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "409": {"description": "Conflict", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Stamping"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/RedeemIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/stamping/set-count": {"post": {"operationId": "apps_stamping_api_set_count", "summary": "Set Count", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StampResultOut"}}}}, "401": {"description": "Unauthorized", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "403": {"description": "Forbidden", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}, "409": {"description": "Conflict", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "description": "Set a card's stamp count to an absolute value.\n\nFor matching a paper punch card at enrollment, or correcting a missed or\nduplicated stamp. Raising the count is a real stamp and mints rewards on\nevery threshold crossed; lowering it never creates or removes one.", "tags": ["Stamping"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/SetCountIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/stamping/lookup": {"post": {"operationId": "apps_stamping_api_lookup", "summary": "Lookup", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/StampCardOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Stamping"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/LookupIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/customers/": {"get": {"operationId": "apps_customers_api_list_customers", "summary": "List Customers", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/CustomerOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Customers"], "security": [{"MerchantJWTAuth": []}]}}, "/api/customers/{customer_id}": {"get": {"operationId": "apps_customers_api_get_customer", "summary": "Get Customer", "parameters": [{"in": "path", "name": "customer_id", "schema": {"title": "Customer Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CustomerOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Customers"], "security": [{"MerchantJWTAuth": []}]}}, "/api/analytics/dashboard": {"get": {"operationId": "apps_analytics_api_dashboard", "summary": "Dashboard", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/DashboardOut"}}}}}, "tags": ["Analytics"], "security": [{"MerchantJWTAuth": []}]}}, "/api/analytics/cards/{slug}/stats": {"get": {"operationId": "apps_analytics_api_card_stats", "summary": "Card Stats", "parameters": [{"in": "path", "name": "slug", "schema": {"title": "Slug", "type": "string"}, "required": true}, {"in": "query", "name": "days", "schema": {"default": 30, "title": "Days", "type": "integer"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/CardStatsOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Analytics"], "security": [{"MerchantJWTAuth": []}]}}, "/api/wallets/enroll/{company_slug}/{store_slug}": {"get": {"operationId": "apps_wallets_api_enrollment_info", "summary": "Enrollment Info", "parameters": [{"in": "path", "name": "company_slug", "schema": {"title": "Company Slug", "type": "string"}, "required": true}, {"in": "path", "name": "store_slug", "schema": {"title": "Store Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/EnrollmentInfoOut"}}}}}, "tags": ["Wallet Enrollment"]}}, "/api/wallets/enroll/{company_slug}/{store_slug}/apple": {"post": {"operationId": "apps_wallets_api_enroll_apple", "summary": "Enroll Apple", "parameters": [{"in": "path", "name": "company_slug", "schema": {"title": "Company Slug", "type": "string"}, "required": true}, {"in": "path", "name": "store_slug", "schema": {"title": "Store Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK"}, "409": {"description": "Conflict", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Wallet Enrollment"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/EnrollAppleIn"}}}, "required": true}}}, "/api/wallets/enroll/{company_slug}/{store_slug}/google": {"post": {"operationId": "apps_wallets_api_enroll_google", "summary": "Enroll Google", "parameters": [{"in": "path", "name": "company_slug", "schema": {"title": "Company Slug", "type": "string"}, "required": true}, {"in": "path", "name": "store_slug", "schema": {"title": "Store Slug", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/EnrollGoogleOut"}}}}, "409": {"description": "Conflict", "content": {"application/json": {"schema": {"additionalProperties": true, "title": "Response", "type": "object"}}}}}, "tags": ["Wallet Enrollment"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/EnrollGoogleIn"}}}, "required": true}}}, "/api/integrations/webhooks": {"post": {"operationId": "apps_integrations_api_create_webhook", "summary": "Create Webhook", "parameters": [], "responses": {"201": {"description": "Created", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/WebhookCreatedOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Integration Webhooks"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/WebhookCreateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}, "get": {"operationId": "apps_integrations_api_list_webhooks", "summary": "List Webhooks", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/WebhookOut"}, "title": "Response", "type": "array"}}}}}, "tags": ["Integration Webhooks"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/webhooks/{webhook_id}": {"get": {"operationId": "apps_integrations_api_get_webhook", "summary": "Get Webhook", "parameters": [{"in": "path", "name": "webhook_id", "schema": {"title": "Webhook Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/WebhookOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Integration Webhooks"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}, "patch": {"operationId": "apps_integrations_api_update_webhook", "summary": "Update Webhook", "parameters": [{"in": "path", "name": "webhook_id", "schema": {"title": "Webhook Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/WebhookOut"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Integration Webhooks"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/WebhookUpdateIn"}}}, "required": true}, "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}, "delete": {"operationId": "apps_integrations_api_delete_webhook", "summary": "Delete Webhook", "parameters": [{"in": "path", "name": "webhook_id", "schema": {"title": "Webhook Id", "type": "string"}, "required": true}], "responses": {"204": {"description": "No Content"}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Integration Webhooks"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/webhooks/{webhook_id}/rotate-secret": {"post": {"operationId": "apps_integrations_api_rotate_secret", "summary": "Rotate Secret", "parameters": [{"in": "path", "name": "webhook_id", "schema": {"title": "Webhook Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/WebhookSecretOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Integration Webhooks"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/webhooks/{webhook_id}/deliveries": {"get": {"operationId": "apps_integrations_api_list_deliveries", "summary": "List Deliveries", "parameters": [{"in": "path", "name": "webhook_id", "schema": {"title": "Webhook Id", "type": "string"}, "required": true}, {"in": "query", "name": "limit", "schema": {"default": 50, "title": "Limit", "type": "integer"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/DeliveryOut"}, "title": "Response", "type": "array"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Integration Webhooks"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/webhooks/deliveries/{delivery_id}/replay": {"post": {"operationId": "apps_integrations_api_replay_delivery", "summary": "Replay Delivery", "parameters": [{"in": "path", "name": "delivery_id", "schema": {"title": "Delivery Id", "type": "string"}, "required": true}], "responses": {"202": {"description": "Accepted", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/DeliveryOut"}}}}, "404": {"description": "Not Found", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "tags": ["Integration Webhooks"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/me": {"get": {"operationId": "apps_integrations_api_me", "summary": "Me", "parameters": [], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/IdentityOut"}}}}}, "description": "Auth test + connection label for Zapier/Make. Deliberately cheap.", "tags": ["Integrations"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/events": {"get": {"operationId": "apps_integrations_api_events", "summary": "Events", "parameters": [{"in": "query", "name": "type", "schema": {"title": "Type", "type": "string"}, "required": true}, {"in": "query", "name": "limit", "schema": {"default": 25, "title": "Limit", "type": "integer"}, "required": false}, {"in": "query", "name": "since", "schema": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Since"}, "required": false}, {"in": "query", "name": "template_slug", "schema": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Template Slug"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"additionalProperties": true, "type": "object"}, "title": "Response", "type": "array"}}}}, "400": {"description": "Bad Request", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/ErrorOut"}}}}}, "description": "Recent events, newest first, in the same shape the webhook delivers.\n\nBacks Zapier's performList and Make's polling triggers. Returns a bare array\nbecause Zapier requires the perform result to be a list.", "tags": ["Integrations"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/templates": {"get": {"operationId": "apps_integrations_api_list_integration_templates", "summary": "List Integration Templates", "parameters": [{"in": "query", "name": "active_only", "schema": {"default": false, "title": "Active Only", "type": "boolean"}, "required": false}, {"in": "query", "name": "limit", "schema": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Limit"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/TemplateOut"}, "title": "Response", "type": "array"}}}}}, "description": "Dropdown source for Zapier dynamic fields and Make RPCs.", "tags": ["Integrations"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/cards/search": {"get": {"operationId": "apps_integrations_api_search_cards", "summary": "Search Cards", "parameters": [{"in": "query", "name": "barcode_value", "schema": {"title": "Barcode Value", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"items": {"$ref": "#/components/schemas/StampCardOut"}, "title": "Response", "type": "array"}}}}}, "description": "Barcode lookup for connectors that cannot treat a 404 as \"no results\".\n\n`POST /api/stamping/lookup` answers 404 on a miss, which Zapier swallows but\nMake cannot: Make treats every 4xx as a scenario error and offers no way to\nreclassify one. Returning a list means a miss is zero bundles rather than a\nfailure.\n\nA card in another company answers the same empty list as one that does not\nexist. Barcodes are printed into every pass QR and so are not secret, while\n`customer_display` names the customer \u2014 see tests/test_multi_company.py.", "tags": ["Integrations"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/integrations/customers/search": {"get": {"operationId": "apps_integrations_api_search", "summary": "Search", "parameters": [{"in": "query", "name": "q", "schema": {"default": "", "title": "Q", "type": "string"}, "required": false}, {"in": "query", "name": "template_slug", "schema": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Template Slug"}, "required": false}, {"in": "query", "name": "store_id", "schema": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Store Id"}, "required": false}, {"in": "query", "name": "page", "schema": {"default": 1, "title": "Page", "type": "integer"}, "required": false}, {"in": "query", "name": "page_size", "schema": {"default": 20, "title": "Page Size", "type": "integer"}, "required": false}], "responses": {"200": {"description": "OK", "content": {"application/json": {"schema": {"$ref": "#/components/schemas/CustomerSearchPage"}}}}}, "tags": ["Integrations"], "security": [{"MerchantJWTAuth": []}, {"MerchantAPIKeyAuth": []}]}}, "/api/v1/devices/{device_id}/registrations/{pass_type_id}/{serial}": {"post": {"operationId": "apps_wallets_api_register_device", "summary": "Register Device", "parameters": [{"in": "path", "name": "device_id", "schema": {"title": "Device Id", "type": "string"}, "required": true}, {"in": "path", "name": "pass_type_id", "schema": {"title": "Pass Type Id", "type": "string"}, "required": true}, {"in": "path", "name": "serial", "schema": {"title": "Serial", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK"}}, "tags": ["Apple Web Service"]}, "delete": {"operationId": "apps_wallets_api_unregister_device", "summary": "Unregister Device", "parameters": [{"in": "path", "name": "device_id", "schema": {"title": "Device Id", "type": "string"}, "required": true}, {"in": "path", "name": "pass_type_id", "schema": {"title": "Pass Type Id", "type": "string"}, "required": true}, {"in": "path", "name": "serial", "schema": {"title": "Serial", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK"}}, "tags": ["Apple Web Service"]}}, "/api/v1/devices/{device_id}/registrations/{pass_type_id}": {"get": {"operationId": "apps_wallets_api_get_serial_numbers", "summary": "Get Serial Numbers", "parameters": [{"in": "path", "name": "device_id", "schema": {"title": "Device Id", "type": "string"}, "required": true}, {"in": "path", "name": "pass_type_id", "schema": {"title": "Pass Type Id", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK"}}, "tags": ["Apple Web Service"]}}, "/api/v1/passes/{pass_type_id}/{serial}": {"get": {"operationId": "apps_wallets_api_get_latest_pass", "summary": "Get Latest Pass", "parameters": [{"in": "path", "name": "pass_type_id", "schema": {"title": "Pass Type Id", "type": "string"}, "required": true}, {"in": "path", "name": "serial", "schema": {"title": "Serial", "type": "string"}, "required": true}], "responses": {"200": {"description": "OK"}}, "tags": ["Apple Web Service"]}}, "/api/v1/log": {"post": {"operationId": "apps_wallets_api_apple_log", "summary": "Apple Log", "parameters": [], "responses": {"200": {"description": "OK"}}, "tags": ["Apple Web Service"], "requestBody": {"content": {"application/json": {"schema": {"$ref": "#/components/schemas/AppleLogIn"}}}, "required": true}}}}, "components": {"schemas": {"CompanySummary": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}}, "required": ["id", "name", "slug", "is_active"], "title": "CompanySummary", "type": "object"}, "TokenPair": {"properties": {"access": {"title": "Access", "type": "string"}, "refresh": {"title": "Refresh", "type": "string"}, "stamp_session": {"default": "", "title": "Stamp Session", "type": "string"}, "company": {"anyOf": [{"$ref": "#/components/schemas/CompanySummary"}, {"type": "null"}]}, "companies": {"default": [], "items": {"$ref": "#/components/schemas/CompanySummary"}, "title": "Companies", "type": "array"}}, "required": ["access", "refresh"], "title": "TokenPair", "type": "object"}, "ErrorOut": {"properties": {"detail": {"title": "Detail", "type": "string"}}, "required": ["detail"], "title": "ErrorOut", "type": "object"}, "RegisterIn": {"properties": {"username": {"title": "Username", "type": "string"}, "email": {"title": "Email", "type": "string"}, "password": {"title": "Password", "type": "string"}, "business_name": {"title": "Business Name", "type": "string"}}, "required": ["username", "email", "password", "business_name"], "title": "RegisterIn", "type": "object"}, "LoginIn": {"properties": {"username": {"title": "Username", "type": "string"}, "password": {"title": "Password", "type": "string"}, "store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Store Id"}}, "required": ["username", "password"], "title": "LoginIn", "type": "object"}, "RefreshIn": {"properties": {"refresh": {"title": "Refresh", "type": "string"}}, "required": ["refresh"], "title": "RefreshIn", "type": "object"}, "SwitchCompanyIn": {"properties": {"company_id": {"format": "uuid", "title": "Company Id", "type": "string"}}, "required": ["company_id"], "title": "SwitchCompanyIn", "type": "object"}, "APIKeyCreatedOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "key": {"title": "Key", "type": "string"}, "prefix": {"title": "Prefix", "type": "string"}, "label": {"title": "Label", "type": "string"}, "store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Store Id"}}, "required": ["id", "key", "prefix", "label", "store_id"], "title": "APIKeyCreatedOut", "type": "object"}, "APIKeyCreateIn": {"properties": {"label": {"title": "Label", "type": "string"}, "store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Store Id"}}, "required": ["label"], "title": "APIKeyCreateIn", "type": "object"}, "APIKeyOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "prefix": {"title": "Prefix", "type": "string"}, "label": {"title": "Label", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Store Id"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "prefix", "label", "is_active", "store_id", "created_at"], "title": "APIKeyOut", "type": "object"}, "MerchantOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "plan": {"title": "Plan", "type": "string"}, "api_enabled": {"title": "Api Enabled", "type": "boolean"}, "usage": {"$ref": "#/components/schemas/UsageOut"}}, "required": ["id", "slug", "is_active", "plan", "api_enabled", "usage"], "title": "MerchantOut", "type": "object"}, "UsageDimensionOut": {"properties": {"used": {"title": "Used", "type": "integer"}, "limit": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Limit"}, "pct": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Pct"}}, "required": ["used", "limit", "pct"], "title": "UsageDimensionOut", "type": "object"}, "UsageOut": {"properties": {"plan": {"title": "Plan", "type": "string"}, "api_enabled": {"title": "Api Enabled", "type": "boolean"}, "exports_enabled": {"title": "Exports Enabled", "type": "boolean"}, "cards": {"$ref": "#/components/schemas/UsageDimensionOut"}, "stores": {"$ref": "#/components/schemas/UsageDimensionOut"}, "staff": {"$ref": "#/components/schemas/UsageDimensionOut"}, "companies": {"$ref": "#/components/schemas/UsageDimensionOut"}}, "required": ["plan", "api_enabled", "exports_enabled", "cards", "stores", "staff", "companies"], "title": "UsageOut", "type": "object"}, "ProfileOut": {"properties": {"username": {"title": "Username", "type": "string"}, "first_name": {"title": "First Name", "type": "string"}, "last_name": {"title": "Last Name", "type": "string"}, "email": {"title": "Email", "type": "string"}}, "required": ["username", "first_name", "last_name", "email"], "title": "ProfileOut", "type": "object"}, "ProfileUpdateIn": {"properties": {"first_name": {"anyOf": [{"maxLength": 150, "type": "string"}, {"type": "null"}], "title": "First Name"}, "last_name": {"anyOf": [{"maxLength": 150, "type": "string"}, {"type": "null"}], "title": "Last Name"}}, "title": "ProfileUpdateIn", "type": "object"}, "PasswordChangeIn": {"properties": {"current_password": {"title": "Current Password", "type": "string"}, "new_password": {"title": "New Password", "type": "string"}}, "required": ["current_password", "new_password"], "title": "PasswordChangeIn", "type": "object"}, "StaffOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "role": {"title": "Role", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "username": {"title": "Username", "type": "string"}, "default_store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Default Store Id"}, "allowed_store_ids": {"items": {"format": "uuid", "type": "string"}, "title": "Allowed Store Ids", "type": "array"}}, "required": ["id", "role", "is_active", "username", "default_store_id", "allowed_store_ids"], "title": "StaffOut", "type": "object"}, "StaffCreateIn": {"properties": {"username": {"title": "Username", "type": "string"}, "role": {"default": "stamper", "title": "Role", "type": "string"}, "email": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Email"}, "password": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Password"}, "allowed_store_ids": {"default": [], "items": {"format": "uuid", "type": "string"}, "title": "Allowed Store Ids", "type": "array"}, "default_store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Default Store Id"}}, "required": ["username"], "title": "StaffCreateIn", "type": "object"}, "StaffUpdateIn": {"properties": {"role": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Role"}, "is_active": {"anyOf": [{"type": "boolean"}, {"type": "null"}], "title": "Is Active"}, "allowed_store_ids": {"anyOf": [{"items": {"format": "uuid", "type": "string"}, "type": "array"}, {"type": "null"}], "title": "Allowed Store Ids"}, "default_store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Default Store Id"}}, "title": "StaffUpdateIn", "type": "object"}, "StaffPasswordResetOut": {"properties": {"username": {"title": "Username", "type": "string"}, "password": {"title": "Password", "type": "string"}}, "required": ["username", "password"], "title": "StaffPasswordResetOut", "type": "object"}, "CompanyOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "allow_cross_store_stamping": {"title": "Allow Cross Store Stamping", "type": "boolean"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "name", "slug", "is_active", "allow_cross_store_stamping", "created_at"], "title": "CompanyOut", "type": "object"}, "CompanyIn": {"properties": {"name": {"title": "Name", "type": "string"}, "slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Slug"}, "is_active": {"default": true, "title": "Is Active", "type": "boolean"}, "allow_cross_store_stamping": {"default": false, "title": "Allow Cross Store Stamping", "type": "boolean"}}, "required": ["name"], "title": "CompanyIn", "type": "object"}, "CompanyUpdateIn": {"properties": {"name": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Name"}, "slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Slug"}, "is_active": {"anyOf": [{"type": "boolean"}, {"type": "null"}], "title": "Is Active"}, "allow_cross_store_stamping": {"anyOf": [{"type": "boolean"}, {"type": "null"}], "title": "Allow Cross Store Stamping"}}, "title": "CompanyUpdateIn", "type": "object"}, "PlanOut": {"properties": {"slug": {"title": "Slug", "type": "string"}, "name": {"title": "Name", "type": "string"}, "max_active_cards": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Max Active Cards"}, "max_stores": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Max Stores"}, "max_extra_staff": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Max Extra Staff"}, "max_companies": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Max Companies"}, "api_enabled": {"title": "Api Enabled", "type": "boolean"}, "exports_enabled": {"title": "Exports Enabled", "type": "boolean"}, "prices": {"items": {"$ref": "#/components/schemas/PlanPriceOut"}, "title": "Prices", "type": "array"}}, "required": ["slug", "name", "max_active_cards", "max_stores", "max_extra_staff", "max_companies", "api_enabled", "exports_enabled", "prices"], "title": "PlanOut", "type": "object"}, "PlanPriceOut": {"properties": {"currency": {"title": "Currency", "type": "string"}, "interval": {"title": "Interval", "type": "string"}, "unit_amount": {"pattern": "^(?!^[-+.]*$)[+-]?0*\\d*\\.?\\d*$", "title": "Unit Amount", "type": "string"}}, "required": ["currency", "interval", "unit_amount"], "title": "PlanPriceOut", "type": "object"}, "SubscriptionOut": {"properties": {"plan": {"title": "Plan", "type": "string"}, "status": {"title": "Status", "type": "string"}, "currency": {"title": "Currency", "type": "string"}, "interval": {"title": "Interval", "type": "string"}, "current_period_end": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Current Period End"}, "cancel_at_period_end": {"title": "Cancel At Period End", "type": "boolean"}, "scheduled_plan": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Scheduled Plan"}, "scheduled_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Scheduled At"}, "usage": {"$ref": "#/components/schemas/UsageOut"}}, "required": ["plan", "status", "currency", "interval", "current_period_end", "cancel_at_period_end", "usage"], "title": "SubscriptionOut", "type": "object"}, "StoreOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "address": {"title": "Address", "type": "string"}, "latitude": {"anyOf": [{"type": "number"}, {"type": "null"}], "title": "Latitude"}, "longitude": {"anyOf": [{"type": "number"}, {"type": "null"}], "title": "Longitude"}, "email": {"title": "Email", "type": "string"}, "phone": {"title": "Phone", "type": "string"}, "website": {"title": "Website", "type": "string"}, "timezone": {"title": "Timezone", "type": "string"}, "enrollment_notify_mode": {"title": "Enrollment Notify Mode", "type": "string"}, "referrals_enabled": {"title": "Referrals Enabled", "type": "boolean"}, "is_active": {"title": "Is Active", "type": "boolean"}, "logo": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Logo"}, "company_id": {"format": "uuid", "title": "Company Id", "type": "string"}, "company_slug": {"title": "Company Slug", "type": "string"}, "allow_cross_store_stamping": {"title": "Allow Cross Store Stamping", "type": "boolean"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "name", "slug", "address", "latitude", "longitude", "email", "phone", "website", "timezone", "enrollment_notify_mode", "referrals_enabled", "is_active", "logo", "company_id", "company_slug", "allow_cross_store_stamping", "created_at"], "title": "StoreOut", "type": "object"}, "StoreIn": {"properties": {"name": {"title": "Name", "type": "string"}, "slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Slug"}, "address": {"default": "", "title": "Address", "type": "string"}, "latitude": {"anyOf": [{"type": "number"}, {"type": "null"}], "title": "Latitude"}, "longitude": {"anyOf": [{"type": "number"}, {"type": "null"}], "title": "Longitude"}, "email": {"default": "", "title": "Email", "type": "string"}, "phone": {"default": "", "title": "Phone", "type": "string"}, "website": {"default": "", "title": "Website", "type": "string"}, "timezone": {"default": "UTC", "title": "Timezone", "type": "string"}, "enrollment_notify_mode": {"default": "digest", "title": "Enrollment Notify Mode", "type": "string"}, "referrals_enabled": {"default": false, "title": "Referrals Enabled", "type": "boolean"}, "is_active": {"default": true, "title": "Is Active", "type": "boolean"}}, "required": ["name"], "title": "StoreIn", "type": "object"}, "StoreUpdateIn": {"properties": {"name": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Name"}, "slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Slug"}, "address": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Address"}, "latitude": {"anyOf": [{"type": "number"}, {"type": "null"}], "title": "Latitude"}, "longitude": {"anyOf": [{"type": "number"}, {"type": "null"}], "title": "Longitude"}, "email": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Email"}, "phone": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Phone"}, "website": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Website"}, "timezone": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Timezone"}, "enrollment_notify_mode": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Enrollment Notify Mode"}, "referrals_enabled": {"anyOf": [{"type": "boolean"}, {"type": "null"}], "title": "Referrals Enabled"}, "is_active": {"anyOf": [{"type": "boolean"}, {"type": "null"}], "title": "Is Active"}}, "title": "StoreUpdateIn", "type": "object"}, "CardTemplateOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Store Id"}, "name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "total_stamps_required": {"title": "Total Stamps Required", "type": "integer"}, "reward_description": {"title": "Reward Description", "type": "string"}, "reward_terms": {"title": "Reward Terms", "type": "string"}, "allow_multiple_completions": {"title": "Allow Multiple Completions", "type": "boolean"}, "stamps_per_visit": {"title": "Stamps Per Visit", "type": "integer"}, "card_expiry_days": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Card Expiry Days"}, "primary_color": {"title": "Primary Color", "type": "string"}, "secondary_color": {"title": "Secondary Color", "type": "string"}, "label_color": {"title": "Label Color", "type": "string"}, "logo_text": {"title": "Logo Text", "type": "string"}, "header_label": {"title": "Header Label", "type": "string"}, "description": {"title": "Description", "type": "string"}, "google_loyalty_class_id": {"title": "Google Loyalty Class Id", "type": "string"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}, "updated_at": {"format": "date-time", "title": "Updated At", "type": "string"}, "deactivated_template": {"anyOf": [{"$ref": "#/components/schemas/TemplateRefOut"}, {"type": "null"}]}}, "required": ["id", "store_id", "name", "slug", "is_active", "total_stamps_required", "reward_description", "reward_terms", "allow_multiple_completions", "stamps_per_visit", "card_expiry_days", "primary_color", "secondary_color", "label_color", "logo_text", "header_label", "description", "google_loyalty_class_id", "created_at", "updated_at"], "title": "CardTemplateOut", "type": "object"}, "TemplateRefOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}}, "required": ["id", "name", "slug"], "title": "TemplateRefOut", "type": "object"}, "CardTemplateCreateIn": {"properties": {"store_id": {"format": "uuid", "title": "Store Id", "type": "string"}, "name": {"title": "Name", "type": "string"}, "reward_description": {"title": "Reward Description", "type": "string"}, "total_stamps_required": {"default": 10, "minimum": 1, "title": "Total Stamps Required", "type": "integer"}, "reward_terms": {"default": "", "title": "Reward Terms", "type": "string"}, "allow_multiple_completions": {"default": true, "title": "Allow Multiple Completions", "type": "boolean"}, "stamps_per_visit": {"default": 1, "minimum": 1, "title": "Stamps Per Visit", "type": "integer"}, "card_expiry_days": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Card Expiry Days"}, "primary_color": {"default": "#4A90D9", "title": "Primary Color", "type": "string"}, "secondary_color": {"default": "#FFFFFF", "title": "Secondary Color", "type": "string"}, "label_color": {"default": "#FFFFFF", "title": "Label Color", "type": "string"}, "logo_text": {"default": "", "title": "Logo Text", "type": "string"}, "header_label": {"default": "Stamps", "title": "Header Label", "type": "string"}, "description": {"default": "", "title": "Description", "type": "string"}}, "required": ["store_id", "name", "reward_description"], "title": "CardTemplateCreateIn", "type": "object"}, "CardTemplateUpdateIn": {"properties": {"store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Store Id"}, "name": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Name"}, "reward_description": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Reward Description"}, "total_stamps_required": {"anyOf": [{"minimum": 1, "type": "integer"}, {"type": "null"}], "title": "Total Stamps Required"}, "reward_terms": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Reward Terms"}, "allow_multiple_completions": {"anyOf": [{"type": "boolean"}, {"type": "null"}], "title": "Allow Multiple Completions"}, "stamps_per_visit": {"anyOf": [{"minimum": 1, "type": "integer"}, {"type": "null"}], "title": "Stamps Per Visit"}, "card_expiry_days": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Card Expiry Days"}, "primary_color": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Primary Color"}, "secondary_color": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Secondary Color"}, "label_color": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Label Color"}, "logo_text": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Logo Text"}, "header_label": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Header Label"}, "description": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Description"}}, "title": "CardTemplateUpdateIn", "type": "object"}, "TemplateImagesOut": {"properties": {"logo_image": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Logo Image"}, "icon_image": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Icon Image"}, "strip_image": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Strip Image"}, "google_logo": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Google Logo"}, "google_hero_image": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Google Hero Image"}}, "required": ["logo_image", "icon_image", "strip_image", "google_logo", "google_hero_image"], "title": "TemplateImagesOut", "type": "object"}, "EnrollmentUrlOut": {"properties": {"url": {"title": "Url", "type": "string"}, "qr_data": {"title": "Qr Data", "type": "string"}}, "required": ["url", "qr_data"], "title": "EnrollmentUrlOut", "type": "object"}, "StampCardOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "barcode_value": {"title": "Barcode Value", "type": "string"}, "current_stamps": {"title": "Current Stamps", "type": "integer"}, "total_stamps_required": {"title": "Total Stamps Required", "type": "integer"}, "total_stamps_earned": {"title": "Total Stamps Earned", "type": "integer"}, "completions": {"title": "Completions", "type": "integer"}, "pending_rewards": {"title": "Pending Rewards", "type": "integer"}, "status": {"title": "Status", "type": "string"}, "reward_description": {"title": "Reward Description", "type": "string"}, "template_name": {"title": "Template Name", "type": "string"}, "customer_display": {"title": "Customer Display", "type": "string"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "barcode_value", "current_stamps", "total_stamps_required", "total_stamps_earned", "completions", "pending_rewards", "status", "reward_description", "template_name", "customer_display", "created_at"], "title": "StampCardOut", "type": "object"}, "StampEventOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "stamps_added": {"title": "Stamps Added", "type": "integer"}, "stamps_before": {"title": "Stamps Before", "type": "integer"}, "stamps_after": {"title": "Stamps After", "type": "integer"}, "source": {"title": "Source", "type": "string"}, "notes": {"title": "Notes", "type": "string"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "stamps_added", "stamps_before", "stamps_after", "source", "notes", "created_at"], "title": "StampEventOut", "type": "object"}, "RewardOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "completion_number": {"title": "Completion Number", "type": "integer"}, "status": {"title": "Status", "type": "string"}, "earned_at": {"format": "date-time", "title": "Earned At", "type": "string"}, "redeemed_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Redeemed At"}, "voided_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Voided At"}, "notes": {"title": "Notes", "type": "string"}}, "required": ["id", "completion_number", "status", "earned_at", "redeemed_at", "voided_at", "notes"], "title": "RewardOut", "type": "object"}, "NonceOut": {"properties": {"nonce": {"title": "Nonce", "type": "string"}, "expires_at": {"format": "date-time", "title": "Expires At", "type": "string"}}, "required": ["nonce", "expires_at"], "title": "NonceOut", "type": "object"}, "StampResultOut": {"properties": {"card": {"$ref": "#/components/schemas/StampCardOut"}, "reward_earned": {"title": "Reward Earned", "type": "boolean"}, "rewards_earned": {"default": 0, "title": "Rewards Earned", "type": "integer"}, "message": {"title": "Message", "type": "string"}}, "required": ["card", "reward_earned", "message"], "title": "StampResultOut", "type": "object"}, "StampIn": {"properties": {"barcode_value": {"title": "Barcode Value", "type": "string"}, "stamps": {"default": 1, "maximum": 100, "minimum": 1, "title": "Stamps", "type": "integer"}, "source": {"default": "scan", "title": "Source", "type": "string"}, "notes": {"default": "", "title": "Notes", "type": "string"}, "nonce": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Nonce"}, "idempotency_key": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Idempotency Key"}}, "required": ["barcode_value"], "title": "StampIn", "type": "object"}, "RedeemIn": {"properties": {"barcode_value": {"title": "Barcode Value", "type": "string"}, "notes": {"default": "", "title": "Notes", "type": "string"}, "count": {"default": 1, "maximum": 20, "minimum": 1, "title": "Count", "type": "integer"}, "idempotency_key": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Idempotency Key"}}, "required": ["barcode_value"], "title": "RedeemIn", "type": "object"}, "SetCountIn": {"properties": {"barcode_value": {"title": "Barcode Value", "type": "string"}, "current_stamps": {"maximum": 1000, "minimum": 0, "title": "Current Stamps", "type": "integer"}, "notes": {"default": "", "title": "Notes", "type": "string"}, "idempotency_key": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Idempotency Key"}}, "required": ["barcode_value", "current_stamps"], "title": "SetCountIn", "type": "object"}, "LookupIn": {"properties": {"barcode_value": {"title": "Barcode Value", "type": "string"}}, "required": ["barcode_value"], "title": "LookupIn", "type": "object"}, "CustomerOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "email": {"title": "Email", "type": "string"}, "phone": {"title": "Phone", "type": "string"}, "display_name": {"title": "Display Name", "type": "string"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "email", "phone", "display_name", "created_at"], "title": "CustomerOut", "type": "object"}, "DashboardOut": {"properties": {"total_templates": {"title": "Total Templates", "type": "integer"}, "total_active_cards": {"title": "Total Active Cards", "type": "integer"}, "total_stamps_given": {"title": "Total Stamps Given", "type": "integer"}, "total_rewards_earned": {"title": "Total Rewards Earned", "type": "integer"}, "total_rewards_redeemed": {"title": "Total Rewards Redeemed", "type": "integer"}, "pending_rewards": {"title": "Pending Rewards", "type": "integer"}, "store_stats": {"items": {"$ref": "#/components/schemas/StoreStatOut"}, "title": "Store Stats", "type": "array"}, "unattributed_stamps": {"title": "Unattributed Stamps", "type": "integer"}}, "required": ["total_templates", "total_active_cards", "total_stamps_given", "total_rewards_earned", "total_rewards_redeemed", "pending_rewards", "store_stats", "unattributed_stamps"], "title": "DashboardOut", "type": "object"}, "StoreStatOut": {"properties": {"name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "stamps": {"title": "Stamps", "type": "integer"}, "templates_count": {"title": "Templates Count", "type": "integer"}}, "required": ["name", "slug", "stamps", "templates_count"], "title": "StoreStatOut", "type": "object"}, "CardStatsOut": {"properties": {"date": {"format": "date", "title": "Date", "type": "string"}, "cards_issued": {"title": "Cards Issued", "type": "integer"}, "stamps_given": {"title": "Stamps Given", "type": "integer"}, "rewards_earned": {"title": "Rewards Earned", "type": "integer"}, "rewards_redeemed": {"title": "Rewards Redeemed", "type": "integer"}, "rewards_outstanding": {"title": "Rewards Outstanding", "type": "integer"}, "unique_customers_stamped": {"title": "Unique Customers Stamped", "type": "integer"}}, "required": ["date", "cards_issued", "stamps_given", "rewards_earned", "rewards_redeemed", "rewards_outstanding", "unique_customers_stamped"], "title": "CardStatsOut", "type": "object"}, "EnrollmentInfoOut": {"properties": {"template_name": {"title": "Template Name", "type": "string"}, "merchant_name": {"title": "Merchant Name", "type": "string"}, "reward_description": {"title": "Reward Description", "type": "string"}, "total_stamps_required": {"title": "Total Stamps Required", "type": "integer"}, "description": {"title": "Description", "type": "string"}, "primary_color": {"title": "Primary Color", "type": "string"}, "enrollment_paused": {"title": "Enrollment Paused", "type": "boolean"}}, "required": ["template_name", "merchant_name", "reward_description", "total_stamps_required", "description", "primary_color", "enrollment_paused"], "title": "EnrollmentInfoOut", "type": "object"}, "EnrollAppleIn": {"properties": {"email": {"default": "", "title": "Email", "type": "string"}, "phone": {"default": "", "title": "Phone", "type": "string"}, "display_name": {"default": "", "title": "Display Name", "type": "string"}, "language": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Language"}, "ref": {"default": "", "title": "Ref", "type": "string"}}, "title": "EnrollAppleIn", "type": "object"}, "EnrollGoogleOut": {"properties": {"add_to_wallet_url": {"title": "Add To Wallet Url", "type": "string"}, "stamp_card_id": {"format": "uuid", "title": "Stamp Card Id", "type": "string"}, "barcode_value": {"title": "Barcode Value", "type": "string"}}, "required": ["add_to_wallet_url", "stamp_card_id", "barcode_value"], "title": "EnrollGoogleOut", "type": "object"}, "EnrollGoogleIn": {"properties": {"email": {"default": "", "title": "Email", "type": "string"}, "phone": {"default": "", "title": "Phone", "type": "string"}, "display_name": {"default": "", "title": "Display Name", "type": "string"}, "language": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Language"}, "ref": {"default": "", "title": "Ref", "type": "string"}}, "title": "EnrollGoogleIn", "type": "object"}, "WebhookCreatedOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "url": {"title": "Url", "type": "string"}, "events": {"items": {"type": "string"}, "title": "Events", "type": "array"}, "template_slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Template Slug"}, "description": {"title": "Description", "type": "string"}, "source": {"title": "Source", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "consecutive_failures": {"title": "Consecutive Failures", "type": "integer"}, "last_delivered_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Last Delivered At"}, "auto_disabled_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Auto Disabled At"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}, "secret": {"title": "Secret", "type": "string"}}, "required": ["id", "url", "events", "description", "source", "is_active", "consecutive_failures", "created_at", "secret"], "title": "WebhookCreatedOut", "type": "object"}, "WebhookCreateIn": {"properties": {"url": {"format": "uri", "maxLength": 2083, "minLength": 1, "title": "Url", "type": "string"}, "events": {"items": {"type": "string"}, "title": "Events", "type": "array"}, "template_slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Template Slug"}, "description": {"default": "", "title": "Description", "type": "string"}, "source": {"default": "", "title": "Source", "type": "string"}}, "required": ["url", "events"], "title": "WebhookCreateIn", "type": "object"}, "WebhookOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "url": {"title": "Url", "type": "string"}, "events": {"items": {"type": "string"}, "title": "Events", "type": "array"}, "template_slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Template Slug"}, "description": {"title": "Description", "type": "string"}, "source": {"title": "Source", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "consecutive_failures": {"title": "Consecutive Failures", "type": "integer"}, "last_delivered_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Last Delivered At"}, "auto_disabled_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Auto Disabled At"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "url", "events", "description", "source", "is_active", "consecutive_failures", "created_at"], "title": "WebhookOut", "type": "object"}, "WebhookUpdateIn": {"properties": {"url": {"anyOf": [{"format": "uri", "maxLength": 2083, "minLength": 1, "type": "string"}, {"type": "null"}], "title": "Url"}, "events": {"anyOf": [{"items": {"type": "string"}, "type": "array"}, {"type": "null"}], "title": "Events"}, "template_slug": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Template Slug"}, "description": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Description"}, "is_active": {"anyOf": [{"type": "boolean"}, {"type": "null"}], "title": "Is Active"}}, "title": "WebhookUpdateIn", "type": "object"}, "WebhookSecretOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "secret": {"title": "Secret", "type": "string"}}, "required": ["id", "secret"], "title": "WebhookSecretOut", "type": "object"}, "DeliveryOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "event_type": {"title": "Event Type", "type": "string"}, "event_id": {"format": "uuid", "title": "Event Id", "type": "string"}, "status": {"title": "Status", "type": "string"}, "attempt_count": {"title": "Attempt Count", "type": "integer"}, "response_status": {"anyOf": [{"type": "integer"}, {"type": "null"}], "title": "Response Status"}, "response_body": {"title": "Response Body", "type": "string"}, "delivered_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Delivered At"}, "next_retry_at": {"anyOf": [{"format": "date-time", "type": "string"}, {"type": "null"}], "title": "Next Retry At"}, "created_at": {"format": "date-time", "title": "Created At", "type": "string"}}, "required": ["id", "event_type", "event_id", "status", "attempt_count", "response_body", "created_at"], "title": "DeliveryOut", "type": "object"}, "CompanyRef": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "name": {"title": "Name", "type": "string"}, "slug": {"title": "Slug", "type": "string"}}, "required": ["id", "name", "slug"], "title": "CompanyRef", "type": "object"}, "IdentityOut": {"properties": {"company": {"$ref": "#/components/schemas/CompanyRef"}, "merchant": {"$ref": "#/components/schemas/MerchantRef"}, "plan": {"$ref": "#/components/schemas/PlanRef"}, "api_enabled": {"title": "Api Enabled", "type": "boolean"}, "store_count": {"title": "Store Count", "type": "integer"}, "active_template_count": {"title": "Active Template Count", "type": "integer"}}, "required": ["company", "merchant", "plan", "api_enabled", "store_count", "active_template_count"], "title": "IdentityOut", "type": "object"}, "MerchantRef": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "slug": {"title": "Slug", "type": "string"}}, "required": ["id", "slug"], "title": "MerchantRef", "type": "object"}, "PlanRef": {"properties": {"slug": {"title": "Slug", "type": "string"}, "name": {"title": "Name", "type": "string"}}, "required": ["slug", "name"], "title": "PlanRef", "type": "object"}, "TemplateOut": {"properties": {"id": {"format": "uuid", "title": "Id", "type": "string"}, "slug": {"title": "Slug", "type": "string"}, "name": {"title": "Name", "type": "string"}, "total_stamps_required": {"title": "Total Stamps Required", "type": "integer"}, "reward_description": {"title": "Reward Description", "type": "string"}, "is_active": {"title": "Is Active", "type": "boolean"}, "store_id": {"anyOf": [{"format": "uuid", "type": "string"}, {"type": "null"}], "title": "Store Id"}, "store_name": {"anyOf": [{"type": "string"}, {"type": "null"}], "title": "Store Name"}}, "required": ["id", "slug", "name", "total_stamps_required", "reward_description", "is_active"], "title": "TemplateOut", "type": "object"}, "CardOut": {"properties": {"card_id": {"format": "uuid", "title": "Card Id", "type": "string"}, "barcode_value": {"title": "Barcode Value", "type": "string"}, "template_id": {"format": "uuid", "title": "Template Id", "type": "string"}, "template_slug": {"title": "Template Slug", "type": "string"}, "template_name": {"title": "Template Name", "type": "string"}, "current_stamps": {"title": "Current Stamps", "type": "integer"}, "total_stamps_required": {"title": "Total Stamps Required", "type": "integer"}, "status": {"title": "Status", "type": "string"}, "completions": {"title": "Completions", "type": "integer"}, "pending_rewards": {"title": "Pending Rewards", "type": "integer"}}, "required": ["card_id", "barcode_value", "template_id", "template_slug", "template_name", "current_stamps", "total_stamps_required", "status", "completions", "pending_rewards"], "title": "CardOut", "type": "object"}, "CustomerSearchOut": {"properties": {"customer_id": {"format": "uuid", "title": "Customer Id", "type": "string"}, "email": {"title": "Email", "type": "string"}, "phone": {"title": "Phone", "type": "string"}, "display_name": {"title": "Display Name", "type": "string"}, "cards": {"items": {"$ref": "#/components/schemas/CardOut"}, "title": "Cards", "type": "array"}}, "required": ["customer_id", "email", "phone", "display_name", "cards"], "title": "CustomerSearchOut", "type": "object"}, "CustomerSearchPage": {"properties": {"items": {"items": {"$ref": "#/components/schemas/CustomerSearchOut"}, "title": "Items", "type": "array"}, "total": {"title": "Total", "type": "integer"}, "page": {"title": "Page", "type": "integer"}, "page_size": {"title": "Page Size", "type": "integer"}}, "required": ["items", "total", "page", "page_size"], "title": "CustomerSearchPage", "type": "object"}, "AppleLogIn": {"properties": {"logs": {"items": {"type": "string"}, "title": "Logs", "type": "array"}}, "required": ["logs"], "title": "AppleLogIn", "type": "object"}}, "securitySchemes": {"MerchantJWTAuth": {"type": "http", "scheme": "bearer"}, "MerchantAPIKeyAuth": {"type": "http", "scheme": "bearer"}}}, "servers": []}