# Models

## The LoginRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"LoginRequest":{"type":"object","required":["email","password"],"properties":{"email":{"type":"string","format":"email","description":"User email address"},"password":{"type":"string","format":"password","description":"User password"}}}}}}
```

## The LoginResponse object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"LoginResponse":{"type":"object","required":["key"],"properties":{"key":{"type":"string","description":"Authentication token for the user session.\nUse this token in the `Authorization: Token <key>` header\nfor subsequent API requests, or it will be used automatically\nvia TokenAuthentication."},"redirect_url":{"type":["string","null"],"description":"Optional redirect URL derived from 'next' query parameter.\nWill be null if no redirect was specified."}}}}}}
```

## The OTPLoginRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"OTPLoginRequest":{"type":"object","required":["phone"],"properties":{"phone":{"type":"string","maxLength":16,"description":"Phone number that matches an existing active user in the system.\nPhone number must pass the configured phone regex validator.\nReturns 400 error if no user exists with this phone number."},"code":{"type":"string","minLength":4,"maxLength":20,"description":"SMS verification code received in Step 1.\n- Omit this field on first request to receive OTP via SMS\n- Include this field with the received code to complete login\n- Code expiration is controlled by `SMS_OTP_EXPIRE_TIME` setting"}}}}}}
```

## The PasswordSetRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordSetRequest":{"type":"object","required":["password1","password2"],"properties":{"password1":{"type":"string","format":"password","description":"New password"},"password2":{"type":"string","format":"password","description":"Confirm new password (must match password1).\nValidated against `AUTH_PASSWORD_VALIDATORS` setting."}}}}}}
```

## The PasswordSetSmsOtpRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordSetSmsOtpRequest":{"type":"object","required":["password1","password2","phone"],"properties":{"password1":{"type":"string","format":"password","description":"New password"},"password2":{"type":"string","format":"password","description":"Confirm new password (must match password1)"},"phone":{"type":"string","maxLength":60,"description":"Phone number for SMS verification"},"code":{"type":"string","description":"SMS verification code. Omit on first request\nto receive OTP."},"resend":{"type":"boolean","default":false,"description":"Set to true to request a new verification code"}}}}}}
```

## The PasswordResetEmailRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordResetEmailRequest":{"type":"object","required":["email"],"properties":{"email":{"type":"string","format":"email","description":"Email address for password reset link"}}}}}}
```

## The PasswordResetPhoneRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordResetPhoneRequest":{"type":"object","required":["phone"],"properties":{"phone":{"type":"string","maxLength":60,"description":"Phone number for password reset SMS"}}}}}}
```

## The PasswordChangeRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordChangeRequest":{"type":"object","required":["old_password","new_password1","new_password2"],"properties":{"old_password":{"type":"string","format":"password","description":"Current password"},"new_password1":{"type":"string","format":"password","description":"New password"},"new_password2":{"type":"string","format":"password","description":"Confirm new password (must match new_password1)"}}}}}}
```

## The PasswordlessLoginRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordlessLoginRequest":{"type":"object","required":["user","token"],"properties":{"user":{"type":"integer","description":"User ID. Must be an active user in the system.\nReturns 400 if user doesn't exist or is inactive."},"token":{"type":"string","description":"User's authentication token.\nThis is the same token returned from `/users/login` endpoint.\nMust match the token associated with the specified user."}}}}}}
```

## The PasswordlessLoginTokenRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordlessLoginTokenRequest":{"type":"object","required":["user","secret_key"],"properties":{"user":{"type":"integer","description":"User ID for whom to generate the one-time login token.\nMust be an active user in the system."},"secret_key":{"type":"string","description":"Secret key used for token generation and validation.\nThis same key must be provided when using the generated token\nat `/users/passwordless-login/{token}/` endpoint."}}}}}}
```

