List services with a broker
If you already have a funded broker, list services directly from the inference manager:Pagination
list_service() accepts pagination arguments:
offsetandlimitpage through large result setsinclude_unacknowledged=Falsehides services whose TEE signer hasn’t been acknowledged by anyone on-chain — useful if you only want production-ready providers
Get a specific service
ServiceNotFoundError if the provider address isn’t registered.
Service metadata
get_service_metadata() returns just the endpoint and model, with /v1/proxy automatically appended to the URL:
Browse without a wallet
You don’t need a private key to list services — usecreate_read_only_broker for wallet-less discovery. This is the right tool for UIs that want to show available providers before the user connects a wallet.
Include health metrics
list_service_with_detail augments each service with uptime and response-time data from the network’s monitoring API:
health_metrics is None for services the monitoring API hasn’t scored yet.
Read-only brokers also expose get_service(provider_address) which returns a ServiceWithDetail (includes the raw additional_info JSON).
The ServiceMetadata object
| Attribute | Type | Description |
|---|---|---|
provider | str | Provider wallet address — globally unique identifier |
service_type | str | chatbot, text-to-image, image-editing, speech-to-text |
url | str | Base URL (without /v1/proxy suffix) |
input_price | int | Wei per input unit (token / image / etc.) |
output_price | int | Wei per output unit |
updated_at | int | Unix timestamp of last metadata update |
model | str | Model identifier (e.g. qwen/qwen-2.5-7b-instruct) |
verifiability | str | TeeML for TEE-verified providers, empty string otherwise |
Filtering
Standard Python filtering covers most needs:Extractors — compute billing per service type
Different service types bill differently (per-token for chatbots, per-image for generation, etc.). Extractors know how to read input/output counts from request and response payloads for each type.Extractor types
| Service type | Class | Input source | Output source |
|---|---|---|---|
chatbot | ChatBotExtractor | usage.prompt_tokens | usage.completion_tokens |
text-to-image | TextToImageExtractor | request n (default 1) | always 0 |
image-editing | ImageEditingExtractor | request n (default 1) | always 0 |
speech-to-text | SpeechToTextExtractor | always 0 | usage.output_tokens |
Manual extractor construction
Bypassget_extractor to avoid the contract call:
EXTRACTOR_REGISTRY:
create_extractor raises ValueError on unknown service types.
End-to-end discovery example
API at a glance
InferenceManager (from a funded broker)
| Method | Returns |
|---|---|
list_service(offset=0, limit=20, include_unacknowledged=True) | list[ServiceMetadata] |
get_service(provider_address) | ServiceMetadata |
get_service_metadata(provider_address) | {'endpoint', 'model'} |
get_extractor(provider_address) | Extractor |
ReadOnlyInferenceBroker (no wallet)
| Method | Returns |
|---|---|
list_service(offset=0, limit=20, include_unacknowledged=True) | list[ServiceWithDetail] |
list_service_with_detail(...) | list[ServiceWithDetail] with health_metrics |
get_service(provider_address) | ServiceWithDetail |
create_extractor / EXTRACTOR_REGISTRY
Factory and registry for building extractors from a ServiceMetadata.
Next steps
Inference
Send requests to the provider you just discovered.
Account Management
Fund your ledger and allocate sub-account balances.