{"openapi":"3.0.0","paths":{"/":{"get":{"operationId":"AppController_getRoot","parameters":[],"responses":{"200":{"description":""}},"tags":["App"]}},"/health":{"get":{"operationId":"AppController_getHealth","parameters":[],"responses":{"200":{"description":""}},"tags":["App"]}},"/v1/auth/challenge":{"post":{"operationId":"AuthController_challenge","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChallengeDTO"}}}},"responses":{"200":{"description":"Generates a unique challenge nonce for the provided address","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChallengeResponseDto"}}}}},"tags":["Auth"]}},"/v1/auth/login":{"post":{"operationId":"AuthController_login","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginDTO"}}}},"responses":{"201":{"description":"Verifies the signed message and returns access and refresh tokens","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LoginResponseDto"}}}}},"tags":["Auth"]}},"/v1/auth/refresh":{"post":{"operationId":"AuthController_refresh","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefreshDto"}}}},"responses":{"200":{"description":"Refreshes the access token using a valid refresh token","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RefreshResponseDto"}}}}},"tags":["Auth"]}},"/v1/auth/link":{"post":{"operationId":"AuthController_link","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkWalletDto"}}}},"responses":{"201":{"description":"Attaches an additional wallet (different chain) to the authenticated user","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LinkWalletResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Auth"]}},"/v1/admin/login":{"post":{"operationId":"AdminController_login","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAuthDTO"}}}},"responses":{"200":{"description":""}},"tags":["Admin"]}},"/v1/admin/addAdmin":{"post":{"operationId":"AdminController_addAdmin","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdminAuthDTO"}}}},"responses":{"201":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/admin/chains":{"get":{"operationId":"AdminController_listChains","parameters":[{"name":"name","required":false,"in":"query","description":"Chain name","schema":{"example":"Ethereum Mainnet","type":"string"}},{"name":"chainId","required":false,"in":"query","description":"Chain ID","schema":{"example":"1","type":"string"}},{"name":"cursor","required":false,"in":"query","description":"Cursor for pagination","schema":{"example":"xyz123","type":"string"}},{"name":"limit","required":false,"in":"query","description":"Number of items per page","schema":{"minimum":1,"maximum":100,"default":25,"example":25,"type":"number"}}],"responses":{"200":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/admin/chains/create":{"post":{"operationId":"AdminController_createChain","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateChainDto"}}}},"responses":{"201":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/admin/chains/{id}":{"patch":{"operationId":"AdminController_updateChain","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateChainDto"}}}},"responses":{"200":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]},"delete":{"operationId":"AdminController_removeChain","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"204":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/admin/tokens/create":{"post":{"operationId":"AdminController_createToken","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTokenDto"}}}},"responses":{"201":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/admin/tokens/{id}":{"patch":{"operationId":"AdminController_updateToken","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateTokenDto"}}}},"responses":{"200":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]},"delete":{"operationId":"AdminController_removeToken","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"204":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/admin/routes/create":{"post":{"operationId":"AdminController_createRoute","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateRouteDto"}}}},"responses":{"201":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/admin/routes/{id}":{"delete":{"operationId":"AdminController_removeRoute","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"204":{"description":""}},"security":[{"bearer":[]}],"tags":["Admin"]}},"/v1/chains":{"get":{"operationId":"ChainController_listChains","parameters":[{"name":"name","required":false,"in":"query","description":"Chain name","schema":{"example":"Ethereum Mainnet","type":"string"}},{"name":"chainId","required":false,"in":"query","description":"Chain ID","schema":{"example":"1","type":"string"}},{"name":"cursor","required":false,"in":"query","description":"Cursor for pagination","schema":{"example":"xyz123","type":"string"}},{"name":"limit","required":false,"in":"query","description":"Number of items per page","schema":{"minimum":1,"maximum":100,"default":25,"example":25,"type":"number"}}],"responses":{"200":{"description":"Returns a list of supported chains based on query parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListChainsResponseDto"}}}}},"tags":["Chains"]}},"/v1/chains/{chainId}":{"get":{"operationId":"ChainController_getChain","parameters":[{"name":"chainId","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Returns chain details by chain ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ChainResponseDto"}}}}},"tags":["Chains"]}},"/v1/tokens":{"get":{"operationId":"TokenController_list","parameters":[{"name":"chainUid","required":false,"in":"query","description":"Filter by chain uuid","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"chainId","required":false,"in":"query","description":"Filter by EVM chain id","schema":{"example":"1","type":"string"}},{"name":"symbol","required":false,"in":"query","description":"Filter by token symbol","schema":{"example":"ETH","type":"string"}},{"name":"address","required":false,"in":"query","description":"Filter by token address","schema":{"example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e","type":"string"}},{"name":"cursor","required":false,"in":"query","description":"Pagination cursor","schema":{"example":"eyJpZCI6MTAwLCJfcG9pbnRzVG9OZXh0SXRlbXMiOnRydWV9","type":"string"}},{"name":"limit","required":false,"in":"query","description":"Number of items per page","schema":{"minimum":1,"maximum":100,"default":25,"example":25,"type":"number"}}],"responses":{"200":{"description":"Returns a list of tokens based on query parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTokenResponseDto"}}}}},"tags":["Tokens"]}},"/v1/tokens/{id}":{"get":{"operationId":"TokenController_get","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Returns token details by token ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TokenDataResponseDto"}}}}},"tags":["Tokens"]}},"/v1/routes":{"get":{"operationId":"RoutesController_list","parameters":[{"name":"adTokenId","required":false,"in":"query","description":"Source token UUID","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"orderTokenId","required":false,"in":"query","description":"Destination token UUID","schema":{"example":"123e4567-e89b-12d3-a456-426614174001","type":"string"}},{"name":"adChainId","required":false,"in":"query","description":"Source chain ID","schema":{"example":"1","type":"string"}},{"name":"orderChainId","required":false,"in":"query","description":"Destination chain ID","schema":{"example":"137","type":"string"}},{"name":"symbol","required":false,"in":"query","description":"Token symbol","schema":{"example":"ETH","type":"string"}},{"name":"cursor","required":false,"in":"query","description":"Pagination cursor","schema":{"example":"next_page_token","type":"string"}},{"name":"limit","required":false,"in":"query","description":"Number of items per page","schema":{"minimum":1,"maximum":100,"default":25,"example":25,"type":"number"}}],"responses":{"200":{"description":"Returns a list of routes based on query parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListRouteResponseDto"}}}}},"tags":["Routes"]}},"/v1/routes/{id}":{"get":{"operationId":"RoutesController_get","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Returns route details by route ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/RouteDataResponseDto"}}}}},"tags":["Routes"]}},"/v1/ads":{"get":{"operationId":"AdsController_list","parameters":[{"name":"routeId","required":false,"in":"query","description":"UUID of the route to filter ads by","schema":{"format":"uuid","example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"creatorAddress","required":false,"in":"query","description":"Creator's blockchain address","schema":{"example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e","type":"string"}},{"name":"creatorAddresses","required":false,"in":"query","description":"Match any of these creator addresses (OR). Useful when the caller has multiple linked wallets across chains.","schema":{"example":["0x742d35Cc6634C0532925a3b844Bc454e4438f44e","0x0000000000000000000000000000000000000000000000000000000000000000"],"type":"array","items":{"type":"string"}}},{"name":"adChainId","required":false,"in":"query","description":"Chain ID of the ad token","schema":{"example":1,"type":"number"}},{"name":"orderChainId","required":false,"in":"query","description":"Chain ID of the order token","schema":{"example":298,"type":"number"}},{"name":"adTokenId","required":false,"in":"query","description":"Ad token ID","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"orderTokenId","required":false,"in":"query","description":"Order token ID","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"status","required":false,"in":"query","description":"Current status of the ad","schema":{"example":"ACTIVE","type":"string","enum":["ACTIVE","PAUSED","EXHAUSTED","CLOSED"]}},{"name":"cursor","required":false,"in":"query","description":"Pagination cursor","schema":{"example":"5","type":"string"}},{"name":"limit","required":false,"in":"query","description":"Number of items to return per page","schema":{"example":10,"type":"number"}}],"responses":{"200":{"description":"Returns a list of ad based on the query parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListAdResponseDto"}}}}},"tags":["Ads"]}},"/v1/ads/{id}":{"get":{"operationId":"AdsController_get","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Returns an ad by ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdResponseDto"}}}}},"tags":["Ads"]}},"/v1/ads/create":{"post":{"operationId":"AdsController_create","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAdDto"}}}},"responses":{"201":{"description":"Creates a new ad and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateAdResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Ads"]}},"/v1/ads/{id}/fund":{"post":{"operationId":"AdsController_fund","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/FundAdDto"}}}},"responses":{"200":{"description":"Funds an existing ad and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FundAdResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Ads"]}},"/v1/ads/{id}/withdraw":{"post":{"operationId":"AdsController_withdraw","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/WithdrawalAdDto"}}}},"responses":{"200":{"description":"Initiates withdrawal of funds from an ad and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/WithdrawAdResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Ads"]}},"/v1/ads/{id}/confirm":{"post":{"operationId":"AdsController_confirmUpdate","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmAdActionDto"}}}},"responses":{"200":{"description":"Confirms a chain action for an ad","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmChainActionADResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Ads"]}},"/v1/ads/{id}/update":{"patch":{"operationId":"AdsController_update","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UpdateAdDto"}}}},"responses":{"200":{"description":"Updates an existing ad","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AdUpdateResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Ads"]}},"/v1/ads/{id}/close":{"post":{"operationId":"AdsController_close","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloseAdDto"}}}},"responses":{"200":{"description":"Closes an ad and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CloseAdResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Ads"]}},"/v1/user/me":{"get":{"operationId":"UserController_getUser","parameters":[],"responses":{"200":{"description":"Returns the authenticated user information","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UserResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["User"]}},"/v1/trades/all":{"get":{"operationId":"TradesController_list","parameters":[{"name":"routeId","required":false,"in":"query","description":"UUID of the route to filter trades by","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"adId","required":false,"in":"query","description":"UUID of the advertisement to filter trades by","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"adCreatorAddress","required":false,"in":"query","description":"Address(es) of the advertisement creator. Pass a single address or an array — an array matches when any of the caller's linked wallets owns the ad.","schema":{"$ref":"#/components/schemas/Object"}},{"name":"bridgerAddress","required":false,"in":"query","description":"Address(es) of the bridger. Pass a single address or an array — an array matches when any of the caller's linked wallets created the trade.","schema":{"$ref":"#/components/schemas/Object"}},{"name":"participantAddresses","required":false,"in":"query","description":"Match trades where any of these addresses is the ad creator OR the bridger. Useful when the caller has multiple linked wallets across chains.","schema":{"type":"array","items":{"type":"string"}}},{"name":"adTokenId","required":false,"in":"query","description":"UUID of the source token","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"orderTokenId","required":false,"in":"query","description":"UUID of the destination token","schema":{"example":"123e4567-e89b-12d3-a456-426614174000","type":"string"}},{"name":"minAmount","required":false,"in":"query","description":"Minimum amount for filtering trades","schema":{"example":"1000","type":"string"}},{"name":"maxAmount","required":false,"in":"query","description":"Maximum amount for filtering trades","schema":{"example":"5000","type":"string"}},{"name":"status","required":false,"in":"query","description":"Filter trades by status (single value or comma-separated list)","schema":{"type":"array","items":{"type":"string","enum":["INACTIVE","ACTIVE","LOCKED","COMPLETED"]}}},{"name":"cursor","required":false,"in":"query","description":"Pagination cursor for fetching next set of results","schema":{"example":"nextPageToken","type":"string"}},{"name":"limit","required":false,"in":"query","description":"Number of results to return per page","schema":{"example":10,"type":"number"}}],"responses":{"200":{"description":"Returns a list of trades based on query parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ListTradesResponseDto"}}}}},"tags":["Trades"]}},"/v1/trades/{id}":{"get":{"operationId":"TradesController_get","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Returns trade details by trade ID","content":{"application/json":{"schema":{"$ref":"#/components/schemas/TradeResponseDto"}}}}},"tags":["Trades"]}},"/v1/trades/create":{"post":{"operationId":"TradesController_create","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTradeDto"}}}},"responses":{"201":{"description":"Creates a new trade and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/CreateTradeRequestContractResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Trades"]}},"/v1/trades/{id}/params":{"get":{"operationId":"TradesController_params","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Trade parameters","content":{"application/json":{"schema":{"$ref":"#/components/schemas/OrderParamsResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Trades"]}},"/v1/trades/{id}/lock":{"post":{"operationId":"TradesController_lock","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":"Locks a trade for order and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/LockForOrderResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Trades"]}},"/v1/trades/{id}/unlock":{"post":{"operationId":"TradesController_unlock","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnlockTradeDto"}}}},"responses":{"200":{"description":"Unlocks a trade and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/UnlockOrderResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Trades"]}},"/v1/trades/{id}/unlock/confirm":{"post":{"operationId":"TradesController_confirmUnlockChainAction","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmTradeActionDto"}}}},"responses":{"200":{"description":"Confirms the unlock action on a trade and returns the transaction data for blockchain execution","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmChainActionTradeResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Trades"]}},"/v1/trades/{id}/confirm":{"post":{"operationId":"TradesController_confirmChainAction","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmTradeActionDto"}}}},"responses":{"200":{"description":"Confirms a chain action for a trade","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ConfirmChainActionTradeResponseDto"}}}}},"security":[{"bearer":[]}],"tags":["Trades"]}},"/v1/notifications":{"get":{"operationId":"NotificationController_list","parameters":[{"name":"unreadOnly","required":false,"in":"query","description":"Return only unread notifications","schema":{"example":true,"type":"boolean"}},{"name":"limit","required":false,"in":"query","schema":{"minimum":1,"maximum":100,"example":20,"type":"number"}},{"name":"cursor","required":false,"in":"query","description":"Cursor (last notification id)","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"security":[{"bearer":[]}],"summary":"List the caller’s notifications","tags":["Notifications"]}},"/v1/notifications/unread-count":{"get":{"operationId":"NotificationController_unreadCount","parameters":[],"responses":{"200":{"description":""}},"security":[{"bearer":[]}],"summary":"Unread notification count for the caller","tags":["Notifications"]}},"/v1/notifications/{id}/read":{"patch":{"operationId":"NotificationController_markRead","parameters":[{"name":"id","required":true,"in":"path","schema":{"type":"string"}}],"responses":{"200":{"description":""}},"security":[{"bearer":[]}],"summary":"Mark a single notification as read","tags":["Notifications"]}},"/v1/notifications/read-all":{"post":{"operationId":"NotificationController_markAllRead","parameters":[],"responses":{"200":{"description":""}},"security":[{"bearer":[]}],"summary":"Mark every unread notification as read","tags":["Notifications"]}},"/v1/mmr/proof":{"get":{"operationId":"MMRController_getProof","parameters":[],"responses":{"200":{"description":""}},"tags":["MMR"]}},"/v1/faucet/request":{"post":{"description":"Mint faucet tokens for a given token ID and send to receiver address","operationId":"FaucetController_requestFaucet","parameters":[],"requestBody":{"required":true,"content":{"application/json":{"schema":{"$ref":"#/components/schemas/RequestFaucetDto"}}}},"responses":{"200":{"description":"Successfully minted and sent faucet tokens","content":{"application/json":{"schema":{"$ref":"#/components/schemas/FaucetResponseDto"}}}}},"security":[{"bearer":[]}],"summary":"Request faucet tokens","tags":["Faucet"]}}},"info":{"title":"Proof Relayer API","description":"ProofBridge Relayer REST API. The OpenAPI specification is in active development and may change before the 1.0 mainnet release.","version":"0.1.0","contact":{}},"tags":[],"servers":[{"url":"http://localhost:2005","description":"Local"}],"components":{"securitySchemes":{"bearer":{"scheme":"bearer","bearerFormat":"JWT","type":"http"},"cookie":{"type":"apiKey","in":"cookie","name":"connect.sid"}},"schemas":{"ChallengeDTO":{"type":"object","properties":{"chainKind":{"type":"string","description":"Chain kind the caller is authenticating with","enum":["EVM","STELLAR"],"example":"EVM"},"address":{"type":"string","description":"Wallet address — 0x-prefixed 20-byte hex for EVM, G-strkey for Stellar","example":"0x1234..."}},"required":["chainKind","address"]},"ChallengeResponseDto":{"type":"object","properties":{"chainKind":{"type":"string","enum":["EVM","STELLAR"]},"address":{"type":"string","description":"Echoed wallet address (canonical form)"},"expiresAt":{"type":"string","description":"Expiration timestamp (ISO8601)"},"nonce":{"type":"string","description":"Unique nonce for SIWE (EVM only)"},"domain":{"type":"string","description":"SIWE domain (EVM only)"},"uri":{"type":"string","description":"SIWE URI (EVM only)"},"transaction":{"type":"string","description":"Server-signed SEP-10 challenge transaction (Stellar only)"},"networkPassphrase":{"type":"string","description":"Stellar network passphrase (Stellar only)"}},"required":["chainKind","address","expiresAt"]},"LoginDTO":{"type":"object","properties":{"chainKind":{"type":"string","description":"Chain kind matching the original challenge","enum":["EVM","STELLAR"],"example":"EVM"},"message":{"type":"string","description":"SIWE message string (EVM path only)"},"signature":{"type":"string","description":"SIWE signature (EVM path only)"},"transaction":{"type":"string","description":"Co-signed SEP-10 challenge transaction, base64 XDR (Stellar path only)"}},"required":["chainKind"]},"LoginResponseDto":{"type":"object","properties":{"user":{"type":"object","description":"User information","example":{"id":"123","username":"user123"}},"tokens":{"type":"object","description":"Authentication tokens","example":{"access":"eyJhbGciOiJIUzI1...","refresh":"eyJhbGciOiJIUzI1..."}}},"required":["user","tokens"]},"RefreshDto":{"type":"object","properties":{"refresh":{"type":"string","description":"Refresh token","example":"eyJhbGciOiJIUzI1..."}},"required":["refresh"]},"RefreshResponseDto":{"type":"object","properties":{"tokens":{"type":"object","description":"Authentication tokens","example":{"access":"eyJhbGciOiJIUzI1...","refresh":"eyJhbGciOiJIUzI1..."}}},"required":["tokens"]},"LinkWalletDto":{"type":"object","properties":{"chainKind":{"type":"string","description":"Chain kind matching the challenge being signed","enum":["EVM","STELLAR"],"example":"STELLAR"},"message":{"type":"string","description":"SIWE message string (EVM path only)"},"signature":{"type":"string","description":"SIWE signature (EVM path only)"},"transaction":{"type":"string","description":"Co-signed SEP-10 challenge transaction, base64 XDR (Stellar path only)"}},"required":["chainKind"]},"LinkWalletResponseDto":{"type":"object","properties":{"id":{"type":"string","description":"Newly linked wallet row id"},"address":{"type":"string","description":"Canonical wallet address stored in DB"},"chainKind":{"type":"string","enum":["EVM","STELLAR"]},"createdAt":{"format":"date-time","type":"string","description":"Link creation timestamp (ISO8601)"}},"required":["id","address","chainKind","createdAt"]},"AdminAuthDTO":{"type":"object","properties":{"email":{"type":"string","description":"The email address of the admin","example":"admin@example.com"},"password":{"type":"string","description":"The password for the admin account","example":"password123","minLength":8}},"required":["email","password"]},"CreateChainDto":{"type":"object","properties":{"name":{"type":"string","description":"Chain name","example":"Ethereum Mainnet"},"chainId":{"type":"string","description":"Chain ID","pattern":"/^d+$","example":"1"},"kind":{"type":"string","description":"Chain kind (defaults to EVM)","enum":["EVM","STELLAR"],"example":"EVM"},"adManagerAddress":{"type":"string","description":"Ad Manager contract address","example":"0x1234567890abcdef1234567890abcdef12345678"},"orderPortalAddress":{"type":"string","description":"Order Portal contract address","example":"0xabcdef1234567890abcdef1234567890abcdef12"}},"required":["name","chainId","adManagerAddress","orderPortalAddress"]},"UpdateChainDto":{"type":"object","properties":{"name":{"type":"string","description":"Chain name","example":"Ethereum Mainnet"},"chainId":{"type":"string","description":"Chain ID","pattern":"^d+$","example":"1"},"kind":{"type":"string","description":"Chain kind","enum":["EVM","STELLAR"],"example":"EVM"},"adManagerAddress":{"type":"string","description":"Ad Manager contract address","example":"0x1234567890abcdef1234567890abcdef12345678"},"orderPortalAddress":{"type":"string","description":"Order Portal contract address","example":"0xabcdef1234567890abcdef1234567890abcdef12"}}},"CreateTokenDto":{"type":"object","properties":{"chainUid":{"type":"string","description":"Internal chain UUID","example":"123e4567-e89b-12d3-a456-426614174000"},"symbol":{"type":"string","description":"Token symbol","example":"ETH"},"name":{"type":"string","description":"Token name","example":"Ethereum"},"address":{"type":"string","description":"Token address (will be lowercased)","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"decimals":{"type":"number","description":"Token decimals","minimum":0,"maximum":30,"example":18},"kind":{"type":"string","description":"Token kind","enum":["NATIVE","ERC20","SAC","SEP41"],"example":"NATIVE"},"assetIssuer":{"type":"string","description":"Stellar classic-asset issuer (G-strkey). Required when kind is SAC.","example":"GA5ZSEJYB37JRC5AVCIA5MOP4RHTM335X2KGX3IHOJAPP5RE34K4KZVN"}},"required":["chainUid","symbol","name","address","decimals"]},"UpdateTokenDto":{"type":"object","properties":{"chainUid":{"type":"string","description":"Internal chain UUID","example":"123e4567-e89b-12d3-a456-426614174000"},"symbol":{"type":"string","description":"Token symbol","example":"ETH"},"name":{"type":"string","description":"Token name","example":"Ethereum"},"address":{"type":"string","description":"Token address","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"decimals":{"type":"number","description":"Token decimals","minimum":0,"maximum":30,"example":18},"kind":{"type":"string","description":"Token kind","enum":["NATIVE","ERC20","SAC","SEP41"],"example":"NATIVE"},"assetIssuer":{"type":"string","description":"Stellar classic-asset issuer (G-strkey). Pass an empty string to clear (only when kind is moving off SAC).","example":"GA5ZSEJYB37JRC5AVCIA5MOP4RHTM335X2KGX3IHOJAPP5RE34K4KZVN"}}},"CreateRouteDto":{"type":"object","properties":{"adTokenId":{"type":"string","description":"Source token UUID","example":"123e4567-e89b-12d3-a456-426614174000"},"orderTokenId":{"type":"string","description":"Destination token UUID","example":"123e4567-e89b-12d3-a456-426614174001"},"metadata":{"type":"object","description":"Additional metadata for the route","example":{"fee":0.1,"slippage":0.5}}},"required":["adTokenId","orderTokenId"]},"ChainResponseDto":{"type":"object","properties":{"name":{"type":"string","description":"Chain name","example":"Ethereum Mainnet"},"chainId":{"type":"string","description":"Chain ID","example":"1"},"kind":{"type":"string","description":"Chain kind","enum":["EVM","STELLAR"],"example":"EVM"},"adManagerAddress":{"type":"string","description":"Ad Manager contract address","example":"0x1234567890abcdef1234567890abcdef12345678"},"orderPortalAddress":{"type":"string","description":"Order Portal contract address","example":"0xabcdef1234567890abcdef1234567890abcdef12"},"createdAt":{"type":"string","description":"Creation timestamp","example":"2023-01-01T00:00:00Z"},"updatedAt":{"type":"string","description":"Last update timestamp","example":"2023-01-01T00:00:00Z"}},"required":["name","chainId","kind","adManagerAddress","orderPortalAddress","createdAt","updatedAt"]},"ListChainsResponseDto":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/ChainResponseDto"}},"nextCursor":{"type":"object","description":"Next pagination cursor","example":"xyz123","nullable":true}},"required":["data","nextCursor"]},"TokenChainDto":{"type":"object","properties":{"id":{"type":"string","description":"Chain ID"},"name":{"type":"string","description":"Chain name"},"chainId":{"type":"string","description":"EVM chain ID"},"kind":{"type":"string","description":"Chain kind","enum":["EVM","STELLAR"]}},"required":["id","name","chainId","kind"]},"TokenDataResponseDto":{"type":"object","properties":{"id":{"type":"string","description":"Token ID"},"symbol":{"type":"string","description":"Token symbol"},"name":{"type":"string","description":"Token name"},"address":{"type":"string","description":"Token address"},"decimals":{"type":"number","description":"Token decimals"},"kind":{"type":"string","description":"Token kind"},"assetIssuer":{"type":"string","description":"Stellar classic-asset issuer (G-strkey). Populated only for SAC tokens.","nullable":true},"createdAt":{"type":"string","description":"Creation timestamp"},"updatedAt":{"type":"string","description":"Last update timestamp"},"chain":{"description":"Chain information","allOf":[{"$ref":"#/components/schemas/TokenChainDto"}]}},"required":["id","symbol","name","address","decimals","kind","assetIssuer","createdAt","updatedAt","chain"]},"ListTokenResponseDto":{"type":"object","properties":{"data":{"description":"Array of token data","type":"array","items":{"$ref":"#/components/schemas/TokenDataResponseDto"}},"nextCursor":{"type":"string","description":"Cursor for the next page of results","nullable":true}},"required":["data","nextCursor"]},"ChainDto":{"type":"object","properties":{"id":{"type":"string","description":"Chain ID","example":"1"},"name":{"type":"string","description":"Chain name","example":"Ethereum"},"chainId":{"type":"string","description":"Chain ID string","example":"1"}},"required":["id","name","chainId"]},"TokenDto":{"type":"object","properties":{"id":{"type":"string","description":"Token ID","example":"123e4567-e89b-12d3-a456-426614174000"},"symbol":{"type":"string","description":"Token symbol","example":"ETH"},"name":{"type":"string","description":"Token name","example":"Ethereum"},"address":{"type":"string","description":"Token contract address","example":"0x..."},"decimals":{"type":"number","description":"Token decimals","example":18},"kind":{"type":"string","description":"Token kind","example":"native"},"chain":{"description":"Token chain information","allOf":[{"$ref":"#/components/schemas/ChainDto"}]}},"required":["id","symbol","name","address","decimals","kind","chain"]},"RouteDataResponseDto":{"type":"object","properties":{"id":{"type":"string","description":"Route ID"},"metadata":{"type":"object","description":"Route metadata"},"createdAt":{"type":"string","description":"Creation timestamp"},"updatedAt":{"type":"string","description":"Last update timestamp"},"adToken":{"description":"Source token information","allOf":[{"$ref":"#/components/schemas/TokenDto"}]},"orderToken":{"description":"Destination token information","allOf":[{"$ref":"#/components/schemas/TokenDto"}]}},"required":["id","metadata","createdAt","updatedAt","adToken","orderToken"]},"ListRouteResponseDto":{"type":"object","properties":{"data":{"description":"Array of route data","type":"array","items":{"$ref":"#/components/schemas/RouteDataResponseDto"}},"nextCursor":{"type":"string","description":"Next page cursor","nullable":true}},"required":["data","nextCursor"]},"AdResponseDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"Unique identifier of the ad entry"},"creatorAddress":{"type":"string","description":"EVM address of the ad creator"},"routeId":{"type":"string","format":"uuid","description":"Associated route identifier"},"adTokenId":{"type":"string","description":"Token ID for the source/input token"},"orderTokenId":{"type":"string","description":"Token ID for the target/output token"},"poolAmount":{"type":"string","pattern":"^d+$","description":"Total amount allocated to the pool (in smallest token units)"},"availableAmount":{"type":"string","pattern":"^d+$","description":"Current available amount in the pool (in smallest token units)"},"minAmount":{"type":"object","pattern":"^d+$","nullable":true,"description":"Minimum transaction amount allowed (in smallest token units)"},"maxAmount":{"type":"object","pattern":"^d+$","nullable":true,"description":"Maximum transaction amount allowed (in smallest token units)"},"status":{"type":"string","enum":["ACTIVE","PAUSED","EXHAUSTED","CLOSED"],"description":"Current status of the advertisement"},"metadata":{"type":"object","nullable":true,"description":"Additional custom metadata associated with the ad"},"adToken":{"description":"Details of the ad token","allOf":[{"$ref":"#/components/schemas/TokenDto"}]},"orderToken":{"description":"Details of the order token","allOf":[{"$ref":"#/components/schemas/TokenDto"}]},"createdAt":{"type":"string","description":"Timestamp when the ad entry was created"},"updatedAt":{"type":"string","description":"Timestamp of the last update to the ad entry"}},"required":["id","creatorAddress","routeId","adTokenId","orderTokenId","poolAmount","availableAmount","minAmount","maxAmount","status","metadata","adToken","orderToken","createdAt","updatedAt"]},"ListAdResponseDto":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/AdResponseDto"}},"nextCursor":{"type":"string","nullable":true}},"required":["data","nextCursor"]},"CreateAdDto":{"type":"object","properties":{"routeId":{"type":"string","format":"uuid","description":"UUID of the route to create ad for","example":"123e4567-e89b-12d3-a456-426614174000"},"creatorDstAddress":{"type":"string","description":"Destination blockchain address of the creator","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"fundAmount":{"type":"string","description":"Initial amount to fund the ad pool (in smallest unit)","example":"1000000000000000000"},"minAmount":{"type":"string","pattern":"^d+$","description":"Minimum amount for the ad (in smallest unit)","example":"100000000000000000"},"maxAmount":{"type":"string","pattern":"^d+$","description":"Maximum amount for the ad (in smallest unit)","example":"5000000000000000000"},"metadata":{"type":"object","description":"Additional metadata for the ad","example":{"title":"My Ad","description":"Ad description"}}},"required":["routeId","creatorDstAddress","fundAmount"]},"CreateAdResponseDto":{"type":"object","properties":{"chainId":{"type":"string","description":"Blockchain chain ID where the ad contract is deployed","example":"1"},"contractAddress":{"type":"string","description":"Contract address for the advertisement","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"signature":{"type":"string","description":"Signature for the transaction request","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"signerPublicKey":{"type":"string","description":"Signer public key (Stellar chains only — 0x-prefixed 32-byte hex of the relayer signer)"},"authToken":{"type":"string","description":"Request auth token","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"timeToExpire":{"type":"number","description":"Time until the request expires","example":3600},"adId":{"type":"string","description":"Unique identifier for the advertisement","example":"ad123"},"adToken":{"type":"string","description":"Token address for the advertisement","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"initialAmount":{"type":"string","pattern":"^d+$","description":"Initial Amount to fund the ad pool with"},"orderChainId":{"type":"string","description":"Chain ID for the order","example":"1"},"adRecipient":{"type":"string","description":"Recipient address for the advertisement","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"reqHash":{"type":"string","description":"Request hash","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"chainKind":{"type":"string","enum":["EVM","STELLAR"],"description":"Kind of chain the ad contract runs on"}},"required":["chainId","contractAddress","signature","authToken","timeToExpire","adId","adToken","initialAmount","orderChainId","adRecipient","reqHash","chainKind"]},"FundAdDto":{"type":"object","properties":{"poolAmountTopUp":{"type":"string","pattern":"^d+$","description":"Amount to add to the ad pool (in smallest unit)","example":"1000000000000000000"}},"required":["poolAmountTopUp"]},"FundAdResponseDto":{"type":"object","properties":{"chainId":{"type":"string","description":"Blockchain chain ID where the ad contract is deployed","example":"1"},"contractAddress":{"type":"string","description":"Contract address for the advertisement","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"signature":{"type":"string","description":"Signature for the transaction request","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"authToken":{"type":"string","description":"Request auth token","example":"0xd35Cc6634C0532925a3b844Bc454e4438f44e"},"timeToExpire":{"type":"number","description":"Time until the request expires","example":3600},"adId":{"type":"string","description":"Unique identifier for the advertisement","example":"ad123"},"amount":{"type":"string","description":"Amount to fund","example":"1000000000000000000"},"reqHash":{"type":"string","description":"Request hash","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"chainKind":{"type":"string","enum":["EVM","STELLAR"],"description":"Kind of chain the ad contract runs on"}},"required":["chainId","contractAddress","signature","authToken","timeToExpire","adId","amount","reqHash","chainKind"]},"WithdrawalAdDto":{"type":"object","properties":{"poolAmountWithdraw":{"type":"string","pattern":"^d+$","description":"Amount to withdraw from the ad pool (in smallest unit)","example":"1000000000000000000"},"to":{"type":"string","description":"Destination address for withdrawal","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"}},"required":["poolAmountWithdraw","to"]},"WithdrawAdResponseDto":{"type":"object","properties":{"chainId":{"type":"string","description":"Blockchain chain ID where the ad contract is deployed","example":"1"},"contractAddress":{"type":"string","description":"Contract address for the advertisement","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"signature":{"type":"string","description":"Signature for the transaction request","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"authToken":{"type":"string","description":"Request auth token","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"timeToExpire":{"type":"number","description":"Time until the request expires","example":3600},"adId":{"type":"string","description":"Unique identifier for the advertisement","example":"ad123"},"amount":{"type":"string","description":"Amount to withdraw","example":"1000000000000000000"},"to":{"type":"string","description":"Destination address for withdrawal","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"reqHash":{"type":"string","description":"Request hash","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"chainKind":{"type":"string","enum":["EVM","STELLAR"],"description":"Kind of chain the ad contract runs on"}},"required":["chainId","contractAddress","signature","authToken","timeToExpire","adId","amount","to","reqHash","chainKind"]},"ConfirmAdActionDto":{"type":"object","properties":{"txHash":{"type":"string","description":"Transaction hash of the chain action","example":"0x123f681646d4a755815f9cb19e1acc8565a0c2ac8e625e37ef3dbf9c8feb8a7e"},"signature":{"type":"string","description":"Optional signature for the chain action","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"}},"required":["txHash"]},"ConfirmChainActionADResponseDto":{"type":"object","properties":{"adId":{"type":"string","format":"uuid","description":"Ad identifier","example":"b693ab22-5e73-47e8-9937-1d4459b8c081"},"success":{"type":"boolean","description":"Whether the chain action was confirmed successfully","example":true}},"required":["adId","success"]},"UpdateAdDto":{"type":"object","properties":{"status":{"type":"string","enum":["ACTIVE","PAUSED"],"description":"New status for the ad","example":"ACTIVE"},"minAmount":{"type":"string","pattern":"^d+$","description":"Minimum amount for the ad (in smallest unit)","example":"100000000000000000"},"maxAmount":{"type":"string","pattern":"^d+$","description":"Maximum amount for the ad (in smallest unit)","example":"5000000000000000000"},"metadata":{"type":"object","description":"Updated metadata for the ad","example":{"title":"Updated Ad","description":"New description"}}}},"AdUpdateResponseDto":{"type":"object","properties":{"id":{"type":"string","format":"uuid","description":"Unique identifier of the ad entry"},"creatorAddress":{"type":"string","description":"EVM address of the ad creator"},"minAmount":{"type":"object","pattern":"^d+$","nullable":true,"description":"Minimum transaction amount allowed (in smallest token units)"},"maxAmount":{"type":"object","pattern":"^d+$","nullable":true,"description":"Maximum transaction amount allowed (in smallest token units)"},"metadata":{"type":"object","nullable":true,"description":"Additional custom metadata associated with the ad"}},"required":["id","creatorAddress","minAmount","maxAmount","metadata"]},"CloseAdDto":{"type":"object","properties":{"to":{"type":"string","description":"Address to send remaining funds when closing the ad","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"}},"required":["to"]},"CloseAdResponseDto":{"type":"object","properties":{"chainId":{"type":"string","description":"Blockchain chain ID where the ad contract is deployed","example":"1"},"contractAddress":{"type":"string","description":"Contract address for the advertisement","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"signature":{"type":"string","description":"Signature for the transaction request","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"authToken":{"type":"string","description":"Request auth token","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"timeToExpire":{"type":"number","description":"Time until the request expires","example":3600},"adId":{"type":"string","description":"Unique identifier for the advertisement","example":"ad123"},"to":{"type":"string","description":"Destination address for withdrawal","example":"0x742d35Cc6634C0532925a3b844Bc454e4438f44e"},"reqHash":{"type":"string","description":"Request hash","example":"0x1234567890abcdef1234567890abcdef1234567890abcdef1234567890abcdef"},"chainKind":{"type":"string","enum":["EVM","STELLAR"],"description":"Kind of chain the ad contract runs on"}},"required":["chainId","contractAddress","signature","authToken","timeToExpire","adId","to","reqHash","chainKind"]},"UserWalletDto":{"type":"object","properties":{"address":{"type":"string","description":"Canonical wallet address — 0x-prefixed for EVM, 0x+64hex for Stellar"},"chainKind":{"type":"string","enum":["EVM","STELLAR"]},"createdAt":{"format":"date-time","type":"string","description":"When this wallet was first linked"}},"required":["address","chainKind","createdAt"]},"UserResponseDto":{"type":"object","properties":{"id":{"type":"string"},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"username":{"type":"string"},"wallets":{"description":"Wallets linked to this user (at most one per chain kind)","type":"array","items":{"$ref":"#/components/schemas/UserWalletDto"}}},"required":["id","createdAt","updatedAt","username","wallets"]},"Object":{"type":"object","properties":{}},"AdDto":{"type":"object","properties":{"id":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000"},"routeId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000"},"creatorAddress":{"type":"string","example":"0x1234567890abcdef"}},"required":["id","routeId","creatorAddress"]},"RouteDto":{"type":"object","properties":{"id":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000"},"adToken":{"$ref":"#/components/schemas/TokenDto"},"orderToken":{"$ref":"#/components/schemas/TokenDto"}},"required":["id","adToken","orderToken"]},"TradeResponseDto":{"type":"object","properties":{"id":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000"},"routeId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000"},"adId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000"},"adCreatorAddress":{"type":"string","example":"0x1234567890abcdef"},"adChainId":{"type":"string","example":"1"},"orderChainId":{"type":"string","example":"294"},"bridgerAddress":{"type":"string","example":"0x1234567890abcdef"},"amount":{"type":"string","example":"1000"},"status":{"type":"string","example":"PENDING"},"createdAt":{"format":"date-time","type":"string"},"updatedAt":{"format":"date-time","type":"string"},"ad":{"$ref":"#/components/schemas/AdDto"},"route":{"$ref":"#/components/schemas/RouteDto"},"adCreatorClaimed":{"type":"boolean"},"bridgerClaimed":{"type":"boolean"}},"required":["id","routeId","adId","adCreatorAddress","adChainId","orderChainId","bridgerAddress","amount","status","createdAt","updatedAt","ad","route","adCreatorClaimed","bridgerClaimed"]},"ListTradesResponseDto":{"type":"object","properties":{"data":{"type":"array","items":{"$ref":"#/components/schemas/TradeResponseDto"}},"nextCursor":{"type":"object","example":"nextPageToken","nullable":true}},"required":["data","nextCursor"]},"CreateTradeDto":{"type":"object","properties":{"adId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000","description":"UUID of the advertisement for the trade"},"routeId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000","description":"UUID of the route for the trade"},"amount":{"type":"string","example":"1000","description":"Amount of tokens to trade"},"bridgerDstAddress":{"type":"string","example":"0x1234567890abcdef","description":"Destination address for the bridger"}},"required":["adId","routeId","amount","bridgerDstAddress"]},"OrderPortalParamsDto":{"type":"object","properties":{"orderChainToken":{"type":"string","example":"0x1234567890abcdef","description":"Order chain token address"},"adChainToken":{"type":"string","example":"0x1234567890abcdef","description":"Ad chain token address"},"amount":{"type":"string","example":"1000","description":"Amount of tokens"},"bridger":{"type":"string","example":"0x1234567890abcdef","description":"Bridger address"},"orderRecipient":{"type":"string","example":"0x1234567890abcdef","description":"Order recipient address"},"adChainId":{"type":"string","example":"1","description":"Ad chain ID"},"adManager":{"type":"string","example":"0x1234567890abcdef","description":"Ad manager address"},"adId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000","description":"Advertisement ID"},"adCreator":{"type":"string","example":"0x1234567890abcdef","description":"Ad creator address"},"adRecipient":{"type":"string","example":"0x1234567890abcdef","description":"Ad recipient address"},"salt":{"type":"string","example":"123456","description":"Salt value"},"orderDecimals":{"type":"number","example":6,"description":"Order-chain token decimals"},"adDecimals":{"type":"number","example":18,"description":"Ad-chain token decimals"}},"required":["orderChainToken","adChainToken","amount","bridger","orderRecipient","adChainId","adManager","adId","adCreator","adRecipient","salt","orderDecimals","adDecimals"]},"CreateOrderRequestContractDetailsDto":{"type":"object","properties":{"chainId":{"type":"string","description":"Blockchain chain ID where the order contract is deployed","example":"1"},"contractAddress":{"type":"string","example":"0x1234567890abcdef","description":"Contract address"},"signature":{"type":"string","example":"0x1234567890abcdef...","description":"Signature value"},"authToken":{"type":"string","example":"token123","description":"Authentication token"},"timeToExpire":{"type":"number","example":3600,"description":"Time until expiration in seconds"},"orderParams":{"description":"Order portal parameters","allOf":[{"$ref":"#/components/schemas/OrderPortalParamsDto"}]},"orderHash":{"type":"string","example":"0x1234567890abcdef...","description":"Order hash"},"reqHash":{"type":"string","example":"0x1234567890abcdef...","description":"Request hash"},"chainKind":{"type":"string","enum":["EVM","STELLAR"],"description":"Kind of chain the order contract runs on"}},"required":["chainId","contractAddress","signature","authToken","timeToExpire","orderParams","orderHash","reqHash","chainKind"]},"CreateTradeRequestContractResponseDto":{"type":"object","properties":{"tradeId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000","description":"Trade ID"},"reqContractDetails":{"description":"Contract request details","allOf":[{"$ref":"#/components/schemas/CreateOrderRequestContractDetailsDto"}]}},"required":["tradeId","reqContractDetails"]},"OrderParamsResponseDto":{"type":"object","properties":{"orderChainToken":{"type":"string","example":"0x1234567890abcdef","description":"Order chain token address"},"adChainToken":{"type":"string","example":"0x1234567890abcdef","description":"Ad chain token address"},"amount":{"type":"string","example":"1000","description":"Amount of tokens"},"bridger":{"type":"string","example":"0x1234567890abcdef","description":"Bridger address"},"orderRecipient":{"type":"string","example":"0x1234567890abcdef","description":"Order recipient address"},"adId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000","description":"Advertisement ID"},"adCreator":{"type":"string","example":"0x1234567890abcdef","description":"Ad creator address"},"adRecipient":{"type":"string","example":"0x1234567890abcdef","description":"Ad recipient address"},"salt":{"type":"string","example":"123456","description":"Salt value"},"orderChainId":{"type":"string","example":"1","description":"Order chain ID"},"orderPortal":{"type":"string","example":"0x1234567890abcdef","description":"Order portal address"},"adChainId":{"type":"string","example":"1","description":"Ad chain ID"},"adManager":{"type":"string","example":"0x1234567890abcdef","description":"Ad manager address"},"orderDecimals":{"type":"number","example":18,"description":"Decimals of the order-chain token"},"adDecimals":{"type":"number","example":7,"description":"Decimals of the ad-chain token"}},"required":["orderChainToken","adChainToken","amount","bridger","orderRecipient","adId","adCreator","adRecipient","salt","orderChainId","orderPortal","adChainId","adManager","orderDecimals","adDecimals"]},"AdManagerOrderParamsDto":{"type":"object","properties":{"orderChainToken":{"type":"string","example":"0x1234567890abcdef","description":"Order chain token address"},"adChainToken":{"type":"string","example":"0x1234567890abcdef","description":"Ad chain token address"},"amount":{"type":"string","example":"1000","description":"Amount of tokens"},"bridger":{"type":"string","example":"0x1234567890abcdef","description":"Bridger address"},"orderChainId":{"type":"string","example":"1","description":"Order chain ID"},"srcOrderPortal":{"type":"string","example":"0x1234567890abcdef","description":"Order portal address"},"orderRecipient":{"type":"string","example":"0x1234567890abcdef","description":"Order recipient address"},"adId":{"type":"string","example":"123e4567-e89b-12d3-a456-426614174000","description":"Advertisement ID"},"adCreator":{"type":"string","example":"0x1234567890abcdef","description":"Ad creator address"},"adRecipient":{"type":"string","example":"0x1234567890abcdef","description":"Ad recipient address"},"salt":{"type":"string","example":"123456","description":"Salt value"},"orderDecimals":{"type":"number","example":6,"description":"Order-chain token decimals"},"adDecimals":{"type":"number","example":18,"description":"Ad-chain token decimals"}},"required":["orderChainToken","adChainToken","amount","bridger","orderChainId","srcOrderPortal","orderRecipient","adId","adCreator","adRecipient","salt","orderDecimals","adDecimals"]},"LockForOrderResponseDto":{"type":"object","properties":{"chainId":{"type":"string","description":"Blockchain chain ID where the ad contract is deployed","example":"1"},"contractAddress":{"type":"string","example":"0x1234567890abcdef","description":"Contract address"},"signature":{"type":"string","example":"0x1234567890abcdef...","description":"Signature value"},"authToken":{"type":"string","example":"token123","description":"Authentication token"},"timeToExpire":{"type":"number","example":3600,"description":"Time until request expires in seconds"},"orderParams":{"description":"AdManager order parameters","allOf":[{"$ref":"#/components/schemas/AdManagerOrderParamsDto"}]},"reqHash":{"type":"string","example":"0x1234567890abcdef...","description":"Request hash"},"orderHash":{"type":"string","example":"0x1234567890abcdef...","description":"Order hash"},"chainKind":{"type":"string","enum":["EVM","STELLAR"],"description":"Kind of chain the ad contract runs on"}},"required":["chainId","contractAddress","signature","authToken","timeToExpire","orderParams","reqHash","orderHash","chainKind"]},"UnlockTradeDto":{"type":"object","properties":{"signature":{"type":"string","example":"0x1234567890...","description":"Signature for trade authorization"}},"required":["signature"]},"UnlockOrderResponseDto":{"type":"object","properties":{"chainId":{"type":"string","description":"Blockchain chain ID where the order/ad contract is deployed","example":"1"},"contractAddress":{"type":"string","example":"0x1234567890abcdef","description":"Contract address"},"signature":{"type":"string","example":"0x1234567890abcdef...","description":"Signature value"},"authToken":{"type":"string","example":"token123","description":"Authentication token"},"timeToExpire":{"type":"number","example":3600,"description":"Time until expiration in seconds"},"orderParams":{"type":"object","description":"Order parameters","example":{"orderChainToken":"0x1234567890abcdef","adChainToken":"0x1234567890abcdef","amount":"1000","bridger":"0x1234567890abcdef","orderChainId":"1","orderPortal":"0x1234567890abcdef","orderRecipient":"0x1234567890abcdef","adId":"123e4567-e89b-12d3-a456-426614174000","adCreator":"0x1234567890abcdef","adRecipient":"0x1234567890abcdef","salt":"123456","orderDecimals":6,"adDecimals":18}},"nullifierHash":{"type":"string","example":"0x1234567890abcdef...","description":"Nullifier hash"},"targetRoot":{"type":"string","example":"0x1234567890abcdef...","description":"Target root"},"proof":{"type":"string","example":"0x1234567890abcdef...","description":"Proof value"},"orderHash":{"type":"string","example":"0x1234567890abcdef...","description":"Order hash"},"reqHash":{"type":"string","example":"0x1234567890abcdef...","description":"Request hash"},"chainKind":{"type":"string","enum":["EVM","STELLAR"],"description":"Kind of chain the unlock runs on"}},"required":["chainId","contractAddress","signature","authToken","timeToExpire","orderParams","nullifierHash","targetRoot","proof","orderHash","reqHash","chainKind"]},"ConfirmTradeActionDto":{"type":"object","properties":{"txHash":{"type":"string","example":"0x1234567890abcdef","description":"Transaction hash of the chain action"},"signature":{"type":"string","example":"0x1234567890...","description":"Optional signature for confirming the chain action"}},"required":["txHash"]},"ConfirmChainActionTradeResponseDto":{"type":"object","properties":{"tradeId":{"type":"string","description":"trade identifier","example":"123e4567-e89b-12d3-a456-426614174000"},"success":{"type":"boolean","description":"Whether the chain action was confirmed successfully","example":true}},"required":["tradeId","success"]},"RequestFaucetDto":{"type":"object","properties":{"tokenId":{"type":"string","description":"Token ID (UUID) to request faucet for","example":"123e4567-e89b-12d3-a456-426614174000"}},"required":["tokenId"]},"FaucetResponseDto":{"type":"object","properties":{"txHash":{"type":"string","description":"Transaction hash of the mint transaction"},"symbol":{"type":"string","description":"Token symbol that was minted"},"chainId":{"type":"string","description":"Chain ID where the transaction was executed"},"amount":{"type":"string","description":"Amount of tokens minted"}},"required":["txHash","symbol","chainId","amount"]}}}}