{"openapi":"3.1.0","info":{"title":"MarketCoop API","summary":"MarketCoop","description":"Cooperative Marketplace API","version":"1.0.0"},"paths":{"/v1":{"get":{"tags":["System"],"summary":"List Api Endpoint","description":"Return API status and list of all available endpoints.\n\nUsed for discovering available routes and system health monitoring.\nResponse includes API version, status, and full endpoint details.","operationId":"list_api_endpoint_v1_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/APIStatus"}}}}}}},"/v1/health":{"get":{"tags":["System"],"summary":"Health Check Endpoint","description":"Check the health of the API and system resources.\n\nReturns CPU usage, memory usage, and process memory statistics.\nUsed for liveness probes and monitoring.","operationId":"health_check_endpoint_v1_health_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HealthCheck"}}}}}}},"/v1/token":{"post":{"tags":["Access Token"],"summary":"User Authentication","description":"Secure staff authentication with Coopenomics signature verification and token issuance.\n\nThe user must:\n1. Get account info from Coopenomics\n2. Create a message (current datetime string) to sign\n3. Sign the message with their private key\n4. Submit account, public key, signature, and message\n\nReturns access and refresh tokens on success.","operationId":"get_access_token_endpoint_v1_token_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthRequest"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/token/refresh":{"post":{"tags":["Access Token"],"summary":"Refresh Access Token","description":"Exchange a valid refresh token for new access + refresh tokens.\nSubmit a valid (non-revoked) access token to receive new tokens.\n\n**Security:**\n- Refresh token must be non-revoked and non-expired\n- Old refresh token is revoked (rotation)\n- New tokens issued with updated context","operationId":"refresh_token_endpoint_v1_token_refresh_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenInput"}}},"required":true},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/auth/me":{"get":{"tags":["Authentication"],"summary":"Current user info","description":"Get information about the current authenticated user.","operationId":"get_current_user_endpoint_v1_auth_me_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AuthenticatedUser"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/auth":{"get":{"tags":["Authentication"],"summary":"Current user info (legacy)","description":"Legacy endpoint for current user info.\nUse GET /me instead.","operationId":"current_user_endpoint_v1_auth_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{}}}}},"deprecated":true,"security":[{"HTTPBearer":[]}]}},"/v1/auth/token":{"get":{"tags":["Authentication"],"summary":"Information about the current token","description":"Get full information about the current token.","operationId":"current_token_endpoint_v1_auth_token_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenInfoResponse"}}}}},"security":[{"HTTPBearer":[]}]},"delete":{"tags":["Authentication"],"summary":"Revoke specific token","description":"Revoke a specific token by ID.\n\nPOST Args:\n        token: Token ID or Access Token\n\nRequires CHAIRMAN position or token owner.\nUsed for administrative token management.","operationId":"revoke_token_v1_auth_token_delete","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/auth/token/all":{"delete":{"tags":["Authentication"],"summary":"Revoke all other tokens","description":"Revoke other user tokens except the current one.","operationId":"clear_tokens_endpoint_v1_auth_token_all_delete","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/auth/logout":{"post":{"tags":["Authentication"],"summary":"Revoke current token","description":"Revoke the current access token.\n\nNote: This only revokes the specific token provided.\nFor full logout (all devices), use /auth/logout/all.","operationId":"logout_endpoint_v1_auth_logout_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/auth/logout/all":{"post":{"tags":["Authentication"],"summary":"Revoke all tokens","description":"Revoke all tokens for the authenticated user.\n\nUse when:\n- User changes password\n- Security breach suspected\n- User logs out from all devices","operationId":"revoke_tokens_endpoint_v1_auth_logout_all_post","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/division":{"post":{"tags":["Division Management"],"summary":"Create division","description":"Create a new division within an organization.\n\nRequirements:\n- User must have at least MANAGER access to the organization\n- Slug must be unique","operationId":"create_division_endpoint_v1_division_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DivisionInput"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DivisionSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Division Management"],"summary":"Division List","description":"List all divisions accessible to the authenticated user.\n\nQuery params:\n- include_inactive: include deactivated divisions\n- skip: pagination offset\n- limit: max results per page\nReturns divisions with basic information.","operationId":"list_divisions_endpoint_v1_division_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/DivisionSchema"},"title":"Response List Divisions Endpoint V1 Division Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/division/search":{"post":{"tags":["Division Management"],"summary":"Search Division","description":"Search divisions by filter criteria with advanced options.\n\nSupported search filters via payload:\n- staff_id: filter divisions containing specific staff member\n- user_id: filter divisions for a specific user\n- shop_id: filter divisions containing a specific shop\nRequires appropriate permissions based on filters used.","operationId":"search_divisions_endpoint_v1_division_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/DivisionSchema"},"type":"array","title":"Response Search Divisions Endpoint V1 Division Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/division/{identifier}":{"get":{"tags":["Division Management"],"summary":"Get Division Info","description":"Get division information by identifier.\n\nArgs:\nidentifier: UUID or slug of the division","operationId":"get_division_endpoint_v1_division__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DivisionExtendedSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Division Management"],"summary":"Update division","description":"Update an existing division.\n\nArgs:\nidentifier: UUID or slug of the organization","operationId":"update_division_endpoint_v1_division__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/DivisionInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/DivisionSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Division Management"],"summary":"Delete division","description":"Deactivate a division (soft delete) by identifier.\n\nPath param: identifier - UUID or slug of the division\nDivision is marked inactive but retained for historical records.\nRequires CHAIRMAN permissions in the division.","operationId":"deactivate_division_endpoint_v1_division__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/division/{identifier}/members":{"get":{"tags":["Division Management"],"summary":"Delete division","description":"List all staff members belonging to a division.\n\nPath param: identifier - UUID or slug of the division\nReturns list of staff with their positions and roles within the division.","operationId":"member_list_by_division_endpoint_v1_division__identifier__members_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StaffSchema"},"title":"Response Member List By Division Endpoint V1 Division  Identifier  Members Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/organization":{"post":{"tags":["Organization"],"summary":"Create Organization","description":"Create a new organization.\nAuthenticated user will automatically get CHAIRMAN access rights.","operationId":"create_organization_endpoint_v1_organization_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Organization"],"summary":"Organization list","description":"Get all organizations.","operationId":"list_organizations_endpoint_v1_organization_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrganizationSchema"},"title":"Response List Organizations Endpoint V1 Organization Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/organization/search":{"post":{"tags":["Organization"],"summary":"Search Organization","description":"Search all user's organizations.\n\nMay apply additional filters:\n        - `date_from`: Organization registration date start period\n        - `date_to`: Organization registration date end period\n        - `staff_id`: Search organizations for specific staff\n        - `user_id`: Search organizations for specific user\n        - `organization_id`: Search only within the certain Organization\n        - `division_id`: Search only within the certain Division of organization\n        - `shop_id`: Search only within the certain Shop within Division","operationId":"search_organizations_endpoint_v1_organization_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/OrganizationSchema"},"type":"array","title":"Response Search Organizations Endpoint V1 Organization Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/organization/{identifier}":{"get":{"tags":["Organization"],"summary":"Get Organization info","description":"Get detailed information on organization.\n\nArgs:\n        identifier: UUID or slug of the organization","operationId":"get_organization_endpoint_v1_organization__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationExtendedSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Organization"],"summary":"Update Organization","description":"Update organization by identifier.\n\nArgs:\n        identifier: UUID or slug of the organization","operationId":"update_organization_endpoint_v1_organization__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrganizationSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Organization"],"summary":"Delete Organization","description":"Delete organization by identifier.\nOrganization deactivated but remains in database for compatability\n\nArgs:\n        identifier: UUID or slug of the organization","operationId":"deactivate_organization_endpoint_v1_organization__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/staff":{"post":{"tags":["Staff Management"],"summary":"Create Staff","description":"Create a new staff.","operationId":"create_staff_endpoint_v1_staff_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StaffInput"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StaffSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Staff Management"],"summary":"Staff list","description":"Get all staff.","operationId":"list_staff_endpoint_v1_staff_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StaffSchema"},"title":"Response List Staff Endpoint V1 Staff Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/staff/search":{"post":{"tags":["Staff Management"],"summary":"Search Staff","description":"Search all staff position in organizations.\n\nMay apply additional filters:\n        - `staff_id`: Search organizations for specific staff\n        - `organization_id`: Search only within the certain Organization\n        - `division_id`: Search only within the certain Division of organization\n        - `shop_id`: Search only within the certain Shop within Division","operationId":"search_staff_endpoint_v1_staff_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/StaffSchema"},"type":"array","title":"Response Search Staff Endpoint V1 Staff Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/staff/{identifier}":{"get":{"tags":["Staff Management"],"summary":"Get Staff info","description":"Get detailed information on staff.\n\nArgs:\n        identifier: UUID or slug of the staff","operationId":"get_staff_endpoint_v1_staff__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StaffExtendedSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Staff Management"],"summary":"Update Staff","description":"Update staff by identifier.\n\nArgs:\n        identifier: UUID or slug of the staff","operationId":"update_staff_endpoint_v1_staff__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StaffInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StaffSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Staff Management"],"summary":"Delete Staff","description":"Delete staff by identifier.\nStaff deactivated but remains in database for compatability\n\nArgs:\n        identifier: UUID or slug of the staff","operationId":"deactivate_staff_endpoint_v1_staff__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/staff/{identifier}/position":{"post":{"tags":["Staff Management"],"summary":"Change Staff Position","description":"Change staff position.\n\nArgs:\n        identifier: UUID or slug of the staff\n\nPayload:\n        position: one of the Staff position","operationId":"set_staff_position_v1_staff__identifier__position_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StaffPosition"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StaffSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/translate/supported":{"get":{"tags":["Translations"],"summary":"Get supported translatable models and fields","description":"Get a list of all supported models and their translatable fields.","operationId":"get_supported_translations_endpoint_v1_translate_supported_get","responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"additionalProperties":true,"type":"object","title":"Response Get Supported Translations Endpoint V1 Translate Supported Get"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/translate/{model}/{field}/{record_id}":{"get":{"tags":["Translations"],"summary":"Get translations for a specific field","description":"Get translations for a specific field of a model instance.\n\n- **model**: Model name (e.g., 'organization', 'product', 'category')\n- **field**: Field name (e.g., 'shortname', 'name', 'title')\n- **record_id**: UUID of the record","operationId":"list_translations_endpoint_v1_translate__model___field___record_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"model","in":"path","required":true,"schema":{"type":"string","title":"Model"}},{"name":"field","in":"path","required":true,"schema":{"type":"string","title":"Field"}},{"name":"record_id","in":"path","required":true,"schema":{"type":"string","title":"Record Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationGetResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"post":{"tags":["Translations"],"summary":"Merge/update translations for a field","description":"Merge new translations with existing ones for a specific field.\n\n- **model**: Model name (e.g., 'organization', 'product', 'category')\n- **field**: Field name (e.g., 'shortname', 'name', 'title')\n- **record_id**: UUID of the record\n- **translations**: Dictionary of language codes to translation strings","operationId":"update_translations_endpoint_v1_translate__model___field___record_id__post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"model","in":"path","required":true,"schema":{"type":"string","title":"Model"}},{"name":"field","in":"path","required":true,"schema":{"type":"string","title":"Field"}},{"name":"record_id","in":"path","required":true,"schema":{"type":"string","title":"Record Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Translations"],"summary":"Replace all translations for a field","description":"Replace all translations for a specific field (does not merge).\nNote: 'ru' key will always be preserved or set to empty string if not provided.\n\n- **model**: Model name (e.g., 'organization', 'product', 'category')\n- **field**: Field name (e.g., 'shortname', 'name', 'title')\n- **record_id**: UUID of the record\n- **translations**: Dictionary of language codes to translation strings","operationId":"replace_translations_endpoint_v1_translate__model___field___record_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"model","in":"path","required":true,"schema":{"type":"string","title":"Model"}},{"name":"field","in":"path","required":true,"schema":{"type":"string","title":"Field"}},{"name":"record_id","in":"path","required":true,"schema":{"type":"string","title":"Record Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationRequest"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Translations"],"summary":"Delete a specific language translation","description":"Delete a specific language translation from a field.\nNote: The default 'ru' language cannot be deleted.\n\n- **model**: Model name (e.g., 'organization', 'product', 'category')\n- **field**: Field name (e.g., 'shortname', 'name', 'title')\n- **record_id**: UUID of the record\n- **lang**: Language code to delete (query parameter)","operationId":"delete_translation_endpoint_v1_translate__model___field___record_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"model","in":"path","required":true,"schema":{"type":"string","title":"Model"}},{"name":"field","in":"path","required":true,"schema":{"type":"string","title":"Field"}},{"name":"record_id","in":"path","required":true,"schema":{"type":"string","title":"Record Id"}},{"name":"lang","in":"query","required":true,"schema":{"type":"string","description":"ISO 639-1 language code to delete","title":"Lang"},"description":"ISO 639-1 language code to delete"}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TranslationResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/addresses":{"post":{"tags":["Address"],"summary":"Create Address","description":"Create a new address for an organization, division, shop, or staff member.\n\nRequires authentication. Address can be tagged as primary for its entity.\nReturns the created address with assigned UUID.","operationId":"create_address_endpoint_v1_addresses_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddressCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddressSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Address"],"summary":"List Addresses","description":"List all addresses with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: whether to return deactivated addresses\n- skip: pagination offset\n- limit: maximum results per page","operationId":"list_addresses_endpoint_v1_addresses_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/AddressSchema"},"title":"Response List Addresses Endpoint V1 Addresses Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/addresses/{identifier}":{"get":{"tags":["Address"],"summary":"Get Address","description":"Get full address details by UUID or slug.\n\nPath param: identifier - UUID or slug of the address","operationId":"get_address_endpoint_v1_addresses__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddressSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Address"],"summary":"Update Address","description":"Update an existing address by UUID or slug.\n\nPath param: identifier - UUID or slug of the address\nBody: updated address fields (all optional)","operationId":"update_address_endpoint_v1_addresses__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddressInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AddressSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Address"],"summary":"Delete Address","description":"Deactivate an address (soft delete) by UUID or slug.\n\nPath param: identifier - UUID or slug of the address\nRequires CHAIRMAN position on the associated entity.","operationId":"delete_address_endpoint_v1_addresses__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/addresses/search":{"get":{"tags":["Address"],"summary":"Search addresses","description":"Search and filter addresses using complex criteria.\n\nRequest body supports filtering by entity type, entity ID, address type,\nand pagination with include_inactive option.","operationId":"search_address_endpoint_v1_addresses_search_get","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/AddressSchema"},"type":"array","title":"Response Search Address Endpoint V1 Addresses Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/brands":{"post":{"tags":["Brand Management"],"summary":"Create Brand","description":"Create a new brand.\n\nRequirements:\n- Staff must have MANAGER position or higher\n- Brand name must be unique","operationId":"create_brand_endpoint_v1_brands_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandInput"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Brand Management"],"summary":"List Brands","description":"List all brands with optional pagination.\n\nQuery params:\n- include_inactive: include deactivated brands\n- skip: pagination offset\n- limit: max results returned","operationId":"list_brands_endpoint_v1_brands_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/BrandBaseSchema"},"title":"Response List Brands Endpoint V1 Brands Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/brands/search":{"post":{"tags":["Brand Management"],"summary":"Search Brands","description":"Search and filter brands by criteria.","operationId":"search_brands_endpoint_v1_brands_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/BrandSchema"},"type":"array","title":"Response Search Brands Endpoint V1 Brands Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/brands/{identifier}":{"get":{"tags":["Brand Management"],"summary":"Get Brand Info","description":"Get brand information by identifier (UUID or name).","operationId":"get_brand_endpoint_v1_brands__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Brand Management"],"summary":"Update Brand","description":"Update an existing brand.\n\nRequirements:\n- Staff must have MANAGER position or higher","operationId":"update_brand_endpoint_v1_brands__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/BrandSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Brand Management"],"summary":"Delete Brand","description":"Delete a brand. Requires CHAIRMAN permissions.","operationId":"delete_brand_endpoint_v1_brands__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/manufacturers":{"post":{"tags":["Manufacturer"],"summary":"Create Manufacturer","description":"Create a new manufacturer.","operationId":"create_manufacturer_endpoint_v1_manufacturers_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManufacturerCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManufacturerSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Manufacturer"],"summary":"List Manufacturers","description":"List manufacturers with optional organization filter.","operationId":"list_manufacturers_endpoint_v1_manufacturers_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ManufacturerSchema"},"title":"Response List Manufacturers Endpoint V1 Manufacturers Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/manufacturers/search":{"get":{"tags":["Manufacturer"],"summary":"Search manufacturer","description":"Search and filter manufacturers using complex criteria.\n\nRequest body supports filtering by entity type, entity ID, address type,\nand pagination with include_inactive option.","operationId":"search_manufaturer_endpoint_v1_manufacturers_search_get","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ManufacturerSchema"},"type":"array","title":"Response Search Manufaturer Endpoint V1 Manufacturers Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/manufacturers/{identifier}":{"get":{"tags":["Manufacturer"],"summary":"Get Manufacturer","description":"Get detailed information on manufacturer.\n\nArgs:\n        identifier: UUID or slug of the manufacturer","operationId":"get_manufacturer_endpoint_v1_manufacturers__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManufacturerSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Manufacturer"],"summary":"Update Manufacturer","description":"Update an existing manufacturer by UUID or slug.\n\nPath param: identifier - UUID or slug of the manufacturer\nBody: updated manufacturer fields\nRequires MANAGER position or higher.","operationId":"update_manufacturer_endpoint_v1_manufacturers__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManufacturerInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ManufacturerSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Manufacturer"],"summary":"Delete Manufacturer","description":"Delete manufacturer. Requires CHAIRMAN position.","operationId":"delete_manufacturer_endpoint_v1_manufacturers__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/phones":{"post":{"tags":["Phone"],"summary":"Create Phone","description":"Create a new phone number.","operationId":"create_phone_endpoint_v1_phones_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhoneCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhoneSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Phone"],"summary":"List Phones","description":"List phone numbers with optional filters.","operationId":"list_phones_endpoint_v1_phones_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PhoneSchema"},"title":"Response List Phones Endpoint V1 Phones Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/phonessearch":{"post":{"tags":["Phone"],"summary":"Search phones","description":"List phones with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: include voided/cancelled invoices\n- skip: pagination offset\n- limit: max results per page\nReturns phones sorted by creation date (newest first).","operationId":"search_phones_endpoint_v1_phonessearch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/PhoneSchema"},"type":"array","title":"Response Search Phones Endpoint V1 Phonessearch Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/phones/{phone_id}":{"get":{"tags":["Phone"],"summary":"Get Phone","description":"Get phone by UUID.","operationId":"get_phone_endpoint_v1_phones__phone_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"phone_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Phone Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhoneSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Phone"],"summary":"Update Phone","description":"Update phone by UUID.","operationId":"update_phone_endpoint_v1_phones__phone_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"phone_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Phone Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhoneInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhoneSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Phone"],"summary":"Delete Phone","description":"Deactivate phone by UUID.","operationId":"delete_phone_v1_phones__phone_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"phone_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Phone Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/phones/{phone_id}/primary":{"post":{"tags":["Phone"],"summary":"Set Primary Phone","description":"Set phone as primary for its organization.","operationId":"set_phone_primary_endpoint_v1_phones__phone_id__primary_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"phone_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Phone Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PhoneSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/socials":{"post":{"tags":["Social"],"summary":"Create Social","description":"Create a new social media account link.","operationId":"create_social_endpoint_v1_socials_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Social"],"summary":"List Socials","description":"List social accounts with optional filters.","operationId":"list_socials_endpoint_v1_socials_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/SocialSchema"},"title":"Response List Socials Endpoint V1 Socials Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/socials/{identifier}":{"get":{"tags":["Social"],"summary":"Get Social","description":"Get detailed information on social account.\n\nArgs:\n        identifier: UUID or slug of the idenitifier in the format `username@socnet`, where:\n                - `username`: identificator of the user in the social network, account, username and so on.\n                - `socnet`: social network definition, e.g: 'facebook', 'goggle', 'github'.","operationId":"get_social_endpoint_v1_socials__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Social"],"summary":"Update Social","description":"Update an existing social media account link by UUID or slug.\n\nPath param: identifier - UUID or slug of the social account\nBody: updated social fields (username, network, profile URL)\nUsed to correct typos or update linked account after rebranding.","operationId":"update_social_endpoint_v1_socials__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/SocialSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Social"],"summary":"Delete Social","description":"Remove a social media account link by UUID or slug.\n\nPath param: identifier - UUID or slug of the social account\nSoft deletes the link; account association is removed from staff profile.\nDoes not affect the actual social media account.","operationId":"delete_social_endpoint_v1_socials__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/socials/search":{"post":{"tags":["Social"],"summary":"Search Socials","description":"Search socials by filter.","operationId":"search_socials_endpoint_v1_socials_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/SocialSchema"},"type":"array","title":"Response Search Socials Endpoint V1 Socials Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/shops":{"post":{"tags":["Shop"],"summary":"Create Shop","description":"Create a new shop. Requires CHAIRMAN position.","operationId":"create_shop_endpoint_v1_shops_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopInput"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Shop"],"summary":"List Shops","description":"List all shops with optional pagination and filtering.\n\nQuery params:\n- include_inactive: include deactivated shops\n- skip: pagination offset\n- limit: max results per page\nReturns shops with basic organization/division association.","operationId":"list_shops_endpoint_v1_shops_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ShopSchema"},"title":"Response List Shops Endpoint V1 Shops Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/shops/search":{"post":{"tags":["Shop"],"summary":"Search Shops","description":"Search shops by filter.","operationId":"search_shops_endpoint_v1_shops_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ShopSchema"},"type":"array","title":"Response Search Shops Endpoint V1 Shops Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/shops/{identifier}":{"get":{"tags":["Shop"],"summary":"Get Shop","description":"Get full details of a Shop.\n\nArgs:\n        identifier: UUID of the shop or slug\nReturns shop with associated organization, division, address, and contact info.","operationId":"get_shop_endpoint_v1_shops__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Shop"],"summary":"Update Shop","description":"Update an existing shop by UUID or slug.\n\nPath param: identifier - UUID or slug of the shop\nBody: updated shop fields (name, address, contact info, etc.)\nRequires CHAIRMAN position on the parent organization.","operationId":"update_shop_endpoint_v1_shops__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShopSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Shop"],"summary":"Delete Shop","description":"Deactivate a shop (soft delete) by UUID or slug.\n\nPath param: identifier - UUID or slug of the shop\nDoes not delete associated inventory or orders (they remain for audit).\nRequires CHAIRMAN position on parent organization.","operationId":"delete_shop_endpoint_v1_shops__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/products":{"post":{"tags":["Product"],"summary":"Create Product","description":"Create a new product.","operationId":"create_product_endpoint_v1_products_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductInput"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Product"],"summary":"List Products","description":"List products with optional filters.","operationId":"list_products_endpoint_v1_products_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ProductSchema"},"title":"Response List Products Endpoint V1 Products Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/products/search":{"post":{"tags":["Product"],"summary":"Search Products","description":"Search products by filter.","operationId":"search_products_endpoint_v1_products_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ProductSchema"},"type":"array","title":"Response Search Products Endpoint V1 Products Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/products/{identifier}":{"get":{"tags":["Product"],"summary":"Get Product","description":"Get detailed information on product.\n\nArgs:\n        identifier: UUID or slug of the product","operationId":"get_product_endpoint_v1_products__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Product"],"summary":"Update Product","description":"Update an existing product by UUID or slug.\n\nPath param: identifier - UUID or slug of the product\nBody: updated product fields (name, description, category, etc.)\nRequires MANAGER or higher position in the product's shop.","operationId":"update_product_endpoint_v1_products__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ProductSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Product"],"summary":"Delete Product","description":"Deactivate product. Requires CHAIRMAN position.","operationId":"delete_product_endpoint_v1_products__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/stocks":{"post":{"tags":["Stock"],"summary":"Create Stock","description":"Create a new stock entry for a product at a location.\n\nStock represents physical inventory at a specific shop/warehouse.\nTracks SKU, serial numbers, barcodes, and quantity on hand.\nAlso records cost price and batch/lot information if applicable.","operationId":"create_stock_endpoint_v1_stocks_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockInput"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Stock"],"summary":"List Stocks","description":"List stock entries with optional pagination.\n\nQuery params:\n- include_inactive: include deactivated stock records\n- skip: pagination offset\n- limit: max results per page\nReturns stock items sorted by creation date.","operationId":"list_stocks_endpoint_v1_stocks_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/StockSchema"},"title":"Response List Stocks Endpoint V1 Stocks Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/stocks/search":{"post":{"tags":["Stock"],"summary":"Search Stocks","description":"Search stocks by filter.","operationId":"search_stocks_endpoint_v1_stocks_search_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/StockSchema"},"type":"array","title":"Response Search Stocks Endpoint V1 Stocks Search Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/stocks/{identifier}":{"get":{"tags":["Stock"],"summary":"Get Stock","description":"Get full stock details including quantity and reservations.\n\nPath param: identifier - UUID of stock, or search by SKU/serial/barcode\nReturns stock with current quantity, reserved amount, location, and product info.\nIdentifier can be: UUID, SKU number, serial number, or barcode data.","operationId":"get_stock_endpoint_v1_stocks__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Stock"],"summary":"Update Stock","description":"Update stock metadata by UUID or identifier.\n\nPath param: identifier - UUID of stock record\nBody: updated stock fields (location, SKU, serial, barcode, cost price)\nQuantity itself should be adjusted via dedicated /adjust endpoint.","operationId":"update_stock_endpoint_v1_stocks__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Stock"],"summary":"Delete Stock","description":"Permanently delete stock entry. Requires CHAIRMAN position.","operationId":"delete_stock_endpoint_v1_stocks__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/stocks/{identifier}/adjust":{"post":{"tags":["Stock"],"summary":"Adjust Stock Quantity","description":"Adjust stock quantity (positive to add, negative to subtract).","operationId":"set_stor_quantity_endpoint_v1_stocks__identifier__adjust_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockAdjustInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/stocks/{identifier}/reserve":{"post":{"tags":["Stock"],"summary":"Reserve Stock","description":"Reserve a quantity of stock for an order.","operationId":"reserve_stock_qty_endpoint_v1_stocks__identifier__reserve_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuantityStock"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/stocks/{identifier}/release":{"post":{"tags":["Stock"],"summary":"Release Stock Reserve","description":"Release a previously reserved stock quantity.","operationId":"release_stock_qty_endpoint_v1_stocks__identifier__release_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/QuantityStock"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/StockSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/prices":{"post":{"tags":["Price"],"summary":"Create Price","description":"Create a new price for a product.\n\nPrice can be tied to a specific product, variant, or catalog.\nSupports effective date ranges and currency specification.\nMultiple prices per product allowed with different validity periods.","operationId":"create_price_endpoint_v1_prices_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Price"],"summary":"List Prices","description":"List all prices with optional pagination and filtering.\n\nQuery params:\n- include_inactive: include prices not currently effective\n- skip: pagination offset\n- limit: max results per page\nReturns prices sorted by effective date (most recent first).","operationId":"list_prices_endpoint_v1_prices_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PriceSchema"},"title":"Response List Prices Endpoint V1 Prices Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/pricessearch":{"post":{"tags":["Price"],"summary":"Search prices","description":"List prices with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: include voided/cancelled invoices\n- skip: pagination offset\n- limit: max results per page\nReturns prices sorted by creation date (newest first).","operationId":"search_prices_endpoint_v1_pricessearch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/PriceSchema"},"type":"array","title":"Response Search Prices Endpoint V1 Pricessearch Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/prices/{price_id}":{"get":{"tags":["Price"],"summary":"Get Price","description":"Get full price details including product and validity period.\n\nPath param: price_id - UUID of the price record\nReturns price with linked product, currency, and effective date range.","operationId":"get_price_endpoint_v1_prices__price_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"price_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Price Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Price"],"summary":"Update Price","description":"Update an existing price record by UUID.\n\nPath param: price_id - UUID of the price\nBody: updated price fields (amount, currency, validity period)\nRequires MANAGER or higher position.","operationId":"update_price_endpoint_v1_prices__price_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"price_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Price Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PriceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Price"],"summary":"Delete Price","description":"Delete a price record by UUID.\n\nPath param: price_id - UUID of the price\nPrice can only be deleted if it hasn't been used in any transactions.\nRequires CHAIRMAN position.","operationId":"delete_price_endpoint_v1_prices__price_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"price_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Price Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/inventories":{"post":{"tags":["Inventory"],"summary":"Create Inventory","description":"Record a new inventory movement (write-off, receipt, etc.).","operationId":"create_inventory_endpoint_v1_inventories_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InventoryCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InventorySchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Inventory"],"summary":"List Inventory","description":"List inventory records with optional pagination.\n\nInventory records track stock movements (receipts, write-offs, transfers).\nQuery params: include_inactive, skip, limit.","operationId":"list_inventories_endpoint_v1_inventories_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/InventorySchema"},"title":"Response List Inventories Endpoint V1 Inventories Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/inventories/{identifier}":{"get":{"tags":["Inventory"],"summary":"Get Inventory","description":"Get detailed information on inventory.\n\nArgs:\n        identifier: UUID or invid of the inventory","operationId":"get_inventory_endpoint_v1_inventories__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InventorySchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Inventory"],"summary":"Update Inventory","description":"Update an inventory record by UUID.\n\nPath param: identifier - UUID of inventory record\nBody: updated inventory fields (typically limited to notes/comments)\nUpdating is restricted to certain fields and requires appropriate permissions.","operationId":"update_inventory_endpoint_v1_inventories__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InventoryInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InventorySchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Inventory"],"summary":"Delete Inventory","description":"Delete inventory record. Requires CHAIRMAN position.","operationId":"delete_inventory_endpoint_v1_inventories__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/inventories/search":{"get":{"tags":["Inventory"],"summary":"Search inventory","description":"Search and filter inventories using complex criteria.","operationId":"search_inventory_endpoint_v1_inventories_search_get","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/InventorySchema"},"type":"array","title":"Response Search Inventory Endpoint V1 Inventories Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/orders":{"post":{"tags":["Order"],"summary":"Create Order","description":"Create a new customer order.\n\nOrder contains line items referencing products and their quantities.\nCreates inventory reservations and calculates totals.\nRequires appropriate staff permissions in the shop.","operationId":"create_order_endpoint_v1_orders_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderInput"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Order"],"summary":"List Orders","description":"List orders with optional pagination and active status filtering.\n\nQuery params:\n- include_inactive: include cancelled/deleted orders\n- skip: pagination offset\n- limit: max results per page\nReturns orders sorted by creation date descending.","operationId":"list_orders_endpoint_v1_orders_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/OrderSchema"},"title":"Response List Orders Endpoint V1 Orders Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/search":{"get":{"tags":["Order"],"summary":"Search catalogs","description":"Search and filter all orders.","operationId":"search_orders_endpoint_v1_orders_search_get","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/OrderSchema"},"type":"array","title":"Response Search Orders Endpoint V1 Orders Search Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/orders/{order_id}":{"get":{"tags":["Order"],"summary":"Get Order","description":"Get full order details including line items and payment status.\n\nPath param: order_id - UUID of the order\nReturns order with products, quantities, totals, and fulfillment status.","operationId":"get_order_endpoint_v1_orders__order_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Order Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Order"],"summary":"Update Order","description":"Update an existing order by UUID.\n\nPath param: order_id - UUID of the order\nBody: updated order fields (typically limited to metadata after creation)\nModifying line items may be restricted after order is processed.","operationId":"update_order_endpoint_v1_orders__order_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Order Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Order"],"summary":"Delete Order","description":"Permanently delete order. Requires CHAIRMAN position.","operationId":"delete_order_endpoint_v1_orders__order_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Order Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/orders/{order_id}/paid":{"post":{"tags":["Order"],"summary":"Mark Order Paid","description":"Mark an order as paid.","operationId":"set_order_paid_endpoint_v1_orders__order_id__paid_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"order_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Order Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/invoices":{"post":{"tags":["Invoice"],"summary":"Create Invoice","description":"Create a new invoice for a shop's sales or purchases.\n\nInvoice tracks financial transactions between shop and customers/suppliers.\nIncludes line items, totals, tax calculations, and payment status.","operationId":"create_invoice_endpoint_v1_invoices_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Invoice"],"summary":"List Invoices","description":"List invoices with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: include voided/cancelled invoices\n- skip: pagination offset\n- limit: max results per page\nReturns invoices sorted by creation date (newest first).","operationId":"list_invoices_endpoint_v1_invoices_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/InvoiceSchema"},"title":"Response List Invoices Endpoint V1 Invoices Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/invoicessearch":{"post":{"tags":["Invoice"],"summary":"List Invoices","description":"List invoices with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: include voided/cancelled invoices\n- skip: pagination offset\n- limit: max results per page\nReturns invoices sorted by creation date (newest first).","operationId":"search_invoices_endpoint_v1_invoicessearch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/InvoiceSchema"},"type":"array","title":"Response Search Invoices Endpoint V1 Invoicessearch Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/invoices/{identifier}":{"get":{"tags":["Invoice"],"summary":"Get Invoice","description":"Get full invoice details including line items and totals.\n\nPath param: identifier - UUID or invoice number\nReturns complete invoice with items, taxes, payment status, and metadata.","operationId":"get_invoice_endpoint_v1_invoices__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Invoice"],"summary":"Update Invoice","description":"Update an existing invoice by UUID or number.\n\nPath param: identifier - UUID or invoice number\nBody: updated invoice fields (typically notes or metadata)\nMost fields are restricted after creation to maintain audit trail.","operationId":"update_invoice_endpoint_v1_invoices__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Invoice"],"summary":"Delete Invoice","description":"Void/delete an invoice permanently.\n\nPath param: identifier - UUID or invoice number\nOnly invoices without completed payments or deliveries can be deleted.\nRequires CHAIRMAN position.","operationId":"delete_invoice_endpoint_v1_invoices__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/invoices/{identifier}/complete":{"post":{"tags":["Invoice"],"summary":"Mark Invoice Complete","description":"Mark an invoice as complete (all items delivered/purchased).\n\nPath param: identifier - UUID or invoice number\nAdvances invoice status to 'complete'. Cannot be undone.\nRequires that all inventory has been allocated/delivered.","operationId":"complete_invoice_endpoint_v1_invoices__identifier__complete_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/invoices/{identifier}/delivered":{"post":{"tags":["Invoice"],"summary":"Mark Invoice Delivered","description":"Mark an invoice as delivered (for sales) or received (for purchases).\n\nPath param: identifier - UUID or invoice number\nRecords delivery/receipt date and updates inventory reservations.\nTypically called after shipping confirmation or goods receipt.","operationId":"deliver_invoice_endpoint_v1_invoices__identifier__delivered_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/InvoiceSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/payments":{"post":{"tags":["Payment"],"summary":"Create Payment","description":"Create a new payment record for an invoice or order.\n\nPayment records financial transaction details (method, amount, reference).\nAutomatically updates related invoice/order payment status on success.","operationId":"create_payment_endpoint_v1_payments_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Payment"],"summary":"List Payments","description":"List payment records with optional pagination and filtering.\n\nQuery params:\n- include_inactive: include voided/reversed payments\n- skip: pagination offset\n- limit: max results per page\nReturns payments sorted by creation date.","operationId":"list_payments_endpoint_v1_payments_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/PaymentSchema"},"title":"Response List Payments Endpoint V1 Payments Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/paymentssearch":{"post":{"tags":["Payment"],"summary":"Search payments","description":"List payments with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: include voided/cancelled invoices\n- skip: pagination offset\n- limit: max results per page\nReturns payments sorted by creation date (newest first).","operationId":"search_payments_endpoint_v1_paymentssearch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/PaymentSchema"},"type":"array","title":"Response Search Payments Endpoint V1 Paymentssearch Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/payments/{payment_id}":{"get":{"tags":["Payment"],"summary":"Get Payment","description":"Get payment details by UUID.\n\nPath param: payment_id - UUID of the payment record\nReturns payment with linked invoice/order and transaction metadata.","operationId":"get_payment_endpoint_v1_payments__payment_id__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"payment_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Payment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Payment"],"summary":"Update Payment","description":"Update payment metadata by UUID.\n\nPath param: payment_id - UUID of the payment\nBody: updated payment fields (typically notes or references only)\nCore payment fields (amount, method) are immutable after creation.","operationId":"update_payment_endpoint_v1_payments__payment_id__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"payment_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Payment Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Payment"],"summary":"Delete Payment","description":"Void/delete a payment record.\n\nPath param: payment_id - UUID of the payment\nCan only delete payments that haven't been settled or reconciled.\nRequires CHAIRMAN position.","operationId":"delete_payment_endpoint_v1_payments__payment_id__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"payment_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Payment Id"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/payments/{payment_id}/status":{"post":{"tags":["Payment"],"summary":"Update Payment Status","description":"Update the status of a payment.\n\nPath param: payment_id - UUID of the payment\nBody: new status (pending, completed, failed, refunded, etc.)\nStatus changes may trigger downstream actions (invoice status update).","operationId":"set_payment_status_endpoint_v1_payments__payment_id__status_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"payment_id","in":"path","required":true,"schema":{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"],"title":"Payment Id"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentStatus"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/PaymentSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/shippings":{"post":{"tags":["Shipping"],"summary":"Create Shipping","description":"Create a new shipping record for an order or invoice.\n\nShipping tracks physical delivery of goods including carrier,\ntracking number, shipping address, and estimated/actual dates.","operationId":"create_shipping_endpoint_v1_shippings_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Shipping"],"summary":"List Shippings","description":"List shipping records with optional filtering and pagination.\n\nQuery params:\n- include_inactive: include cancelled/completed shipments\n- skip: pagination offset\n- limit: max results per page\nReturns shippings sorted by creation date.","operationId":"list_shippings_endpoint_v1_shippings_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/ShippingSchema"},"title":"Response List Shippings Endpoint V1 Shippings Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/shippingssearch":{"post":{"tags":["Shipping"],"summary":"List Shippings","description":"List shippings with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: include voided/cancelled invoices\n- skip: pagination offset\n- limit: max results per page\nReturns shippings sorted by creation date (newest first).","operationId":"search_shipping_endpoint_v1_shippingssearch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/ShippingSchema"},"type":"array","title":"Response Search Shipping Endpoint V1 Shippingssearch Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/shippings/{identifier}":{"get":{"tags":["Shipping"],"summary":"Get Shipping","description":"Get detailed information on shipping.\n\nArgs:\n        identifier: UUID or actual number of the shipping","operationId":"get_shipping_endpoint_v1_shippings__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Shipping"],"summary":"Update Shipping","description":"Update shipping metadata by UUID.\n\nPath param: identifier - UUID of the shipping record\nBody: updated shipping fields (address, carrier, tracking updates)\nStatus changes are handled via dedicated status endpoint.","operationId":"update_shipping_endpoint_v1_shippings__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Shipping"],"summary":"Delete Shipping","description":"Cancel/delete a shipping record.\n\nPath param: identifier - UUID of the shipping\nOnly pending shippings can be cancelled. Completed deliveries cannot be deleted.\nRequires appropriate permissions on the related order.","operationId":"delete_shipping_endpoint_v1_shippings__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/shippings/{identifier}/status":{"post":{"tags":["Shipping"],"summary":"Update Shipping Status","description":"Update the status of a shipping record.\n\nPath param: identifier - UUID of the shipping\nBody: new status (pending, in_transit, delivered, returned, etc.)\nStatus transitions may validate business rules (e.g. cannot mark undelivered as delivered).","operationId":"set_shipping_status_endpoint_v1_shippings__identifier__status_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingStatus"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ShippingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/trackings":{"post":{"tags":["Tracking"],"summary":"Create Tracking","description":"Create a new tracking record for an order or shipment.\n\nTracking monitors the progress of orders through fulfillment stages.\nStores current stage, timestamps, and associated order reference.","operationId":"create_tracking_endpoint_v1_trackings_post","security":[{"HTTPBearer":[]}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackingCreate"}}}},"responses":{"201":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"get":{"tags":["Tracking"],"summary":"List Trackings","description":"List tracking records with optional filtering.\n\nQuery params:\n- include_inactive: include completed/archived tracking\n- skip: pagination offset\n- limit: max results per page\nReturns trackings sorted by creation date, newest first.","operationId":"list_trackings_endpoint_v1_trackings_get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"include_inactive","in":"query","required":false,"schema":{"type":"boolean","default":false,"title":"Include Inactive"}},{"name":"skip","in":"query","required":false,"schema":{"type":"integer","default":0,"title":"Skip"}},{"name":"limit","in":"query","required":false,"schema":{"type":"integer","default":100,"title":"Limit"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"type":"array","items":{"$ref":"#/components/schemas/TrackingSchema"},"title":"Response List Trackings Endpoint V1 Trackings Get"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/trackingssearch":{"post":{"tags":["Tracking"],"summary":"List Trackings","description":"List trackings with optional pagination and active filtering.\n\nQuery params:\n- include_inactive: include voided/cancelled invoices\n- skip: pagination offset\n- limit: max results per page\nReturns trackings sorted by creation date (newest first).","operationId":"search_trackings_endpoint_v1_trackingssearch_post","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/SearchInput"}}},"required":true},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"items":{"$ref":"#/components/schemas/TrackingSchema"},"type":"array","title":"Response Search Trackings Endpoint V1 Trackingssearch Post"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}},"security":[{"HTTPBearer":[]}]}},"/v1/trackings/{identifier}":{"get":{"tags":["Tracking"],"summary":"Get Tracking","description":"Get full tracking details including stage history.\n\nPath param: identifier - UUID of tracking record or tracking number\nReturns current stage, timestamps, and associated order/shipment info.","operationId":"get_tracking_endpoint_v1_trackings__identifier__get","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"put":{"tags":["Tracking"],"summary":"Update Tracking","description":"Update tracking metadata by UUID.\n\nPath param: identifier - UUID of tracking record\nBody: updated tracking fields (notes, references)\nStage progression handled via dedicated /advance endpoint.","operationId":"update_tracking_endpoint_v1_trackings__identifier__put","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackingInput"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}},"delete":{"tags":["Tracking"],"summary":"Delete Tracking","description":"Archive/cancel a tracking record.\n\nPath param: identifier - UUID of tracking record\nUsed when an order is cancelled or tracking is no longer needed.\nDoes not delete associated order data.","operationId":"delete_tracking_endpoint_v1_trackings__identifier__delete","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"path","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ApiResponse"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}},"/v1/trackings/{tracking_id}/advance":{"post":{"tags":["Tracking"],"summary":"Advance Tracking Stage","description":"Advance a tracking record to the next fulfillment stage.\n\nPath param: identifier - UUID of tracking record\nBody: target stage (e.g., confirmed, packed, shipped, delivered)\nValidates stage transition rules and updates stage timestamp.","operationId":"advance_stage_endpoint_v1_trackings__tracking_id__advance_post","security":[{"HTTPBearer":[]}],"parameters":[{"name":"identifier","in":"query","required":true,"schema":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","minLength":3,"maxLength":50,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug","title":"Identifier"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackingStage"}}}},"responses":{"200":{"description":"Successful Response","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TrackingSchema"}}}},"422":{"description":"Validation Error","content":{"application/json":{"schema":{"$ref":"#/components/schemas/HTTPValidationError"}}}}}}}},"components":{"schemas":{"APIStatus":{"properties":{"status":{"type":"string","title":"Status"},"version":{"type":"string","title":"Version"},"endpoints":{"items":{"$ref":"#/components/schemas/EndpointInfo"},"type":"array","title":"Endpoints"},"details":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Details"}},"type":"object","required":["status","version","endpoints"],"title":"APIStatus"},"AddressCreate":{"properties":{"postal_code":{"type":"string","maxLength":10,"title":"Postal Code","default":""},"country":{"type":"string","maxLength":2,"title":"Country","default":"ru"},"region":{"type":"string","title":"Region","default":""},"city":{"type":"string","title":"City","default":""},"settlement":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Settlement"},"street":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Street"},"block":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Block"},"house":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"House"},"floor":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Floor"},"room":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Room"},"address":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Address"},"latitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude"},"longitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude"},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"address_type":{"$ref":"#/components/schemas/AddressTypeEnum","default":"legal"},"organization_id":{"type":"string","title":"Organization Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id"}},"type":"object","required":["organization_id"],"title":"AddressCreate"},"AddressInput":{"properties":{"postal_code":{"type":"string","maxLength":10,"title":"Postal Code","default":""},"country":{"type":"string","maxLength":2,"title":"Country","default":"ru"},"region":{"type":"string","title":"Region","default":""},"city":{"type":"string","title":"City","default":""},"settlement":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Settlement"},"street":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Street"},"block":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Block"},"house":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"House"},"floor":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Floor"},"room":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Room"},"address":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Address"},"latitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude"},"longitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude"},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"address_type":{"$ref":"#/components/schemas/AddressTypeEnum","default":"legal"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"organization":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Organization"},"division":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Division"}},"type":"object","title":"AddressInput"},"AddressSchema":{"properties":{"postal_code":{"type":"string","maxLength":10,"title":"Postal Code","default":""},"country":{"type":"string","maxLength":2,"title":"Country","default":"ru"},"region":{"type":"string","title":"Region","default":""},"city":{"type":"string","title":"City","default":""},"settlement":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Settlement"},"street":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Street"},"block":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Block"},"house":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"House"},"floor":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Floor"},"room":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Room"},"address":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Address"},"latitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Latitude"},"longitude":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Longitude"},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_verified":{"type":"boolean","title":"Is Verified","default":false},"address_type":{"$ref":"#/components/schemas/AddressTypeEnum","default":"legal"},"organization_id":{"type":"string","title":"Organization Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["organization_id","id"],"title":"AddressSchema"},"AddressTypeEnum":{"type":"string","enum":["home","legal","shipping","warehouse","corporate"],"title":"AddressTypeEnum"},"ApiResponse":{"properties":{"data":{"anyOf":[{"items":{},"type":"array"},{"type":"null"}],"title":"Data"},"status":{"type":"string","enum":["success","error","timeout"],"title":"Status","description":"The status of the request","default":"success","examples":["success","error","timeout"]},"success":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Success","default":true},"errors":{"anyOf":[{"items":{"$ref":"#/components/schemas/ErrorDetail"},"type":"array"},{"type":"null"}],"title":"Errors","description":"A list of structured error details, populated only if status is not 'success'","examples":[[{"loc":["auth"],"msg":"Invalid token","type":"auth_error"}]]},"details":{"anyOf":[{},{"type":"null"}],"title":"Details","description":"Additional details valuable for request","examples":[{"pagination":{"page":1,"per_page":10,"total":100}}]},"timestamp":{"type":"string","format":"date-time","title":"Timestamp"},"call_id":{"type":"string","title":"Call Id"},"is_successful":{"type":"boolean","title":"Is Successful","description":"Helper property to quickly check success state.","readOnly":true},"error_count":{"type":"integer","title":"Error Count","description":"Returns the number of errors present.","readOnly":true}},"type":"object","required":["is_successful","error_count"],"title":"ApiResponse","description":"Structured API response"},"AuthRequest":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"public_key":{"type":"string","title":"Public Key","description":"Public key used for signing"},"signature":{"type":"string","title":"Signature","description":"Hex-encoded signature"},"message":{"type":"string","title":"Message","description":"ISO 8601 timestamp used for signing"}},"type":"object","required":["public_key","signature","message"],"title":"AuthRequest"},"AuthenticatedUser":{"properties":{"user_id":{"type":"string","title":"User Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"account":{"type":"string","title":"Account"},"staff_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Staff Id"},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id"},"organization_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Organization Id"},"position":{"anyOf":[{"$ref":"#/components/schemas/StaffPositionEnum"},{"type":"null"}]},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title"},"is_granted":{"type":"boolean","title":"Is Granted","default":false},"staff":{"anyOf":[{"$ref":"#/components/schemas/StaffSchema"},{"type":"null"}]}},"type":"object","required":["user_id","account"],"title":"AuthenticatedUser","description":"Complete authenticated user context with staff information.\nInjected into every authenticated request for tracking and authorization."},"BrandBaseSchema":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Brand name (must be unique)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Brand description"},"logo":{"anyOf":[{"type":"string","description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Logo","description":"Logo URL"},"country_code":{"anyOf":[{"type":"string","maxLength":2},{"type":"null"}],"title":"Country Code","description":"ISO country code"},"website":{"anyOf":[{"type":"string","description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Brand website"},"meta_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Meta Data","description":"Additional metadata"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["name","id"],"title":"BrandBaseSchema"},"BrandInput":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Brand name (must be unique)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Brand description"},"logo":{"anyOf":[{"type":"string","description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Logo","description":"Logo URL"},"country_code":{"anyOf":[{"type":"string","maxLength":2},{"type":"null"}],"title":"Country Code","description":"ISO country code"},"website":{"anyOf":[{"type":"string","description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Brand website"},"meta_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Meta Data","description":"Additional metadata"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier","description":"Brand UUID or slug (only for update operations)"}},"type":"object","required":["name"],"title":"BrandInput","description":"Unified input schema for create and update operations."},"BrandSchema":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Brand name (must be unique)"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Brand description"},"logo":{"anyOf":[{"type":"string","description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Logo","description":"Logo URL"},"country_code":{"anyOf":[{"type":"string","maxLength":2},{"type":"null"}],"title":"Country Code","description":"ISO country code"},"website":{"anyOf":[{"type":"string","description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Brand website"},"meta_data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Meta Data","description":"Additional metadata"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["name","id"],"title":"BrandSchema","description":"Schema returned from API responses."},"DivisionExtendedSchema":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Division title"},"shortname":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","maxLength":255,"minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Shortname","description":"Division short name"},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"reputation":{"type":"integer","title":"Reputation","description":"Division reputation","default":1},"is_active":{"type":"boolean","title":"Is Active","description":"Division is active","default":true},"organization_id":{"type":"string","title":"Organization Id","description":"Organization UUID","examples":["550e8400-e29b-41d4-a716-446655440000"]},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"shops":{"items":{"$ref":"#/components/schemas/ShopSchema"},"type":"array","title":"Shops","description":"list of active shops"}},"type":"object","required":["title","organization_id","id"],"title":"DivisionExtendedSchema"},"DivisionInput":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Division title"},"shortname":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","maxLength":255,"minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Shortname","description":"Division short name"},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"reputation":{"type":"integer","title":"Reputation","description":"Division reputation","default":1},"is_active":{"type":"boolean","title":"Is Active","description":"Division is active","default":true},"organization":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"title":"Organization","description":"Organization UUID"}},"type":"object","required":["title","organization"],"title":"DivisionInput","description":"Division input form"},"DivisionSchema":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Division title"},"shortname":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","maxLength":255,"minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Shortname","description":"Division short name"},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"reputation":{"type":"integer","title":"Reputation","description":"Division reputation","default":1},"is_active":{"type":"boolean","title":"Is Active","description":"Division is active","default":true},"organization_id":{"type":"string","title":"Organization Id","description":"Organization UUID","examples":["550e8400-e29b-41d4-a716-446655440000"]},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["title","organization_id","id"],"title":"DivisionSchema"},"EndpointInfo":{"properties":{"path":{"type":"string","title":"Path"},"methods":{"items":{"type":"string"},"type":"array","title":"Methods"},"name":{"type":"string","title":"Name"},"summary":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Summary"},"tags":{"items":{"type":"string"},"type":"array","title":"Tags","default":[]},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"}},"type":"object","required":["path","methods","name"],"title":"EndpointInfo"},"ErrorDetail":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Loc","description":"Error location (e.g., ['body', 'email'])"},"msg":{"type":"string","title":"Msg","description":"Human-readable error message"},"type":{"type":"string","title":"Type","description":"Error type (e.g., 'validation_error')"}},"type":"object","required":["loc","msg","type"],"title":"ErrorDetail","description":"Structured error following Pydantic/JSON Schema conventions"},"GenderEnum":{"type":"string","enum":["unknown","female","male"],"title":"GenderEnum"},"HTTPValidationError":{"properties":{"detail":{"items":{"$ref":"#/components/schemas/ValidationError"},"type":"array","title":"Detail"}},"type":"object","title":"HTTPValidationError"},"HealthCheck":{"properties":{"status":{"$ref":"#/components/schemas/ServerStatus","default":"ok"},"version":{"type":"string","title":"Version","default":"1.0.0"},"system":{"$ref":"#/components/schemas/SystemMetrics"},"details":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object"},{"type":"null"}],"title":"Details"}},"type":"object","required":["system"],"title":"HealthCheck"},"InventoryCreate":{"properties":{"invid":{"type":"string","maxLength":255,"title":"Invid","description":"Inventory document ID"},"qty":{"type":"integer","title":"Qty","description":"Quantity","default":1},"uom":{"type":"string","maxLength":2,"title":"Uom","description":"Unit of measure"},"cost":{"type":"integer","title":"Cost","description":"Cost in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"chain":{"anyOf":[{"type":"string","maxLength":25},{"type":"null"}],"title":"Chain","description":"Blockchain chain"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reason":{"anyOf":[{"$ref":"#/components/schemas/ReasonChoices"},{"type":"null"}]},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"stock_id":{"type":"string","title":"Stock Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"shipping_id":{"type":"string","title":"Shipping Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"entity_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Entity Id"}},"type":"object","required":["invid","uom","shop_id","stock_id","shipping_id"],"title":"InventoryCreate"},"InventoryInput":{"properties":{"invid":{"type":"string","maxLength":255,"title":"Invid","description":"Inventory document ID"},"qty":{"type":"integer","title":"Qty","description":"Quantity","default":1},"uom":{"type":"string","maxLength":2,"title":"Uom","description":"Unit of measure"},"cost":{"type":"integer","title":"Cost","description":"Cost in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"chain":{"anyOf":[{"type":"string","maxLength":25},{"type":"null"}],"title":"Chain","description":"Blockchain chain"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reason":{"anyOf":[{"$ref":"#/components/schemas/ReasonChoices"},{"type":"null"}]},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"shop_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shop Id"},"stock_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Stock Id"},"shipping_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shipping Id"},"entity_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Entity Id"}},"type":"object","required":["invid","uom"],"title":"InventoryInput"},"InventorySchema":{"properties":{"invid":{"type":"string","maxLength":255,"title":"Invid","description":"Inventory document ID"},"qty":{"type":"integer","title":"Qty","description":"Quantity","default":1},"uom":{"type":"string","maxLength":2,"title":"Uom","description":"Unit of measure"},"cost":{"type":"integer","title":"Cost","description":"Cost in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"chain":{"anyOf":[{"type":"string","maxLength":25},{"type":"null"}],"title":"Chain","description":"Blockchain chain"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"reason":{"anyOf":[{"$ref":"#/components/schemas/ReasonChoices"},{"type":"null"}]},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"stock_id":{"type":"string","title":"Stock Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"shipping_id":{"type":"string","title":"Shipping Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"entity_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Entity Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["invid","uom","shop_id","stock_id","shipping_id","id"],"title":"InventorySchema"},"InvoiceCreate":{"properties":{"number":{"type":"string","maxLength":255,"title":"Number"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"total":{"type":"integer","title":"Total","description":"Total amount in minor currency units","default":0},"paid":{"type":"integer","title":"Paid","description":"Paid amount in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"is_complete":{"type":"boolean","title":"Is Complete","default":false},"is_delivered":{"type":"boolean","title":"Is Delivered","default":false},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"address_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Address Id"},"phone_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Phone Id"}},"type":"object","required":["number","shop_id"],"title":"InvoiceCreate"},"InvoiceInput":{"properties":{"number":{"type":"string","maxLength":255,"title":"Number"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"total":{"type":"integer","title":"Total","description":"Total amount in minor currency units","default":0},"paid":{"type":"integer","title":"Paid","description":"Paid amount in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"is_complete":{"type":"boolean","title":"Is Complete","default":false},"is_delivered":{"type":"boolean","title":"Is Delivered","default":false},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"shop_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shop Id"},"address_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Address Id"},"phone_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Phone Id"}},"type":"object","required":["number"],"title":"InvoiceInput"},"InvoiceSchema":{"properties":{"number":{"type":"string","maxLength":255,"title":"Number"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"total":{"type":"integer","title":"Total","description":"Total amount in minor currency units","default":0},"paid":{"type":"integer","title":"Paid","description":"Paid amount in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"is_complete":{"type":"boolean","title":"Is Complete","default":false},"is_delivered":{"type":"boolean","title":"Is Delivered","default":false},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"address_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Address Id"},"phone_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Phone Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["number","shop_id","id"],"title":"InvoiceSchema"},"LegalFormEnum":{"type":"string","enum":["cooperative","society","foundation","trust","nonprofit","enterpreneur"],"title":"LegalFormEnum"},"ManufacturerCreate":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Manufacturer name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Manufacturer description"},"location":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Location","description":"Location information (JSONB)"},"contact_info":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Contact Info","description":"Contact information (JSONB)"},"organization_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Organization Id","description":"Organization UUID"},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id","description":"Division UUID"}},"type":"object","required":["name"],"title":"ManufacturerCreate"},"ManufacturerInput":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Manufacturer name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Manufacturer description"},"location":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Location","description":"Location information (JSONB)"},"contact_info":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Contact Info","description":"Contact information (JSONB)"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier","description":"Manufacturer UUID (only for update)"},"organization":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Organization","description":"Organization UUID or slug"},"division":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Division","description":"Division UUID or slug"}},"type":"object","required":["name"],"title":"ManufacturerInput","description":"Unified create/update input."},"ManufacturerSchema":{"properties":{"name":{"type":"string","maxLength":255,"title":"Name","description":"Manufacturer name"},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description","description":"Manufacturer description"},"location":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Location","description":"Location information (JSONB)"},"contact_info":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Contact Info","description":"Contact information (JSONB)"},"organization_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Organization Id","description":"Organization UUID"},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id","description":"Division UUID"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["name","id"],"title":"ManufacturerSchema"},"OrderInput":{"properties":{"amount":{"type":"integer","title":"Amount","description":"Order amount in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"is_paid":{"type":"boolean","title":"Is Paid","default":false},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"shop_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shop Id"},"stock_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Stock Id"},"invoice_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Invoice Id"}},"type":"object","title":"OrderInput"},"OrderSchema":{"properties":{"amount":{"type":"integer","title":"Amount","description":"Order amount in minor currency units","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"is_paid":{"type":"boolean","title":"Is Paid","default":false},"description":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Description"},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"stock_id":{"type":"string","title":"Stock Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"invoice_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Invoice Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["shop_id","stock_id","id"],"title":"OrderSchema"},"OrganizationCreate":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Organization title"},"shortname":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Shortname","description":"Organization short name in different languages in JSON format. Accepts string or dict with language codes."},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"is_active":{"type":"boolean","title":"Is Active","description":"Organization is active","default":true},"legal":{"$ref":"#/components/schemas/LegalFormEnum","description":"The legal form of the organization","default":"cooperative"},"reputation":{"type":"integer","title":"Reputation","description":"Organization reputation","default":1},"regnum":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Regnum","description":"Registration number"},"regdate":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Regdate","description":"Registration date"},"taxid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Taxid","description":"Local Tax ID of organization"},"hid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Hid","description":"DaData ID of the organization"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Data","description":"DaData information on organization"}},"type":"object","required":["title"],"title":"OrganizationCreate"},"OrganizationExtendedSchema":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Organization title"},"shortname":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Shortname","description":"Organization short name in different languages in JSON format. Accepts string or dict with language codes."},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"is_active":{"type":"boolean","title":"Is Active","description":"Organization is active","default":true},"legal":{"$ref":"#/components/schemas/LegalFormEnum","description":"The legal form of the organization","default":"cooperative"},"reputation":{"type":"integer","title":"Reputation","description":"Organization reputation","default":1},"regnum":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Regnum","description":"Registration number"},"regdate":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Regdate","description":"Registration date"},"taxid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Taxid","description":"Local Tax ID of organization"},"hid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Hid","description":"DaData ID of the organization"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Data","description":"DaData information on organization"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"divisions":{"items":{"$ref":"#/components/schemas/DivisionSchema"},"type":"array","title":"Divisions","description":"list of active divisions"}},"type":"object","required":["title","id"],"title":"OrganizationExtendedSchema"},"OrganizationInput":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Organization title"},"shortname":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Shortname","description":"Organization short name in different languages in JSON format. Accepts string or dict with language codes."},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"is_active":{"type":"boolean","title":"Is Active","description":"Organization is active","default":true},"legal":{"$ref":"#/components/schemas/LegalFormEnum","description":"The legal form of the organization","default":"cooperative"},"reputation":{"type":"integer","title":"Reputation","description":"Organization reputation","default":1},"regnum":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Regnum","description":"Registration number"},"regdate":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Regdate","description":"Registration date"},"taxid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Taxid","description":"Local Tax ID of organization"},"hid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Hid","description":"DaData ID of the organization"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Data","description":"DaData information on organization"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"}},"type":"object","required":["title"],"title":"OrganizationInput"},"OrganizationSchema":{"properties":{"account":{"anyOf":[{"type":"string","maxLength":12,"minLength":1,"description":"Coopenomics account name (12 chars, a-z and 1-5)"},{"type":"null"}],"title":"Account","description":"Standard Coopenomics account name (must start with a-z, max 12 chars)"},"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Organization title"},"shortname":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Shortname","description":"Organization short name in different languages in JSON format. Accepts string or dict with language codes."},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"is_active":{"type":"boolean","title":"Is Active","description":"Organization is active","default":true},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["title","id"],"title":"OrganizationSchema"},"PayStatusChoices":{"type":"string","enum":["failed","initiated","pending","succeeded","dispute","return"],"title":"PayStatusChoices"},"PaymentCreate":{"properties":{"status":{"$ref":"#/components/schemas/PayStatusChoices","default":"initiated"},"provider":{"$ref":"#/components/schemas/ProviderChoices","default":"coop"},"record":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Record"},"amount":{"type":"integer","title":"Amount","description":"Amount in minor currency units","default":0},"paid":{"type":"integer","title":"Paid","description":"Paid amount in minor currency units","default":0},"currency":{"type":"string","maxLength":10,"title":"Currency","default":"RUB"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Data"},"is_complete":{"type":"boolean","title":"Is Complete","default":false},"chain":{"anyOf":[{"type":"string","maxLength":25},{"type":"null"}],"title":"Chain"},"account":{"anyOf":[{"type":"string","maxLength":12},{"type":"null"}],"title":"Account"},"invoice_id":{"type":"string","title":"Invoice Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]}},"type":"object","required":["invoice_id"],"title":"PaymentCreate"},"PaymentInput":{"properties":{"status":{"$ref":"#/components/schemas/PayStatusChoices","default":"initiated"},"provider":{"$ref":"#/components/schemas/ProviderChoices","default":"coop"},"record":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Record"},"amount":{"type":"integer","title":"Amount","description":"Amount in minor currency units","default":0},"paid":{"type":"integer","title":"Paid","description":"Paid amount in minor currency units","default":0},"currency":{"type":"string","maxLength":10,"title":"Currency","default":"RUB"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Data"},"is_complete":{"type":"boolean","title":"Is Complete","default":false},"chain":{"anyOf":[{"type":"string","maxLength":25},{"type":"null"}],"title":"Chain"},"account":{"anyOf":[{"type":"string","maxLength":12},{"type":"null"}],"title":"Account"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"invoice_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Invoice Id"}},"type":"object","title":"PaymentInput"},"PaymentSchema":{"properties":{"status":{"$ref":"#/components/schemas/PayStatusChoices","default":"initiated"},"provider":{"$ref":"#/components/schemas/ProviderChoices","default":"coop"},"record":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Record"},"amount":{"type":"integer","title":"Amount","description":"Amount in minor currency units","default":0},"paid":{"type":"integer","title":"Paid","description":"Paid amount in minor currency units","default":0},"currency":{"type":"string","maxLength":10,"title":"Currency","default":"RUB"},"data":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Data"},"is_complete":{"type":"boolean","title":"Is Complete","default":false},"chain":{"anyOf":[{"type":"string","maxLength":25},{"type":"null"}],"title":"Chain"},"account":{"anyOf":[{"type":"string","maxLength":12},{"type":"null"}],"title":"Account"},"invoice_id":{"type":"string","title":"Invoice Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["invoice_id","id"],"title":"PaymentSchema"},"PaymentStatus":{"properties":{"status":{"$ref":"#/components/schemas/PayStatusChoices","default":"initiated"}},"type":"object","title":"PaymentStatus"},"PhoneCreate":{"properties":{"number":{"type":"string","maxLength":15,"title":"Number"},"title":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Title"},"is_primary":{"type":"boolean","title":"Is Primary","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_telegram":{"type":"boolean","title":"Is Telegram","default":false},"is_whatsapp":{"type":"boolean","title":"Is Whatsapp","default":false},"is_viber":{"type":"boolean","title":"Is Viber","default":false},"phone_type":{"$ref":"#/components/schemas/PhoneTypeEnum","default":"mobile"},"organization_id":{"type":"string","title":"Organization Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id"}},"type":"object","required":["number","organization_id"],"title":"PhoneCreate"},"PhoneInput":{"properties":{"number":{"type":"string","maxLength":15,"title":"Number"},"title":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Title"},"is_primary":{"type":"boolean","title":"Is Primary","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_telegram":{"type":"boolean","title":"Is Telegram","default":false},"is_whatsapp":{"type":"boolean","title":"Is Whatsapp","default":false},"is_viber":{"type":"boolean","title":"Is Viber","default":false},"phone_type":{"$ref":"#/components/schemas/PhoneTypeEnum","default":"mobile"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"organization":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Organization"},"division":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Division"}},"type":"object","required":["number"],"title":"PhoneInput"},"PhoneSchema":{"properties":{"number":{"type":"string","maxLength":15,"title":"Number"},"title":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Title"},"is_primary":{"type":"boolean","title":"Is Primary","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_telegram":{"type":"boolean","title":"Is Telegram","default":false},"is_whatsapp":{"type":"boolean","title":"Is Whatsapp","default":false},"is_viber":{"type":"boolean","title":"Is Viber","default":false},"phone_type":{"$ref":"#/components/schemas/PhoneTypeEnum","default":"mobile"},"organization_id":{"type":"string","title":"Organization Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["number","organization_id","id"],"title":"PhoneSchema"},"PhoneTypeEnum":{"type":"string","enum":["dormant","home","work","mobile","free","support","multiline"],"title":"PhoneTypeEnum"},"PriceCreate":{"properties":{"price_type":{"type":"string","maxLength":50,"title":"Price Type","default":"retail"},"amount":{"type":"integer","title":"Amount","description":"Price in minor currency units (kopecks)","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"start_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"},"is_active":{"type":"boolean","title":"Is Active","default":true},"stock_id":{"type":"string","title":"Stock Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"variation_id":{"type":"string","title":"Variation Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]}},"type":"object","required":["stock_id","variation_id"],"title":"PriceCreate"},"PriceInput":{"properties":{"price_type":{"type":"string","maxLength":50,"title":"Price Type","default":"retail"},"amount":{"type":"integer","title":"Amount","description":"Price in minor currency units (kopecks)","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"start_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"},"is_active":{"type":"boolean","title":"Is Active","default":true},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"stock_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Stock Id"},"variation_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Variation Id"}},"type":"object","title":"PriceInput"},"PriceSchema":{"properties":{"price_type":{"type":"string","maxLength":50,"title":"Price Type","default":"retail"},"amount":{"type":"integer","title":"Amount","description":"Price in minor currency units (kopecks)","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"start_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Start Date"},"end_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"End Date"},"is_active":{"type":"boolean","title":"Is Active","default":true},"stock_id":{"type":"string","title":"Stock Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"variation_id":{"type":"string","title":"Variation Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["stock_id","variation_id","id"],"title":"PriceSchema"},"ProductInput":{"properties":{"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"name":{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"title":"Name","description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_new":{"type":"boolean","title":"Is New","default":false},"is_featured":{"type":"boolean","title":"Is Featured","default":false},"is_custom":{"type":"boolean","title":"Is Custom","default":false},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"category_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Category Id"},"brand_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Brand Id"},"manufacturer_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Manufacturer Id"}},"type":"object","required":["name"],"title":"ProductInput"},"ProductSchema":{"properties":{"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"name":{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"title":"Name","description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"is_active":{"type":"boolean","title":"Is Active","default":true},"is_new":{"type":"boolean","title":"Is New","default":false},"is_featured":{"type":"boolean","title":"Is Featured","default":false},"is_custom":{"type":"boolean","title":"Is Custom","default":false},"category_id":{"type":"string","title":"Category Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"brand_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Brand Id"},"manufacturer_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Manufacturer Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"variations":{"items":{"$ref":"#/components/schemas/VariationSchema"},"type":"array","title":"Variations"}},"type":"object","required":["name","category_id","id"],"title":"ProductSchema"},"ProviderChoices":{"type":"string","enum":["coop","yoomoney","sber","yapay"],"title":"ProviderChoices"},"QuantityStock":{"properties":{"qty":{"type":"integer","title":"Qty"}},"type":"object","required":["qty"],"title":"QuantityStock"},"ReasonChoices":{"type":"string","enum":["lost","stolen","expired","rotten","broken"],"title":"ReasonChoices"},"SearchInput":{"properties":{"filters":{"anyOf":[{"additionalProperties":true,"type":"object"},{"type":"null"}],"title":"Filters","description":"Search filter dictionary, where key is a model field name","examples":[["title","My Title"]]},"skip":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Skip","description":"Starting record in pagination","default":0},"limit":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Limit"},"include_inactive":{"anyOf":[{"type":"boolean"},{"type":"null"}],"title":"Include Inactive","description":"Flag to include inactive records","default":false}},"type":"object","title":"SearchInput"},"ServerStatus":{"type":"string","enum":["ok","testing","maintenance","deprecated"],"title":"ServerStatus"},"ShippingCreate":{"properties":{"number":{"type":"string","maxLength":255,"title":"Number"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"total_items":{"type":"integer","title":"Total Items","default":0},"total_cost":{"type":"integer","title":"Total Cost","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"reference":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference"},"received_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received Date"},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"invoice_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Invoice Id"},"tracking_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Tracking Id"},"supplier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Supplier Id"},"carrier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Carrier Id"}},"type":"object","required":["number","shop_id"],"title":"ShippingCreate"},"ShippingInput":{"properties":{"number":{"type":"string","maxLength":255,"title":"Number"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"total_items":{"type":"integer","title":"Total Items","default":0},"total_cost":{"type":"integer","title":"Total Cost","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"reference":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference"},"received_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received Date"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"shop_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shop Id"},"invoice_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Invoice Id"},"tracking_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Tracking Id"},"supplier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Supplier Id"},"carrier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Carrier Id"}},"type":"object","required":["number"],"title":"ShippingInput"},"ShippingSchema":{"properties":{"number":{"type":"string","maxLength":255,"title":"Number"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"total_items":{"type":"integer","title":"Total Items","default":0},"total_cost":{"type":"integer","title":"Total Cost","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"reference":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference"},"received_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received Date"},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"invoice_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Invoice Id"},"tracking_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Tracking Id"},"supplier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Supplier Id"},"carrier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Carrier Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["number","shop_id","id"],"title":"ShippingSchema"},"ShippingStatus":{"properties":{"status":{"$ref":"#/components/schemas/TrackingChoices","default":"pending"}},"type":"object","title":"ShippingStatus"},"ShopInput":{"properties":{"slug":{"anyOf":[{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"},{"type":"null"}],"title":"Slug"},"title":{"type":"string","maxLength":255,"title":"Title","description":"Shop title"},"email":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid email address"},{"type":"null"}],"title":"Email"},"description":{"anyOf":[{"additionalProperties":{"type":"string"},"type":"object","minLength":1,"description":"Map of ISO language codes to strings. Must include 'ru'. Accepts string input which converts to {'ru': value}.","examples":[{"en":"Text","ru":"Текст"}]},{"type":"null"}],"title":"Description"},"address":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Address","description":"Address of the Shop"},"phone":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Phone","description":"Phone of the Shop"},"website":{"anyOf":[{"type":"string","maxLength":255,"description":"Valid URL (prepends https:// if missing) or relative path"},{"type":"null"}],"title":"Website","description":"Website"},"is_active":{"type":"boolean","title":"Is Active","description":"Organization is active","default":true},"id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Id","description":"Shop UUID for update"},"division":{"type":"string","title":"Division","description":"Division UUID or a slug"}},"type":"object","required":["title","id","division"],"title":"ShopInput","description":"Shop Input Form"},"ShopSchema":{"properties":{"organization_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Organization Id","description":"UUID of the parent organization"},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id","description":"UUID of the division"},"is_active":{"type":"boolean","title":"Is Active","description":"Shop is active","default":true},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id"],"title":"ShopSchema"},"SocialCreate":{"properties":{"socid":{"type":"string","maxLength":50,"title":"Socid"},"soc_type":{"$ref":"#/components/schemas/SocialTypeEnum","default":"unknown"},"username":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Username"},"first_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Email"},"avatar":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar"},"birthday":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birthday"},"gender":{"$ref":"#/components/schemas/GenderEnum","default":"unknown"},"appid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Appid"},"access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"scope":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope"},"credentials":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Credentials"},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"is_enrolled":{"type":"boolean","title":"Is Enrolled","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"organization_id":{"type":"string","title":"Organization Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id"}},"type":"object","required":["socid","organization_id"],"title":"SocialCreate"},"SocialInput":{"properties":{"socid":{"type":"string","maxLength":50,"title":"Socid"},"soc_type":{"$ref":"#/components/schemas/SocialTypeEnum","default":"unknown"},"username":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Username"},"first_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Email"},"avatar":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar"},"birthday":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birthday"},"gender":{"$ref":"#/components/schemas/GenderEnum","default":"unknown"},"appid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Appid"},"access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"scope":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope"},"credentials":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Credentials"},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"is_enrolled":{"type":"boolean","title":"Is Enrolled","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"organization":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Organization"},"division":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Division"}},"type":"object","required":["socid"],"title":"SocialInput"},"SocialSchema":{"properties":{"socid":{"type":"string","maxLength":50,"title":"Socid"},"soc_type":{"$ref":"#/components/schemas/SocialTypeEnum","default":"unknown"},"username":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Username"},"first_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"First Name"},"last_name":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Last Name"},"email":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Email"},"avatar":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Avatar"},"birthday":{"anyOf":[{"type":"string","format":"date"},{"type":"null"}],"title":"Birthday"},"gender":{"$ref":"#/components/schemas/GenderEnum","default":"unknown"},"appid":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Appid"},"access_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Access Token"},"refresh_token":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Refresh Token"},"expires_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expires At"},"scope":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Scope"},"credentials":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Credentials"},"account":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Account"},"is_enrolled":{"type":"boolean","title":"Is Enrolled","default":false},"is_active":{"type":"boolean","title":"Is Active","default":true},"organization_id":{"type":"string","title":"Organization Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["socid","organization_id","id"],"title":"SocialSchema"},"SocialTypeEnum":{"type":"string","enum":["yandex","vk","telegram","sberbank","tbank","google","facebook","twitter","odnoklassniki","renren","wechat","unknown"],"title":"SocialTypeEnum"},"StaffExtendedSchema":{"properties":{"position":{"anyOf":[{"$ref":"#/components/schemas/StaffPositionEnum"},{"type":"null"}],"description":"Authority level of the staff or the member","default":"associate"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title","description":"Position of the staff or the member"},"is_granted":{"type":"boolean","title":"Is Granted","description":"Active status of the user","default":true},"organization_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Organization Id","description":"Organization UUID"},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id","description":"Division UUID"},"user_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"User Id","description":"User UUID"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"organization":{"$ref":"#/components/schemas/OrganizationSchema","description":"Organization data"},"division":{"$ref":"#/components/schemas/DivisionSchema","description":"Division data"},"shops":{"items":{"$ref":"#/components/schemas/ShopSchema"},"type":"array","title":"Shops"}},"type":"object","required":["id"],"title":"StaffExtendedSchema"},"StaffInput":{"properties":{"position":{"anyOf":[{"$ref":"#/components/schemas/StaffPositionEnum"},{"type":"null"}],"description":"Authority level of the staff or the member","default":"associate"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title","description":"Position of the staff or the member"},"is_granted":{"type":"boolean","title":"Is Granted","description":"Active status of the user","default":true},"identifier":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"title":"Identifier","description":"UUID string or URL-friendly slug"},"division":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Division","description":"Division UUID or a slug"}},"type":"object","required":["identifier"],"title":"StaffInput","description":"Staff Input Form"},"StaffPosition":{"properties":{"position":{"anyOf":[{"$ref":"#/components/schemas/StaffPositionEnum"},{"type":"null"}],"description":"Authority level of the staff or the member","default":"associate"}},"type":"object","title":"StaffPosition"},"StaffPositionEnum":{"type":"string","enum":["associate","member","manager","board","executive","chairman"],"title":"StaffPositionEnum"},"StaffSchema":{"properties":{"position":{"anyOf":[{"$ref":"#/components/schemas/StaffPositionEnum"},{"type":"null"}],"description":"Authority level of the staff or the member","default":"associate"},"title":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Title","description":"Position of the staff or the member"},"is_granted":{"type":"boolean","title":"Is Granted","description":"Active status of the user","default":true},"organization_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Organization Id","description":"Organization UUID"},"division_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Division Id","description":"Division UUID"},"user_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"User Id","description":"User UUID"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["id"],"title":"StaffSchema"},"StockAdjustInput":{"properties":{"quantity_change":{"type":"integer","title":"Quantity Change","description":"Positive to add, negative to subtract"},"reason":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reason"}},"type":"object","required":["quantity_change"],"title":"StockAdjustInput","description":"Input for adjusting stock quantity."},"StockInput":{"properties":{"qty":{"type":"integer","title":"Qty"},"sku":{"type":"string","maxLength":255,"title":"Sku"},"serial":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Serial"},"barcode":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Barcode"},"tracking":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Tracking"},"reserve":{"type":"integer","title":"Reserve","default":0},"transit":{"type":"integer","title":"Transit","default":0},"minimum":{"type":"integer","title":"Minimum","default":0},"uom":{"type":"string","maxLength":2,"title":"Uom","default":"шт"},"produced_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Produced Date"},"expration_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expration Date"},"inventory_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Inventory Date"},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier"},"product_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Product Id"},"shop_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shop Id"},"bundle_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Bundle Id"},"modification_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Modification Id"},"brand_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Brand Id"}},"type":"object","required":["qty","sku"],"title":"StockInput"},"StockSchema":{"properties":{"qty":{"type":"integer","title":"Qty"},"sku":{"type":"string","maxLength":255,"title":"Sku"},"serial":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Serial"},"barcode":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Barcode"},"tracking":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Tracking"},"reserve":{"type":"integer","title":"Reserve","default":0},"transit":{"type":"integer","title":"Transit","default":0},"minimum":{"type":"integer","title":"Minimum","default":0},"uom":{"type":"string","maxLength":2,"title":"Uom","default":"шт"},"produced_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Produced Date"},"expration_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Expration Date"},"inventory_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Inventory Date"},"product_id":{"type":"string","title":"Product Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"shop_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shop Id"},"bundle_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Bundle Id"},"modification_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Modification Id"},"brand_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Brand Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["qty","sku","product_id","id"],"title":"StockSchema"},"SystemMetrics":{"properties":{"cpu_usage":{"type":"number","title":"Cpu Usage","description":"CPU usage (percent)"},"memory_usage":{"type":"number","title":"Memory Usage","description":"Memory usage (percent)"},"process_memory":{"type":"number","title":"Process Memory","description":"Process Memory (Mb)"}},"type":"object","required":["cpu_usage","memory_usage","process_memory"],"title":"SystemMetrics"},"Token":{"properties":{"token":{"type":"string","title":"Token","description":"JWT encoded string representing the access token"},"expires":{"type":"string","format":"date-time","title":"Expires","description":"Expiration datetime in ISO format"}},"type":"object","required":["token","expires"],"title":"Token","description":"Represents a single encoded token with its metadata."},"TokenCollection":{"properties":{"access":{"$ref":"#/components/schemas/Token"},"refresh":{"$ref":"#/components/schemas/Token"}},"type":"object","required":["access","refresh"],"title":"TokenCollection"},"TokenInfoResponse":{"properties":{"token":{"type":"string","title":"Token","description":"JWT encoded string representing the access token"},"expires":{"type":"string","format":"date-time","title":"Expires","description":"Expiration datetime in ISO format"},"issued":{"type":"string","format":"date-time","title":"Issued","description":"Issue date in ISO format"},"expires_in":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expires In"},"type":{"type":"string","title":"Type"},"version":{"type":"string","title":"Version"}},"type":"object","required":["token","expires","issued","type","version"],"title":"TokenInfoResponse"},"TokenInput":{"properties":{"token":{"type":"string","title":"Token","description":"Access token or its ID"}},"type":"object","required":["token"],"title":"TokenInput"},"TokenResponse":{"properties":{"tokens":{"$ref":"#/components/schemas/TokenCollection"},"id":{"type":"string","title":"Id","description":"Unique token identifier"},"token_type":{"type":"string","title":"Token Type","default":"bearer"},"expires_in":{"anyOf":[{"type":"integer"},{"type":"null"}],"title":"Expires In","description":"Seconds before ccess token expiration"}},"type":"object","required":["tokens","id"],"title":"TokenResponse"},"TrackingChoices":{"type":"string","enum":["initiated","pending","accepted","processed","transit","delivered","returned","liquidated","cancelled"],"title":"TrackingChoices"},"TrackingCreate":{"properties":{"stage":{"$ref":"#/components/schemas/TrackingChoices","default":"initiated"},"number":{"type":"string","maxLength":255,"title":"Number"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"shipped_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Shipped Date"},"estimated_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Estimated Delivery"},"actual_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Actual Delivery"},"received_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received Date"},"total_items":{"type":"integer","title":"Total Items","default":0},"total_cost":{"type":"integer","title":"Total Cost","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"reference":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference"},"is_received":{"type":"boolean","title":"Is Received","default":false},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"carrier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Carrier Id"}},"type":"object","required":["number","shop_id"],"title":"TrackingCreate"},"TrackingInput":{"properties":{"stage":{"$ref":"#/components/schemas/TrackingChoices","default":"initiated"},"number":{"type":"string","maxLength":255,"title":"Number"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"shipped_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Shipped Date"},"estimated_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Estimated Delivery"},"actual_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Actual Delivery"},"received_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received Date"},"total_items":{"type":"integer","title":"Total Items","default":0},"total_cost":{"type":"integer","title":"Total Cost","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"reference":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference"},"is_received":{"type":"boolean","title":"Is Received","default":false},"identifier":{"anyOf":[{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"string","maxLength":50,"minLength":3,"description":"Latin letters, numbers, dashes, underscores, and dots only"}],"description":"UUID string or URL-friendly slug"},{"type":"null"}],"title":"Identifier","description":"UUID or a tracking number"},"shop_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Shop Id"},"carrier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Carrier Id"}},"type":"object","required":["number"],"title":"TrackingInput"},"TrackingSchema":{"properties":{"stage":{"$ref":"#/components/schemas/TrackingChoices","default":"initiated"},"number":{"type":"string","maxLength":255,"title":"Number"},"notes":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Notes"},"shipped_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Shipped Date"},"estimated_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Estimated Delivery"},"actual_delivery":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Actual Delivery"},"received_date":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Received Date"},"total_items":{"type":"integer","title":"Total Items","default":0},"total_cost":{"type":"integer","title":"Total Cost","default":0},"currency":{"type":"string","maxLength":3,"title":"Currency","default":"RUB"},"reference":{"anyOf":[{"type":"string","maxLength":255},{"type":"null"}],"title":"Reference"},"is_received":{"type":"boolean","title":"Is Received","default":false},"shop_id":{"type":"string","title":"Shop Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"carrier_id":{"anyOf":[{"type":"string","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},{"type":"null"}],"title":"Carrier Id"},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"}},"type":"object","required":["number","shop_id","id"],"title":"TrackingSchema"},"TrackingStage":{"properties":{"stage":{"$ref":"#/components/schemas/TrackingChoices","default":"initiated"}},"type":"object","title":"TrackingStage"},"TranslationGetResponse":{"properties":{"model":{"type":"string","title":"Model","description":"Model name"},"field":{"type":"string","title":"Field","description":"Field name"},"id":{"type":"string","title":"Id","description":"Record ID","examples":["550e8400-e29b-41d4-a716-446655440000"]},"translations":{"additionalProperties":{"type":"string"},"type":"object","title":"Translations","description":"Current translations"}},"type":"object","required":["model","field","id","translations"],"title":"TranslationGetResponse","description":"Response schema for getting translations."},"TranslationRequest":{"properties":{"translations":{"additionalProperties":{"type":"string"},"type":"object","minProperties":1,"title":"Translations","description":"Dictionary of ISO language codes to translation strings","examples":[{"cn":"中文文本","en":"English text","ru":"Русский текст"}]}},"type":"object","required":["translations"],"title":"TranslationRequest","description":"Request schema for updating translations.\nAccepts a dictionary of language codes to translation strings."},"TranslationResponse":{"properties":{"model":{"type":"string","title":"Model","description":"Model name"},"field":{"type":"string","title":"Field","description":"Field name"},"id":{"type":"string","title":"Id","description":"Record ID","examples":["550e8400-e29b-41d4-a716-446655440000"]},"translations":{"additionalProperties":{"type":"string"},"type":"object","title":"Translations","description":"Current translations"},"message":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Message","description":"Operation result message"}},"type":"object","required":["model","field","id","translations"],"title":"TranslationResponse","description":"Response schema for translation operations."},"ValidationError":{"properties":{"loc":{"items":{"anyOf":[{"type":"string"},{"type":"integer"}]},"type":"array","title":"Location"},"msg":{"type":"string","title":"Message"},"type":{"type":"string","title":"Error Type"},"input":{"title":"Input"},"ctx":{"type":"object","title":"Context"}},"type":"object","required":["loc","msg","type"],"title":"ValidationError"},"VariationSchema":{"properties":{"sku":{"type":"string","maxLength":255,"title":"Sku"},"attributes":{"additionalProperties":true,"type":"object","title":"Attributes"},"color":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Color"},"size":{"anyOf":[{"type":"string"},{"type":"null"}],"title":"Size"},"weight":{"anyOf":[{"type":"number"},{"type":"null"}],"title":"Weight"},"stock":{"type":"integer","title":"Stock","default":0},"id":{"type":"string","title":"Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]},"created_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Created At"},"updated_at":{"anyOf":[{"type":"string","format":"date-time"},{"type":"null"}],"title":"Updated At"},"product_id":{"type":"string","title":"Product Id","description":"Valid UUID string","examples":["550e8400-e29b-41d4-a716-446655440000"]}},"type":"object","required":["sku","id","product_id"],"title":"VariationSchema"}},"securitySchemes":{"HTTPBearer":{"type":"http","scheme":"bearer"}}}}