ai.v1.AssistantService
CompleteAssistantKeys
CompleteAssistantKeys finishes a setup once SetAssistantKeys registered its public keys: the assistant starts using them, and drops the keys the registration replaced or left out. Completing a completed setup returns the keys again. Errors: - INVALID_ARGUMENT: malformed request. - NOT_FOUND: KEY_SETUP_NOT_FOUND. - FAILED_PRECONDITION: KEY_SETUP_NOT_REGISTERED; nothing changed. - UNAVAILABLE: SERVICE_UNAVAILABLE; retry the same request. - UNAUTHENTICATED: missing or invalid credentials.
Request
curl --request POST \ \
--url 'https://api.testnet.polyester.com/ai.v1.AssistantService/CompleteAssistantKeys' \
--header 'Content-Type: application/json' \
--header 'Connect-Protocol-Version: 1' \
--data '{
"setupId": "1"
}'Responses
{
"keys": [
{
"keyId": "ak_1a3c6de8153d5a5b04cd2a6529779542",
"publicKeyEd25519": "AA==",
"state": "ACTIVE",
"subaccountId": "6789012345678"
}
]
}ai.v1.CompleteAssistantKeysRequestai.v1.CompleteAssistantKeysResponseSetup from PrepareAssistantKeysResponse.
Subaccount the key acts on. Omitted for the main account. Public ID. ConnectRPC carries it as fixed64 (a decimal string in JSON).
Opaque identifier of the API key.
Ed25519 public key, 32 bytes.
ACTIVE or DISABLED.
| Key | HTTP status | Connect code | Error | When |
|---|---|---|---|---|
| unauthenticated | 401 | unauthenticated | Unauthenticated | Authentication required. |
| permission-denied | 403 | permission_denied | Permission Denied | Permission denied. |
| invalid-argument | 400 | invalid_argument | Invalid Argument | Invalid argument. |
| not-found | 404 | not_found | Not Found | Not found. |
| unavailable | 503 | unavailable | Unavailable | Service unavailable. |