## The PasswordlessLoginTokenResponse object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PasswordlessLoginTokenResponse":{"type":"object","properties":{"redirect_url":{"type":"string","description":"Partial URL path containing only the token.\nFormat: `/users/passwordless-login/{token}/`\n\n**Important:** This is NOT a complete URL. The admin must append query\nparameters `user` and `secret_key` to create the full login link:\n`/users/passwordless-login/{token}/?user={user_id}&secret_key={secret_key}`\n\nToken expires after `PASSWORDLESS_LOGIN_MAX_AGE` seconds (default: 300)."}}}}}}
```

## The UserOrder object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"UserOrder":{"type":"object","description":"User order with all related data including items, discounts, addresses, and payment details.","properties":{"pk":{"type":"integer","description":"Order ID"},"number":{"type":"string","description":"Order number (unique identifier)"},"status":{"$ref":"#/components/schemas/EnumValue"},"currency":{"$ref":"#/components/schemas/EnumValue"},"amount":{"type":"string","description":"Order total amount"},"discount_amount":{"type":"string","description":"Total discount applied"},"amount_without_discount":{"type":"string","description":"Amount before discounts (computed field)"},"shipping_amount":{"type":"string","description":"Shipping cost"},"shipping_tax_rate":{"type":["string","null"],"description":"Tax rate for shipping"},"refund_amount":{"type":"string","description":"Total refund amount"},"discount_refund_amount":{"type":"string","description":"Refunded discount amount"},"shipping_refund_amount":{"type":"string","description":"Refunded shipping amount"},"is_cancelled":{"type":"boolean","description":"Whether order is fully cancelled"},"is_cancellable":{"type":"boolean","description":"Whether order can be cancelled"},"is_refundable":{"type":"boolean","description":"Whether order is eligible for refund"},"is_payable":{"type":"boolean","description":"Whether order has pending payment"},"tracking_url":{"type":["string","null"],"format":"uri","description":"Shipment tracking URL"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"invoice_number":{"type":["string","null"],"description":"Invoice number"},"invoice_date":{"type":["string","null"],"format":"date-time","description":"Invoice date"},"e_archive_url":{"type":["string","null"],"format":"uri","description":"E-Archive document URL"},"order_type":{"oneOf":[{"$ref":"#/components/schemas/EnumValue"},{"type":"null"}],"description":"Type of order. Possible values:\n- `regular`: Standard order placed by customer\n- `addon`: Additional items added to an existing order\n- `replacement`: Replacement order for defective/incorrect items\n\nField can be null for legacy orders created before order_type was introduced."},"user_email":{"type":"string","format":"email","description":"Email address used for order"},"has_gift_box":{"type":["boolean","null"],"description":"Whether order includes gift box"},"gift_box_note":{"type":["string","null"],"description":"Gift box message/note"},"notes":{"type":["string","null"],"description":"Order delivery instructions"},"installment_count":{"type":"integer","description":"Number of payment installments"},"installment_interest_amount":{"type":"string","description":"Interest amount for installment payment"},"bin_number":{"type":["string","null"],"description":"Credit card BIN number (first 6-8 digits)"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"},"shipping_address":{"$ref":"#/components/schemas/Address"},"billing_address":{"$ref":"#/components/schemas/Address"},"shipping_company":{"oneOf":[{"$ref":"#/components/schemas/EnumValue"},{"type":"null"}]},"client_type":{"$ref":"#/components/schemas/EnumValue"},"payment_option":{"$ref":"#/components/schemas/PaymentOptionSummary"},"bank":{"oneOf":[{"$ref":"#/components/schemas/BankSummary"},{"type":"null"}],"description":"Bank information (null if not credit card payment)"},"extra_field":{"type":["object","null"],"description":"Additional order data (rewards, custom fields, etc.)"},"orderitem_set":{"type":"array","items":{"$ref":"#/components/schemas/UserOrderItem"}},"discountitem_set":{"type":"array","items":{"$ref":"#/components/schemas/DiscountItem"}},"loyaltytransaction_set":{"type":"array","items":{"$ref":"#/components/schemas/LoyaltyTransaction"}}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}},"Address":{"type":"object","description":"Address details with location references","properties":{"pk":{"type":"integer"},"email":{"type":["string","null"],"format":"email"},"phone_number":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"country":{"$ref":"#/components/schemas/LocationSummary"},"city":{"$ref":"#/components/schemas/LocationSummary"},"line":{"type":"string","description":"Full address line"},"title":{"type":"string","description":"Address title/label"},"township":{"oneOf":[{"$ref":"#/components/schemas/LocationSummary"},{"type":"null"}]},"district":{"oneOf":[{"$ref":"#/components/schemas/LocationSummary"},{"type":"null"}]},"postcode":{"type":["string","null"]},"notes":{"type":["string","null"],"description":"Additional delivery instructions"},"company_name":{"type":["string","null"],"description":"Company name for corporate addresses"},"tax_office":{"type":["string","null"]},"tax_no":{"type":["string","null"]},"e_bill_taxpayer":{"type":["boolean","null"],"description":"E-bill taxpayer status"},"hash_data":{"type":"string","description":"Address hash for deduplication"},"address_type":{"$ref":"#/components/schemas/EnumValue"},"retail_store":{"oneOf":[{"type":"object","description":"Retail store details for store pickup addresses"},{"type":"null"}]},"remote_id":{"type":["string","null"],"description":"Remote system identifier"},"identity_number":{"type":["string","null"],"description":"Identity/tax number"},"extra_field":{"type":["object","null"],"description":"Additional custom fields"},"user":{"type":["integer","null"],"description":"User ID who owns this address"},"is_corporate":{"type":["boolean","null"],"description":"Whether this is a corporate address"},"primary":{"type":["boolean","null"],"description":"Whether this is the primary address"}}},"LocationSummary":{"type":"object","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"code":{"type":"string"}}},"PaymentOptionSummary":{"type":"object","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"payment_type":{"type":"string"},"slug":{"type":"string"}}},"BankSummary":{"type":"object","description":"Bank information for payment","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"slug":{"type":"string"},"logo":{"type":["string","null"],"format":"uri","description":"Bank logo image URL"},"logo_path":{"type":["string","null"],"description":"Alternative path for bank logo"}}},"UserOrderItem":{"type":"object","description":"Order item within an order. Includes product details, pricing, status, and cancellation information.","properties":{"pk":{"type":"integer","description":"Order item ID"},"product":{"$ref":"#/components/schemas/UserOrderProduct"},"order":{"type":"integer","description":"Parent order ID"},"price":{"type":"string","description":"Total price for this order item"},"tax_rate":{"type":"string","description":"Tax rate applied"},"retail_price":{"type":["string","null"],"description":"Original retail price before discounts"},"discount_amount":{"type":["string","null"],"description":"Discount applied to this item"},"discounted_price":{"type":"string","description":"Final price after discount (computed field)"},"status":{"$ref":"#/components/schemas/EnumValue"},"price_currency":{"$ref":"#/components/schemas/EnumValue"},"is_cancelled":{"type":"boolean","description":"Whether item is cancelled"},"is_cancellable":{"type":"boolean","description":"Whether item can be cancelled"},"is_refundable":{"type":"boolean","description":"Whether item is eligible for refund"},"is_tradable":{"type":"boolean","description":"Whether item is eligible for trade-in"},"tracking_url":{"type":["string","null"],"format":"uri","description":"Shipment tracking URL for this item"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"invoice_number":{"type":["string","null"],"description":"Invoice number for this item"},"invoice_date":{"type":["string","null"],"format":"date-time","description":"Invoice date"},"e_archive_url":{"type":["string","null"],"format":"uri","description":"E-Archive document URL"},"shipping_company":{"oneOf":[{"$ref":"#/components/schemas/EnumValue"},{"type":"null"}]},"shipping_option_group":{"oneOf":[{"$ref":"#/components/schemas/ShippingOptionGroup"},{"type":"null"}]},"estimated_delivery_date":{"type":["string","null"],"format":"date","description":"Estimated delivery date"},"shipped_date":{"type":["string","null"],"format":"date-time","description":"Date when item was shipped"},"delivered_date":{"type":["string","null"],"format":"date-time","description":"Date when item was delivered"},"image":{"type":["string","null"],"format":"uri","description":"Order item image (may differ from product image)"},"attributes":{"type":["object","null"],"description":"Item-specific attributes (e.g., trade-in inquiry data)"},"attributes_kwargs":{"type":["object","null"],"description":"Attribute configuration parameters"},"extra_field":{"type":["object","null"],"description":"Additional item data"},"cancellationrequest_set":{"type":"array","items":{"$ref":"#/components/schemas/CancellationRequest"}},"active_cancellation_request":{"oneOf":[{"$ref":"#/components/schemas/CancellationRequest"},{"type":"null"}],"description":"Most recent active cancellation request if exists"},"available_easy_return_shipping_companies":{"type":"array","items":{"$ref":"#/components/schemas/EasyReturnShippingCompany"},"description":"Available shipping companies for easy return"},"datasource_detailed":{"type":["object","null"],"description":"Data source information (if applicable)"},"extra_product_stock_detailed":{"type":["object","null"],"description":"Extra product stock details (if applicable)"},"extra_product_price_detailed":{"type":["object","null"],"description":"Extra product price details (if applicable)"}}},"UserOrderProduct":{"type":"object","description":"Product information in order context, including translations and attributes.","properties":{"pk":{"type":"integer","description":"Product ID"},"sku":{"type":"string","description":"Stock keeping unit"},"base_code":{"type":"string","description":"Product base code"},"name":{"type":"string","description":"Product name (translated)"},"image":{"type":["string","null"],"format":"uri","description":"Product image URL"},"absolute_url":{"type":"string","description":"Product detail page URL"},"attributes":{"type":"object","description":"Product attributes as key-value pairs"},"attributes_kwargs":{"type":"object","description":"Attribute configuration parameters"},"form_schema":{"type":"array","description":"Form configuration for product attributes"},"data_source":{"type":["object","null"],"description":"Data source information"},"extra_attributes":{"type":"object","description":"Additional product attributes"},"category":{"type":["object","null"],"description":"Main category information"},"attribute_set":{"type":"array","description":"Product attribute set"}}},"ShippingOptionGroup":{"type":"object","description":"Shipping option group information for order item","properties":{"pk":{"type":"integer","description":"Shipping option group ID"},"amount":{"type":"string","description":"Shipping amount"},"shipping_option_name":{"type":"string","description":"Name of shipping option"},"shipping_option_logo":{"type":["string","null"],"format":"uri","description":"Logo/icon of shipping option"}}},"CancellationRequest":{"type":"object","description":"Cancellation request record (response)","properties":{"pk":{"type":"integer"},"uuid":{"type":"string","format":"uuid","description":"Unique identifier for the cancellation request"},"order_item":{"type":"integer","description":"Order item ID"},"reason":{"type":"integer","description":"Cancellation reason ID"},"cancellation_type":{"$ref":"#/components/schemas/EnumValue"},"status":{"$ref":"#/components/schemas/EnumValue"},"description":{"type":["string","null"],"description":"User-provided cancellation description"},"iban":{"type":["string","null"],"description":"IBAN for refund (for cash payment orders)"},"holder_name":{"type":["string","null"],"description":"Account holder name for refund"},"easy_return":{"oneOf":[{"$ref":"#/components/schemas/CancellationEasyReturn"},{"type":"null"}],"description":"Easy return shipping information (for refund type cancellations)"},"quantity":{"type":["integer","null"],"description":"Quantity being cancelled (for mergeable order items)"},"fully_refund_as_loyalty_money":{"type":["boolean","null"],"description":"Whether refund is issued as loyalty points"},"cancellation_request_image_set":{"type":"array","items":{"$ref":"#/components/schemas/CancellationRequestImage"},"description":"Images attached to the cancellation request"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"}}},"CancellationEasyReturn":{"type":"object","description":"Easy return shipping details","properties":{"shipping_company":{"$ref":"#/components/schemas/EnumValue"},"code":{"type":"string","description":"Easy return code/reference"},"start_date":{"type":["string","null"],"format":"date-time","description":"Pickup window start date"},"end_date":{"type":["string","null"],"format":"date-time","description":"Pickup window end date"},"status":{"$ref":"#/components/schemas/EnumValue"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"tracking_url":{"type":["string","null"],"format":"uri","description":"Shipment tracking URL"},"pickup_date":{"type":["object","null"],"description":"Selected pickup date and time slot","properties":{"date":{"type":"string","format":"date","description":"Pickup date in YYYY-MM-DD format"},"hour_range":{"type":"object","properties":{"start":{"type":"string","description":"Start time in HH:MM format"},"end":{"type":"string","description":"End time in HH:MM format"}}}}}}},"CancellationRequestImage":{"type":"object","description":"Image attached to a cancellation request","properties":{"pk":{"type":"integer"},"cancellation_request":{"type":"integer","description":"Parent cancellation request ID"},"image":{"type":"string","format":"uri","description":"URL to the uploaded image"},"description":{"type":["string","null"],"description":"Optional description for the image"},"is_uploaded_by_user":{"type":"boolean","description":"Whether image was uploaded by user (vs system/admin)"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"}}},"EasyReturnShippingCompany":{"type":"object","description":"Easy return shipping company option","properties":{"pk":{"type":"integer","description":"Shipping company ID"},"shipping_company":{"$ref":"#/components/schemas/EnumValue"},"name":{"type":"string","description":"Shipping company name"}}},"DiscountItem":{"type":"object","description":"Discount applied to an order.","properties":{"name":{"type":"string","description":"Discount name/label"},"amount":{"type":"string","description":"Discount amount"},"created_date":{"type":"string","format":"date-time","description":"When discount was created"},"order_number":{"type":"string","description":"Order number this discount applies to"},"currency":{"$ref":"#/components/schemas/EnumValue"}}},"LoyaltyTransaction":{"type":"object","description":"Loyalty points transaction associated with an order.","properties":{"pk":{"type":"integer","description":"Transaction ID"},"uuid":{"type":"string","format":"uuid","description":"Unique transaction identifier"},"amount":{"type":"string","description":"Loyalty points amount"},"order":{"type":["integer","null"],"description":"Associated order ID"},"user":{"type":["integer","null"],"description":"Associated user ID"},"user_email":{"type":["string","null"],"format":"email","description":"User email for transaction"},"reference":{"type":["string","null"],"description":"Transaction reference"}}}}}}
```

