Palbase ai · API
/ai/pools/{pool}/keysMint an enrolment key
A single-use key a machine of the project's enrols into the pool with (saved to a file on the machine: palbase-agent enroll --key-file <file> --capacity <n> — never on a command line), said once, here. A machine enrolled with it serves the project's sessions once whoever minted it is gone: never minted for an environment's token.
Called by your server, with the project's secret key.
Path
poolstring · requiredThe pool: its id, or its name.Request body
labelstring · optionalWhat it is for — the machine it enrols: 128 bytes of UTF-8 at most (maxLength counts characters, so a label of fewer may still be too long), with no control character, no format character (a bidi override or isolate, a zero-width space or joiner, a byte order mark) and no line or paragraph separator — a label is shown as it was written.curl -X POST "https://<your-ref>.palbase.studio/ai/pools/<pool>/keys" \
-H "apikey: $PALBASE_SECRET_KEY" \
-H "content-type: application/json" \
-d '{"label":"string"}'Responses
201The key, said once
400The request is malformed, or names what this module does not offer (the error names which)
401No valid credential
403A publishable key or a user's session: everything here is the project's server's, called with the secret key
404No such response, job or provider in this project
503The model service or the database did not answer; retry shortly
defaultAn error: the envelope names it (`error`) and explains it (`error_description`).
Operation CreatePoolKey of ai's contract.