Repository navigation
feat(akash/console-api): document Console teams and projects - #43
Merged
Merged
Conversation
Console now has teams and projects. An API key acts in the personal account or team it was created in, with its creator's role, and can be limited to one project. The skill still said every key carries the full rights of the account and that a Console account is a single wallet, so an agent could deploy into the wrong project, misread a project_forbidden refusal, or tell a user to spend personal credits for a team. This adds rules/deploy/console-api/teams-and-projects.md (roles, the x-organization-id and x-project-id headers, keys bound to a team or a project, deploying into, listing by and moving between projects, project budgets, team billing, provider JWTs for project keys, session-only actions and the new error codes), corrects the account and key model across the Console API pages, SKILL.md and the method overview, and adds evals 26 to 32 for team and project cases.
…limits API keys now expire at most a year out and default to 365 days, so the note that an omitted expiresAt gives a key that never expires was wrong. The teams page also lacked the project_limit_reached and organization_limit_reached refusals and did not say that only owners and admins create projects.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Why
Part of CON-1264.
Console now has teams and projects. An API key acts in the personal account or team it was created in, with its creator's role, and can be limited to one project. The skill still says every key carries the full rights of the account and that a Console account is a single wallet, so an agent following it can deploy into the wrong project, misread a
project_forbiddenrefusal, or tell a user to spend personal credits for a team.Ships with the Console teams launch. It leans on akash-network/console#4413, which publishes the team and project routes in the API reference; merge that first.
What
rules/deploy/console-api/teams-and-projects.md: roles, how a request picks its team and project (x-organization-id,x-project-id), keys bound to a team or a project and theorganizationId/projectIdon each key, deploying into a project, listing by project and moving a deployment, project budgets, team billing (team wallet, cards, Auto recharge), provider JWTs for project keys, session-only actions, and the new codesorganization_forbidden,organization_mismatch,project_forbidden,project_required,project_budget_exceeded,project_limit_reached,organization_limit_reached,session_required; only owners and admins create projects, up to 10 per team counting the default oneauthentication.md: the "full rights of the account, no per-key scopes" rule is replaced by what a key can actually do; key fields, the new auth errors, andexpiresAtcapped at 1 year with a 365-day defaultaccount-and-funding.md: the "a Console account is a wallet" model now covers the personal account and teams, each with its own wallet; team billing and 402s on a team keydeployment-endpoints.md,overview.md,operations.md,api-key-quickstart.md,secrets.md:projectIdon create and list, the move and location endpoints,project_forbiddenon writes and JWTs, the 3600 s JWTttlcap in a team, error rows and the endpoint mapSKILL.md,rules/deploy/overview.md,rules/overview.md,provider-sdk.md, README: the same corrections where they said a key is the whole accountproject_forbidden, deploy into a named project, list and move by project, team 402 with personal credits, session-only team actions, provider JWT for a project key, a contractor key for one projectTesting
Every endpoint, field, role rule and error code was checked against the Console API source on
mainand the OpenAPI spec from #4413. Evals 26 to 32 each ran in a fresh Opus subagent, once against this branch and once againstmain: this branch passes 32 of 32 assertions,mainpasses 16 of 32. Two assertions were loosened after the first run because they failed correct answers (aPATCHsent through a helper function, andaccess: "full"named in a prose table), and eval 30 was tightened so it needs thesession_requiredreason.evals.jsonround-trips throughjson.dumps(indent=2)unchanged, and every relative link and@reference resolves.