## The UserOrderItem object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"UserOrderItem":{"type":"object","description":"Order item within an order. Includes product details, pricing, status, and cancellation information.","properties":{"pk":{"type":"integer","description":"Order item ID"},"product":{"$ref":"#/components/schemas/UserOrderProduct"},"order":{"type":"integer","description":"Parent order ID"},"price":{"type":"string","description":"Total price for this order item"},"tax_rate":{"type":"string","description":"Tax rate applied"},"retail_price":{"type":["string","null"],"description":"Original retail price before discounts"},"discount_amount":{"type":["string","null"],"description":"Discount applied to this item"},"discounted_price":{"type":"string","description":"Final price after discount (computed field)"},"status":{"$ref":"#/components/schemas/EnumValue"},"price_currency":{"$ref":"#/components/schemas/EnumValue"},"is_cancelled":{"type":"boolean","description":"Whether item is cancelled"},"is_cancellable":{"type":"boolean","description":"Whether item can be cancelled"},"is_refundable":{"type":"boolean","description":"Whether item is eligible for refund"},"is_tradable":{"type":"boolean","description":"Whether item is eligible for trade-in"},"tracking_url":{"type":["string","null"],"format":"uri","description":"Shipment tracking URL for this item"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"invoice_number":{"type":["string","null"],"description":"Invoice number for this item"},"invoice_date":{"type":["string","null"],"format":"date-time","description":"Invoice date"},"e_archive_url":{"type":["string","null"],"format":"uri","description":"E-Archive document URL"},"shipping_company":{"oneOf":[{"$ref":"#/components/schemas/EnumValue"},{"type":"null"}]},"shipping_option_group":{"oneOf":[{"$ref":"#/components/schemas/ShippingOptionGroup"},{"type":"null"}]},"estimated_delivery_date":{"type":["string","null"],"format":"date","description":"Estimated delivery date"},"shipped_date":{"type":["string","null"],"format":"date-time","description":"Date when item was shipped"},"delivered_date":{"type":["string","null"],"format":"date-time","description":"Date when item was delivered"},"image":{"type":["string","null"],"format":"uri","description":"Order item image (may differ from product image)"},"attributes":{"type":["object","null"],"description":"Item-specific attributes (e.g., trade-in inquiry data)"},"attributes_kwargs":{"type":["object","null"],"description":"Attribute configuration parameters"},"extra_field":{"type":["object","null"],"description":"Additional item data"},"cancellationrequest_set":{"type":"array","items":{"$ref":"#/components/schemas/CancellationRequest"}},"active_cancellation_request":{"oneOf":[{"$ref":"#/components/schemas/CancellationRequest"},{"type":"null"}],"description":"Most recent active cancellation request if exists"},"available_easy_return_shipping_companies":{"type":"array","items":{"$ref":"#/components/schemas/EasyReturnShippingCompany"},"description":"Available shipping companies for easy return"},"datasource_detailed":{"type":["object","null"],"description":"Data source information (if applicable)"},"extra_product_stock_detailed":{"type":["object","null"],"description":"Extra product stock details (if applicable)"},"extra_product_price_detailed":{"type":["object","null"],"description":"Extra product price details (if applicable)"}}},"UserOrderProduct":{"type":"object","description":"Product information in order context, including translations and attributes.","properties":{"pk":{"type":"integer","description":"Product ID"},"sku":{"type":"string","description":"Stock keeping unit"},"base_code":{"type":"string","description":"Product base code"},"name":{"type":"string","description":"Product name (translated)"},"image":{"type":["string","null"],"format":"uri","description":"Product image URL"},"absolute_url":{"type":"string","description":"Product detail page URL"},"attributes":{"type":"object","description":"Product attributes as key-value pairs"},"attributes_kwargs":{"type":"object","description":"Attribute configuration parameters"},"form_schema":{"type":"array","description":"Form configuration for product attributes"},"data_source":{"type":["object","null"],"description":"Data source information"},"extra_attributes":{"type":"object","description":"Additional product attributes"},"category":{"type":["object","null"],"description":"Main category information"},"attribute_set":{"type":"array","description":"Product attribute set"}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}},"ShippingOptionGroup":{"type":"object","description":"Shipping option group information for order item","properties":{"pk":{"type":"integer","description":"Shipping option group ID"},"amount":{"type":"string","description":"Shipping amount"},"shipping_option_name":{"type":"string","description":"Name of shipping option"},"shipping_option_logo":{"type":["string","null"],"format":"uri","description":"Logo/icon of shipping option"}}},"CancellationRequest":{"type":"object","description":"Cancellation request record (response)","properties":{"pk":{"type":"integer"},"uuid":{"type":"string","format":"uuid","description":"Unique identifier for the cancellation request"},"order_item":{"type":"integer","description":"Order item ID"},"reason":{"type":"integer","description":"Cancellation reason ID"},"cancellation_type":{"$ref":"#/components/schemas/EnumValue"},"status":{"$ref":"#/components/schemas/EnumValue"},"description":{"type":["string","null"],"description":"User-provided cancellation description"},"iban":{"type":["string","null"],"description":"IBAN for refund (for cash payment orders)"},"holder_name":{"type":["string","null"],"description":"Account holder name for refund"},"easy_return":{"oneOf":[{"$ref":"#/components/schemas/CancellationEasyReturn"},{"type":"null"}],"description":"Easy return shipping information (for refund type cancellations)"},"quantity":{"type":["integer","null"],"description":"Quantity being cancelled (for mergeable order items)"},"fully_refund_as_loyalty_money":{"type":["boolean","null"],"description":"Whether refund is issued as loyalty points"},"cancellation_request_image_set":{"type":"array","items":{"$ref":"#/components/schemas/CancellationRequestImage"},"description":"Images attached to the cancellation request"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"}}},"CancellationEasyReturn":{"type":"object","description":"Easy return shipping details","properties":{"shipping_company":{"$ref":"#/components/schemas/EnumValue"},"code":{"type":"string","description":"Easy return code/reference"},"start_date":{"type":["string","null"],"format":"date-time","description":"Pickup window start date"},"end_date":{"type":["string","null"],"format":"date-time","description":"Pickup window end date"},"status":{"$ref":"#/components/schemas/EnumValue"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"tracking_url":{"type":["string","null"],"format":"uri","description":"Shipment tracking URL"},"pickup_date":{"type":["object","null"],"description":"Selected pickup date and time slot","properties":{"date":{"type":"string","format":"date","description":"Pickup date in YYYY-MM-DD format"},"hour_range":{"type":"object","properties":{"start":{"type":"string","description":"Start time in HH:MM format"},"end":{"type":"string","description":"End time in HH:MM format"}}}}}}},"CancellationRequestImage":{"type":"object","description":"Image attached to a cancellation request","properties":{"pk":{"type":"integer"},"cancellation_request":{"type":"integer","description":"Parent cancellation request ID"},"image":{"type":"string","format":"uri","description":"URL to the uploaded image"},"description":{"type":["string","null"],"description":"Optional description for the image"},"is_uploaded_by_user":{"type":"boolean","description":"Whether image was uploaded by user (vs system/admin)"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"}}},"EasyReturnShippingCompany":{"type":"object","description":"Easy return shipping company option","properties":{"pk":{"type":"integer","description":"Shipping company ID"},"shipping_company":{"$ref":"#/components/schemas/EnumValue"},"name":{"type":"string","description":"Shipping company name"}}}}}}
```

## The UserOldOrder object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"UserOldOrder":{"type":"object","description":"Archived order from legacy systems with basic order information.","properties":{"pk":{"type":"integer"},"number":{"type":"string","description":"Order number (unique identifier)"},"user_email":{"type":"string","format":"email","description":"User email associated with order"},"status":{"type":"string","description":"Order status (stored as plain string from legacy system)"},"created_date":{"type":"string","format":"date-time"},"amount":{"type":"string","description":"Order total amount"},"discount_amount":{"type":"string","description":"Total discount applied"},"currency":{"$ref":"#/components/schemas/EnumValue"},"payment_type":{"type":["string","null"],"description":"Payment type from legacy system"},"bank":{"type":["string","null"],"description":"Bank name from legacy system"},"installment_count":{"type":"integer","description":"Number of installments"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"shipping_company":{"oneOf":[{"$ref":"#/components/schemas/EnumValue"},{"type":"null"}]},"shipping_address":{"type":["string","null"],"description":"Shipping address (stored as plain text from legacy system)"},"billing_address":{"type":["string","null"],"description":"Billing address (stored as plain text from legacy system)"},"extra_field":{"type":"object","description":"Additional legacy data"},"oldorderitem_set":{"type":"array","items":{"$ref":"#/components/schemas/UserOldOrderItem"}}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}},"UserOldOrderItem":{"type":"object","description":"Item within an old/archived order","properties":{"pk":{"type":"integer"},"product":{"type":["string","null"],"description":"Product name/identifier"},"sku":{"type":["string","null"]},"quantity":{"type":["integer","null"]},"price":{"type":"string","description":"Item price"},"image":{"type":["string","null"],"format":"uri","description":"Product image URL (from uploaded image or derived from image_url)"},"image_url":{"type":["string","null"],"format":"uri","description":"Original image URL from legacy system"},"extra_field":{"type":"object","description":"Additional legacy data"}}}}}}
```

