{"openapi":"3.1.0","info":{"title":"world-id-indexer","description":"","license":{"name":"MIT","identifier":"MIT"},"version":"0.1.5"},"paths":{"/authenticator-pubkeys":{"post":{"tags":["indexer"],"summary":"Get Authenticator Pubkeys","description":"Returns the compressed authenticator public keys for a given World ID by leaf index.\nRemoved authenticator slots are returned as `null` to preserve `pubkey_id` positions.","operationId":"handler","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerQueryRequest"}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerAuthenticatorPubkeysResponse"}}}}}}},"/inclusion-proof":{"post":{"tags":["indexer"],"summary":"Get Inclusion Proof","description":"Returns a Merkle inclusion proof for the given leaf index to the current `WorldIDRegistry` tree. In\naddition, it also includes the entire authenticator slot list for the World ID account.\nRemoved authenticators are represented as `null` entries to preserve `pubkey_id` positions.","operationId":"handler","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerQueryRequest"}}},"required":true},"responses":{"200":{"description":"Merkle inclusion proof with authenticator public keys","content":{"application/json":{"schema":{"$ref":"#/components/schemas/AccountInclusionProofSchema"}}}}}}},"/packed-account":{"post":{"tags":["indexer"],"summary":"Get Packed Account Data","description":"Returns the packed account data for a given authenticator address from the `WorldIDRegistry` contract.","operationId":"handler","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerPackedAccountRequest"}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerPackedAccountResponse"}}}},"400":{"description":"Account does not exist for the given authenticator address","content":{"application/json":{"schema":{"$ref":"#/components/schemas/ServiceApiError"}}}}}}},"/pending-recovery-agent":{"post":{"tags":["indexer"],"summary":"Get the pending recovery agent update for a particular World ID given its leaf index.","description":"If no recovery agent update is pending, the zero address and zero execute-after timestamp are returned.","operationId":"handler","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerQueryRequest"}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerPendingRecoveryAgentResponse"}}}}}}},"/recovery-agent":{"post":{"tags":["indexer"],"summary":"Get the Recovery Agent for a particular World ID given its leaf index.","description":"If no recovery agent is set, the zero address is returned.","operationId":"handler","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerQueryRequest"}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerRecoveryAgentResponse"}}}}}}},"/signature-nonce":{"post":{"tags":["indexer"],"summary":"Get Signature Nonce","description":"Returns the current signature nonce for a given World ID based on its leaf index. The nonce is\nused to perform on-chain operations for the World ID.","operationId":"handler","requestBody":{"content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerQueryRequest"}}},"required":true},"responses":{"200":{"description":"","content":{"application/json":{"schema":{"$ref":"#/components/schemas/IndexerSignatureNonceResponse"}}}}}}}},"components":{"schemas":{"AccountInclusionProofSchema":{"type":"object","description":"OpenAPI schema representation of the `AccountInclusionProof` response.","required":["root","leaf_index","siblings","authenticator_pubkeys"],"properties":{"authenticator_pubkeys":{"type":"array","items":{"type":["string","null"],"format":"hex"},"description":"The compressed authenticator public keys for the account.\n\nEntries are optional to preserve sparse slot positions (`null` for removed authenticators)."},"leaf_index":{"type":"string","format":"hex","description":"The World ID's leaf position in the Merkle tree","example":"0x2a"},"root":{"type":"string","format":"hex","description":"The root hash of the Merkle tree (hex string)","example":"0x1a2b3c4d5e6f7890"},"siblings":{"type":"array","items":{"type":"string","format":"hex"},"description":"The sibling path up to the Merkle root (array of hex strings)"}}},"IndexerAuthenticatorPubkeysResponse":{"type":"object","description":"Response containing authenticator public keys for an account from the indexer.","required":["authenticator_pubkeys","offchain_signer_commitment"],"properties":{"authenticator_pubkeys":{"type":"array","items":{"type":["string","null"],"format":"hex"},"description":"The compressed authenticator public keys for the account.\n\nEntries may be `null` for removed authenticator slots to preserve `pubkey_id` positions."},"offchain_signer_commitment":{"type":"string","format":"hex","description":"The commitment to all the authenticator pubkeys. This commitment is\nstored in the `WorldIDRegistry`."}}},"IndexerPackedAccountRequest":{"type":"object","description":"Request to fetch a packed account index from the indexer.","required":["authenticator_address"],"properties":{"authenticator_address":{"type":"string","format":"hex","description":"The authenticator address to look up","example":"0x742d35Cc6634C0532925a3b844Bc9e7595f0bEb"}}},"IndexerPackedAccountResponse":{"type":"object","description":"Response containing the packed account index from the indexer.","required":["packed_account_data"],"properties":{"packed_account_data":{"type":"string","format":"hex","description":"The packed account data [32 bits recoveryCounter][32 bits pubkeyId][192 bits leafIndex].\n\nSerialized as a canonical `0x`-prefixed hex string.","example":"0x1"}}},"IndexerPendingRecoveryAgentResponse":{"type":"object","description":"Response containing the pending recovery agent from the indexer.","required":["pending_recovery_agent","execute_after"],"properties":{"execute_after":{"type":"string","format":"hex","description":"The earliest timestamp at which the pending recovery agent update may be executed.\n\nPlease note this may be zero if no recovery agent update is pending.\n\nSerialized as a canonical `0x`-prefixed hex string.","example":"0x0"},"pending_recovery_agent":{"type":"string","format":"hex","description":"The pending recovery agent for the World ID.\n\nPlease note this may be the zero address if no recovery agent update is pending.\n\nSerialized as a canonical `0x`-prefixed hex string.","example":"0x0"}}},"IndexerQueryRequest":{"type":"object","description":"Query for the indexer based on a leaf index.\n\nUsed for getting inclusion proofs and signature nonces.","required":["leaf_index"],"properties":{"leaf_index":{"type":"string","format":"hex","description":"The leaf index to query (from the `WorldIDRegistry`).\n\nAccepts decimal or `0x`/`0X`-prefixed hex input.","example":"0x1"}}},"IndexerRecoveryAgentResponse":{"type":"object","description":"Response containing the recovery agent from the indexer.","required":["recovery_agent"],"properties":{"recovery_agent":{"type":"string","format":"hex","description":"The recovery agent for the World ID.\n\nPlease note this may be the zero address if no recovery agent is set for the account.\n\nSerialized as a canonical `0x`-prefixed hex string.","example":"0x0"}}},"IndexerSignatureNonceResponse":{"type":"object","description":"Response containing the signature nonce from the indexer.","required":["signature_nonce"],"properties":{"signature_nonce":{"type":"string","format":"hex","description":"The signature nonce for the account.\n\nSerialized as a canonical `0x`-prefixed hex string.","example":"0x0"}}},"ServiceApiError":{"type":"object","description":"Error object returned by the services APIs (indexer, gateway).","required":["code","message"],"properties":{"code":{"$ref":"#/components/schemas/IndexerErrorCode","description":"The error code."},"message":{"type":"string","description":"Human-readable error message."}}}}},"tags":[{"name":"indexer","description":"World ID Indexer. Provides Merkle inclusion proofs and account information from the on-chain registry."}]}