## The UserOldOrderItem object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"UserOldOrderItem":{"type":"object","description":"Item within an old/archived order","properties":{"pk":{"type":"integer"},"product":{"type":["string","null"],"description":"Product name/identifier"},"sku":{"type":["string","null"]},"quantity":{"type":["integer","null"]},"price":{"type":"string","description":"Item price"},"image":{"type":["string","null"],"format":"uri","description":"Product image URL (from uploaded image or derived from image_url)"},"image_url":{"type":["string","null"],"format":"uri","description":"Original image URL from legacy system"},"extra_field":{"type":"object","description":"Additional legacy data"}}}}}}
```

## The AnonymousOrderQuery object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"AnonymousOrderQuery":{"type":"object","required":["number","email"],"properties":{"number":{"type":"string","description":"Order number"},"email":{"type":"string","format":"email","description":"Email address used for the order (must match)"}}}}}}
```

## The AnonymousCancellationRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"AnonymousCancellationRequest":{"type":"object","required":["number","email","order_item","reason","cancellation_type"],"properties":{"number":{"type":"string","description":"Order number"},"email":{"type":"string","format":"email","description":"Email address (must match order)"},"order_item":{"type":"integer","description":"Order item ID to cancel"},"reason":{"type":"integer","description":"Cancellation reason ID"},"cancellation_type":{"type":"string","enum":["cancel","refund"],"description":"Type of cancellation.\n- cancel: Simple cancellation\n- refund: Cancellation with refund (easy return)"},"description":{"type":"string","description":"Optional cancellation description"},"shipping_company":{"type":"integer","description":"Easy return shipping company ID (required for refund type).\nMust be an active EasyReturnShippingCompany."},"pickup_date":{"type":"object","description":"Pickup date and time slot information for easy return shipping.\n\n**Required for**: Refund-type cancellations when using easy return.\n\n**How to obtain available time slots:**\nCall the appointment dates endpoint: `POST /shippings/easy-return-appointment-dates`\n\nRequest body:\n- shipping_company: The easy return shipping company ID (integer)\n- pickup_address: Customer's address ID for pickup (integer)\n- start_datetime: Start of date range (YYYY-MM-DD)\n- end_datetime: End of date range (YYYY-MM-DD)\n\nResponse: Array of available dates, each containing:\n- date: Available pickup date (YYYY-MM-DD)\n- hourRanges: Array of time slots with {start, end} times in HH:MM format\n\nSelect one date and one hour_range from this response to populate this field.\n\n**Data Structure:**\nThis field stores the selected pickup appointment as a JSON object.","properties":{"date":{"type":"string","format":"date","description":"Pickup date in YYYY-MM-DD format.\nMust be one of the available dates returned from the appointment dates query."},"hour_range":{"type":"object","description":"Time slot for pickup.\nMust be one of the hourRanges returned for the selected date from the appointment dates query.","required":["start","end"],"properties":{"start":{"type":"string","description":"Start time of pickup window in HH:MM format (24-hour).\nObtained from the shipping company's available time slots."},"end":{"type":"string","description":"End time of pickup window in HH:MM format (24-hour).\nObtained from the shipping company's available time slots."}}}}},"quantity":{"type":"integer","minimum":1,"description":"Quantity to cancel (for mergeable order items).\nCannot exceed order item quantity."},"iban":{"type":"string","maxLength":34,"description":"IBAN for refund (for cash payment orders)"},"holder_name":{"type":"string","maxLength":255,"description":"Account holder name for refund"},"cancellation_request_image_set":{"type":"array","description":"Images for cancellation request (e.g., product damage photos).\nImages must be Base64 encoded strings.\nMaximum count per item controlled by CANCELLATION_REQUEST_MAX_IMAGE_COUNT_PER_ORDER_ITEM setting.","items":{"type":"object","required":["image"],"properties":{"image":{"type":"string","description":"Base64 encoded image data.\nFormat: \"data:image/jpeg;base64,/9j/4AAQSkZJRg...\" or just the Base64 string without prefix.\nSupported formats: JPEG, PNG, GIF, etc."},"description":{"type":"string","description":"Optional description for the image"}}}}}}}}}
```

## The AnonymousBulkCancellationRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"AnonymousBulkCancellationRequest":{"type":"object","required":["number","email","cancel_order_items"],"properties":{"number":{"type":"string","description":"Order number"},"email":{"type":"string","format":"email","description":"Email address (must match order)"},"cancel_order_items":{"type":"array","minItems":1,"description":"Array of order items to cancel","items":{"type":"object","required":["order_item","reason","cancellation_type"],"properties":{"order_item":{"type":"integer","description":"Order item ID"},"reason":{"type":"integer","description":"Cancellation reason ID"},"cancellation_type":{"type":"string","enum":["cancel","refund"],"description":"Type of cancellation (cancel or refund)"},"description":{"type":"string","description":"Optional cancellation description"},"shipping_company":{"type":"integer","description":"Easy return shipping company ID (required for refund type)"},"pickup_date":{"type":"object","description":"Pickup date and time slot for easy return.\n\n**Required for**: Refund-type cancellations.\n\n**Obtaining available time slots:**\nEndpoint: `POST /shippings/easy-return-appointment-dates`\n\nRequest: shipping_company (ID), pickup_address (ID), \nstart_datetime (YYYY-MM-DD), end_datetime (YYYY-MM-DD)\n\nResponse: Array of {date, hourRanges[{start, end}]}\n\nSelect one date and hour_range from the response for this field.","properties":{"date":{"type":"string","format":"date","description":"Pickup date (must be from available dates returned by appointment query)"},"hour_range":{"type":"object","description":"Pickup time window (must be from hourRanges returned for the selected date)","required":["start","end"],"properties":{"start":{"type":"string","description":"Start time in HH:MM format"},"end":{"type":"string","description":"End time in HH:MM format"}}}}},"quantity":{"type":"integer","minimum":1,"description":"Quantity to cancel (for mergeable items)"},"iban":{"type":"string","maxLength":34,"description":"IBAN for refund"},"holder_name":{"type":"string","maxLength":255,"description":"Account holder name"},"cancellation_request_image_set":{"type":"array","description":"Images for this cancellation request.\nImages must be Base64 encoded.\nMaximum count controlled by CANCELLATION_REQUEST_MAX_IMAGE_COUNT_PER_ORDER_ITEM setting.","items":{"type":"object","required":["image"],"properties":{"image":{"type":"string","description":"Base64 encoded image data.\nFormat: \"data:image/jpeg;base64,...\" or raw Base64 string."},"description":{"type":"string","description":"Optional image description"}}}}}}},"pickup_address":{"type":"integer","description":"Optional shared pickup address ID for all items.\nMust be a customer address belonging to the user."},"fully_refund_as_loyalty_money":{"type":"boolean","default":false,"description":"Whether to refund entire amount as loyalty points"}}}}}}
```

## The CancellationRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"CancellationRequest":{"type":"object","description":"Cancellation request record (response)","properties":{"pk":{"type":"integer"},"uuid":{"type":"string","format":"uuid","description":"Unique identifier for the cancellation request"},"order_item":{"type":"integer","description":"Order item ID"},"reason":{"type":"integer","description":"Cancellation reason ID"},"cancellation_type":{"$ref":"#/components/schemas/EnumValue"},"status":{"$ref":"#/components/schemas/EnumValue"},"description":{"type":["string","null"],"description":"User-provided cancellation description"},"iban":{"type":["string","null"],"description":"IBAN for refund (for cash payment orders)"},"holder_name":{"type":["string","null"],"description":"Account holder name for refund"},"easy_return":{"oneOf":[{"$ref":"#/components/schemas/CancellationEasyReturn"},{"type":"null"}],"description":"Easy return shipping information (for refund type cancellations)"},"quantity":{"type":["integer","null"],"description":"Quantity being cancelled (for mergeable order items)"},"fully_refund_as_loyalty_money":{"type":["boolean","null"],"description":"Whether refund is issued as loyalty points"},"cancellation_request_image_set":{"type":"array","items":{"$ref":"#/components/schemas/CancellationRequestImage"},"description":"Images attached to the cancellation request"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}},"CancellationEasyReturn":{"type":"object","description":"Easy return shipping details","properties":{"shipping_company":{"$ref":"#/components/schemas/EnumValue"},"code":{"type":"string","description":"Easy return code/reference"},"start_date":{"type":["string","null"],"format":"date-time","description":"Pickup window start date"},"end_date":{"type":["string","null"],"format":"date-time","description":"Pickup window end date"},"status":{"$ref":"#/components/schemas/EnumValue"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"tracking_url":{"type":["string","null"],"format":"uri","description":"Shipment tracking URL"},"pickup_date":{"type":["object","null"],"description":"Selected pickup date and time slot","properties":{"date":{"type":"string","format":"date","description":"Pickup date in YYYY-MM-DD format"},"hour_range":{"type":"object","properties":{"start":{"type":"string","description":"Start time in HH:MM format"},"end":{"type":"string","description":"End time in HH:MM format"}}}}}}},"CancellationRequestImage":{"type":"object","description":"Image attached to a cancellation request","properties":{"pk":{"type":"integer"},"cancellation_request":{"type":"integer","description":"Parent cancellation request ID"},"image":{"type":"string","format":"uri","description":"URL to the uploaded image"},"description":{"type":["string","null"],"description":"Optional description for the image"},"is_uploaded_by_user":{"type":"boolean","description":"Whether image was uploaded by user (vs system/admin)"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"}}}}}}
```

## The CancellationEasyReturn object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"CancellationEasyReturn":{"type":"object","description":"Easy return shipping details","properties":{"shipping_company":{"$ref":"#/components/schemas/EnumValue"},"code":{"type":"string","description":"Easy return code/reference"},"start_date":{"type":["string","null"],"format":"date-time","description":"Pickup window start date"},"end_date":{"type":["string","null"],"format":"date-time","description":"Pickup window end date"},"status":{"$ref":"#/components/schemas/EnumValue"},"tracking_number":{"type":["string","null"],"description":"Shipment tracking number"},"tracking_url":{"type":["string","null"],"format":"uri","description":"Shipment tracking URL"},"pickup_date":{"type":["object","null"],"description":"Selected pickup date and time slot","properties":{"date":{"type":"string","format":"date","description":"Pickup date in YYYY-MM-DD format"},"hour_range":{"type":"object","properties":{"start":{"type":"string","description":"Start time in HH:MM format"},"end":{"type":"string","description":"End time in HH:MM format"}}}}}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}}}}}
```

## The CancellationRequestImage object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"CancellationRequestImage":{"type":"object","description":"Image attached to a cancellation request","properties":{"pk":{"type":"integer"},"cancellation_request":{"type":"integer","description":"Parent cancellation request ID"},"image":{"type":"string","format":"uri","description":"URL to the uploaded image"},"description":{"type":["string","null"],"description":"Optional description for the image"},"is_uploaded_by_user":{"type":"boolean","description":"Whether image was uploaded by user (vs system/admin)"},"created_date":{"type":"string","format":"date-time"},"modified_date":{"type":"string","format":"date-time"}}}}}}
```

## The UsersUnsubscriptionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"UsersUnsubscriptionRequest":{"type":"object","required":["service_name","hash_value","request_datetime","unsubscribed_users"],"properties":{"service_name":{"type":"string","maxLength":20,"description":"Identifier for the calling service. Must match a configured subscription gateway\nin `ACTIVE_SUBSCRIPTION_GATEWAYS` or `SUBSCRIPTION_GATEWAY` dynamic settings."},"hash_value":{"type":"string","description":"HMAC hash for request validation. Generated by the subscription gateway's\n`get_unsubscription_hash(request_datetime)` method. Algorithm depends on gateway implementation."},"request_datetime":{"type":"string","format":"date-time","description":"Request timestamp in ISO format. Must be within 1 minute of server time\nto be valid (time gap validated as: (now - request_datetime).seconds / 60 < 1)."},"unsubscribed_users":{"type":"array","minItems":1,"maxItems":100,"items":{"$ref":"#/components/schemas/UserUnsubscription"}}}},"UserUnsubscription":{"type":"object","required":["email"],"properties":{"email":{"type":"string","format":"email","description":"User email address. Matches against primary email or verified email addresses.\nCan match multiple verified email entries for the same user."},"email_allowed":{"type":"boolean","description":"Set email communication preference. Only `False` value will update the user.\nIf `True` or omitted, no change is made to user's email_allowed field."},"sms_allowed":{"type":"boolean","description":"Set SMS communication preference. Only `False` value will update the user.\nIf `True` or omitted, no change is made to user's sms_allowed field."},"call_allowed":{"type":"boolean","description":"Set call communication preference. Only `False` value will update the user.\nIf `True` or omitted, no change is made to user's call_allowed field."}}}}}}
```

## The UserUnsubscription object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"UserUnsubscription":{"type":"object","required":["email"],"properties":{"email":{"type":"string","format":"email","description":"User email address. Matches against primary email or verified email addresses.\nCan match multiple verified email entries for the same user."},"email_allowed":{"type":"boolean","description":"Set email communication preference. Only `False` value will update the user.\nIf `True` or omitted, no change is made to user's email_allowed field."},"sms_allowed":{"type":"boolean","description":"Set SMS communication preference. Only `False` value will update the user.\nIf `True` or omitted, no change is made to user's sms_allowed field."},"call_allowed":{"type":"boolean","description":"Set call communication preference. Only `False` value will update the user.\nIf `True` or omitted, no change is made to user's call_allowed field."}}}}}}
```

## The KvkkUsersUnsubscriptionRequest object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"KvkkUsersUnsubscriptionRequest":{"type":"object","required":["service_name","hash_value","request_datetime","unsubscribed_users"],"properties":{"service_name":{"type":"string","maxLength":20,"description":"Identifier for the calling service. Must have a corresponding secret key\nin `KVKK_UNSUBSCRIPTION_SECRET_MAP` setting."},"hash_value":{"type":"string","description":"KVKK-specific SHA-256 hash for request validation.\nCalculated as: `sha256(secret_key + request_datetime.isoformat()).hexdigest()`\nwhere secret_key is retrieved from KVKK_UNSUBSCRIPTION_SECRET_MAP[service_name]."},"request_datetime":{"type":"string","format":"date-time","description":"Request timestamp in ISO format. Must be within 1 minute of server time\n(time gap validated as: (now - request_datetime).seconds / 60 < 1)."},"unsubscribed_users":{"type":"array","minItems":1,"maxItems":100,"items":{"$ref":"#/components/schemas/KvkkUserUnsubscription"}}}},"KvkkUserUnsubscription":{"type":"object","description":"User identification for KVKK unsubscription.\nMust provide either email OR phone, not both.\n\nAt least one permission field (email_allowed, sms_allowed, call_allowed) \nshould be set to False to trigger an update. Fields set to True are ignored.","properties":{"phone":{"type":"string","description":"User phone number (alternative to email)"},"email":{"type":"string","format":"email","description":"User email (alternative to phone)"},"email_allowed":{"type":"boolean","description":"Set email communication preference"},"sms_allowed":{"type":"boolean","description":"Set SMS communication preference"},"call_allowed":{"type":"boolean","description":"Set call communication preference"}}}}}}
```

## The KvkkUserUnsubscription object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"KvkkUserUnsubscription":{"type":"object","description":"User identification for KVKK unsubscription.\nMust provide either email OR phone, not both.\n\nAt least one permission field (email_allowed, sms_allowed, call_allowed) \nshould be set to False to trigger an update. Fields set to True are ignored.","properties":{"phone":{"type":"string","description":"User phone number (alternative to email)"},"email":{"type":"string","format":"email","description":"User email (alternative to phone)"},"email_allowed":{"type":"boolean","description":"Set email communication preference"},"sms_allowed":{"type":"boolean","description":"Set SMS communication preference"},"call_allowed":{"type":"boolean","description":"Set call communication preference"}}}}}}
```

## The Address object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"Address":{"type":"object","description":"Address details with location references","properties":{"pk":{"type":"integer"},"email":{"type":["string","null"],"format":"email"},"phone_number":{"type":"string"},"first_name":{"type":"string"},"last_name":{"type":"string"},"country":{"$ref":"#/components/schemas/LocationSummary"},"city":{"$ref":"#/components/schemas/LocationSummary"},"line":{"type":"string","description":"Full address line"},"title":{"type":"string","description":"Address title/label"},"township":{"oneOf":[{"$ref":"#/components/schemas/LocationSummary"},{"type":"null"}]},"district":{"oneOf":[{"$ref":"#/components/schemas/LocationSummary"},{"type":"null"}]},"postcode":{"type":["string","null"]},"notes":{"type":["string","null"],"description":"Additional delivery instructions"},"company_name":{"type":["string","null"],"description":"Company name for corporate addresses"},"tax_office":{"type":["string","null"]},"tax_no":{"type":["string","null"]},"e_bill_taxpayer":{"type":["boolean","null"],"description":"E-bill taxpayer status"},"hash_data":{"type":"string","description":"Address hash for deduplication"},"address_type":{"$ref":"#/components/schemas/EnumValue"},"retail_store":{"oneOf":[{"type":"object","description":"Retail store details for store pickup addresses"},{"type":"null"}]},"remote_id":{"type":["string","null"],"description":"Remote system identifier"},"identity_number":{"type":["string","null"],"description":"Identity/tax number"},"extra_field":{"type":["object","null"],"description":"Additional custom fields"},"user":{"type":["integer","null"],"description":"User ID who owns this address"},"is_corporate":{"type":["boolean","null"],"description":"Whether this is a corporate address"},"primary":{"type":["boolean","null"],"description":"Whether this is the primary address"}}},"LocationSummary":{"type":"object","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"code":{"type":"string"}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}}}}}
```

## The LocationSummary object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"LocationSummary":{"type":"object","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"code":{"type":"string"}}}}}}
```

## The ProductSummary object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"ProductSummary":{"type":"object","description":"Basic product information in order context","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"sku":{"type":"string"},"base_code":{"type":"string"},"absolute_url":{"type":"string","format":"uri"},"productimage_set":{"type":"array","items":{"type":"object","properties":{"pk":{"type":"integer"},"image":{"type":"string","format":"uri"}}}}}}}}}
```

## The PaymentOptionSummary object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"PaymentOptionSummary":{"type":"object","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"payment_type":{"type":"string"},"slug":{"type":"string"}}}}}}
```

## The BankSummary object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"BankSummary":{"type":"object","description":"Bank information for payment","properties":{"pk":{"type":"integer"},"name":{"type":"string"},"slug":{"type":"string"},"logo":{"type":["string","null"],"format":"uri","description":"Bank logo image URL"},"logo_path":{"type":["string","null"],"description":"Alternative path for bank logo"}}}}}}
```

## The DiscountItem object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"DiscountItem":{"type":"object","description":"Discount applied to an order.","properties":{"name":{"type":"string","description":"Discount name/label"},"amount":{"type":"string","description":"Discount amount"},"created_date":{"type":"string","format":"date-time","description":"When discount was created"},"order_number":{"type":"string","description":"Order number this discount applies to"},"currency":{"$ref":"#/components/schemas/EnumValue"}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}}}}}
```

## The LoyaltyTransaction object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"LoyaltyTransaction":{"type":"object","description":"Loyalty points transaction associated with an order.","properties":{"pk":{"type":"integer","description":"Transaction ID"},"uuid":{"type":"string","format":"uuid","description":"Unique transaction identifier"},"amount":{"type":"string","description":"Loyalty points amount"},"order":{"type":["integer","null"],"description":"Associated order ID"},"user":{"type":["integer","null"],"description":"Associated user ID"},"user_email":{"type":["string","null"],"format":"email","description":"User email for transaction"},"reference":{"type":["string","null"],"description":"Transaction reference"}}}}}}
```

## The UserOrderProduct object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"UserOrderProduct":{"type":"object","description":"Product information in order context, including translations and attributes.","properties":{"pk":{"type":"integer","description":"Product ID"},"sku":{"type":"string","description":"Stock keeping unit"},"base_code":{"type":"string","description":"Product base code"},"name":{"type":"string","description":"Product name (translated)"},"image":{"type":["string","null"],"format":"uri","description":"Product image URL"},"absolute_url":{"type":"string","description":"Product detail page URL"},"attributes":{"type":"object","description":"Product attributes as key-value pairs"},"attributes_kwargs":{"type":"object","description":"Attribute configuration parameters"},"form_schema":{"type":"array","description":"Form configuration for product attributes"},"data_source":{"type":["object","null"],"description":"Data source information"},"extra_attributes":{"type":"object","description":"Additional product attributes"},"category":{"type":["object","null"],"description":"Main category information"},"attribute_set":{"type":"array","description":"Product attribute set"}}}}}}
```

## The ShippingOptionGroup object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"ShippingOptionGroup":{"type":"object","description":"Shipping option group information for order item","properties":{"pk":{"type":"integer","description":"Shipping option group ID"},"amount":{"type":"string","description":"Shipping amount"},"shipping_option_name":{"type":"string","description":"Name of shipping option"},"shipping_option_logo":{"type":["string","null"],"format":"uri","description":"Logo/icon of shipping option"}}}}}}
```

## The EasyReturnShippingCompany object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"EasyReturnShippingCompany":{"type":"object","description":"Easy return shipping company option","properties":{"pk":{"type":"integer","description":"Shipping company ID"},"shipping_company":{"$ref":"#/components/schemas/EnumValue"},"name":{"type":"string","description":"Shipping company name"}}},"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}}}}}
```

## The EnumValue object

```json
{"openapi":"3.1.0","info":{"title":"Users API - Authentication, Password, Orders, and Hooks","version":"1.0.0"},"components":{"schemas":{"EnumValue":{"type":"object","description":"Enum representation with value and label","properties":{"value":{"type":"string","description":"Enum internal value"},"label":{"type":"string","description":"Human-readable label"}}}}}}
```
