@meshery/schemas 1.1.0 → 1.1.2

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (35) hide show
  1. package/dist/cloudApi.d.mts +1474 -1471
  2. package/dist/cloudApi.d.ts +1474 -1471
  3. package/dist/cloudApi.js +1 -1
  4. package/dist/cloudApi.mjs +1 -1
  5. package/dist/constructs/v1beta1/credential/CredentialSchema.js +1 -1
  6. package/dist/constructs/v1beta1/credential/CredentialSchema.mjs +1 -1
  7. package/dist/constructs/v1beta1/role/RoleSchema.js +1 -1
  8. package/dist/constructs/v1beta1/role/RoleSchema.mjs +1 -1
  9. package/dist/constructs/v1beta1/schedule/ScheduleSchema.js +1 -1
  10. package/dist/constructs/v1beta1/schedule/ScheduleSchema.mjs +1 -1
  11. package/dist/constructs/v1beta1/token/TokenSchema.js +1 -1
  12. package/dist/constructs/v1beta1/token/TokenSchema.mjs +1 -1
  13. package/dist/constructs/v1beta2/credential/CredentialSchema.js +1 -1
  14. package/dist/constructs/v1beta2/credential/CredentialSchema.mjs +1 -1
  15. package/dist/constructs/v1beta2/role/RoleSchema.js +1 -1
  16. package/dist/constructs/v1beta2/role/RoleSchema.mjs +1 -1
  17. package/dist/constructs/v1beta2/schedule/ScheduleSchema.js +1 -1
  18. package/dist/constructs/v1beta2/schedule/ScheduleSchema.mjs +1 -1
  19. package/dist/constructs/v1beta2/token/TokenSchema.js +1 -1
  20. package/dist/constructs/v1beta2/token/TokenSchema.mjs +1 -1
  21. package/dist/constructs/v1beta3/component/ComponentSchema.js +1 -1
  22. package/dist/constructs/v1beta3/component/ComponentSchema.mjs +1 -1
  23. package/dist/constructs/v1beta3/connection/Connection.d.mts +42 -42
  24. package/dist/constructs/v1beta3/connection/Connection.d.ts +42 -42
  25. package/dist/constructs/v1beta3/connection/ConnectionSchema.js +1 -1
  26. package/dist/constructs/v1beta3/connection/ConnectionSchema.mjs +1 -1
  27. package/dist/constructs/v1beta3/token/TokenSchema.js +1 -1
  28. package/dist/constructs/v1beta3/token/TokenSchema.mjs +1 -1
  29. package/dist/constructs/v1beta3/workspace/Workspace.d.mts +18 -15
  30. package/dist/constructs/v1beta3/workspace/Workspace.d.ts +18 -15
  31. package/dist/constructs/v1beta3/workspace/WorkspaceSchema.js +3 -3
  32. package/dist/constructs/v1beta3/workspace/WorkspaceSchema.mjs +3 -3
  33. package/dist/mesheryApi.d.mts +584 -581
  34. package/dist/mesheryApi.d.ts +584 -581
  35. package/package.json +1 -1
@@ -1,2 +1,2 @@
1
- 'use strict';var e={openapi:"3.0.0",info:{title:"token",description:"Documentation for Meshery Cloud REST APIs for user tokens and sessions",contact:{name:"Meshery Maintainers",email:"maintainers@meshery.io",url:"https://meshery.io"},license:{name:"Apache 2.0",url:"https://www.apache.org/licenses/LICENSE-2.0.html"},version:"v1beta3"},servers:[{url:"https://cloud.layer5.io",description:"Meshery Cloud production server URL"},{url:"https://staging-cloud.layer5.io",description:"Meshery Cloud staging server URL"},{url:"http://localhost:9876",description:"Meshery Cloud development server URL"}],security:[{jwt:[]}],tags:[{name:"tokens",description:"Operations related to user tokens and sessions"}],paths:{"/api/identity/tokens":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get tokens",operationId:"getUserTokens",description:"Retrieves tokens associated with the authenticated user.",parameters:[{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}}],responses:{200:{description:"Tokens response",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},post:{"x-internal":["cloud"],tags:["tokens"],summary:"Generate token",operationId:"generateToken",description:"Generates a token for the authenticated user.",parameters:[{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}],responses:{201:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},delete:{"x-internal":["cloud"],tags:["tokens"],summary:"Delete token",operationId:"deleteUserToken",description:"Deletes a specific token for the authenticated user.",parameters:[{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token deleted",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/{tokenId}":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get token by ID",operationId:"getUserTokensById",description:"Retrieves a specific token by its ID.",parameters:[{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token response",content:{"application/json":{schema:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/infinite":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Issue indefinite lifetime token",operationId:"issueIndefiniteLifetimeToken",description:"Creates a non-expiring user token for provider admin use cases.",parameters:[{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}}],responses:{200:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}}},components:{securitySchemes:{jwt:{type:"http",scheme:"bearer",bearerFormat:"JWT"}},responses:{400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}},parameters:{tokenId:{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},tokenIdQuery:{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},userIdQuery:{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},providerQuery:{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}},page:{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},pagesize:{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},search:{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},order:{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}},isOauth:{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},name:{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},purpose:{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}},schemas:{UserToken:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},TokenPage:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},t=e;
1
+ 'use strict';var e={openapi:"3.0.0",info:{title:"token",description:"Documentation for Meshery Cloud REST APIs for user tokens and sessions",contact:{name:"Meshery Maintainers",email:"maintainers@meshery.io",url:"https://meshery.io"},license:{name:"Apache 2.0",url:"https://www.apache.org/licenses/LICENSE-2.0.html"},version:"v1beta3"},servers:[{url:"https://cloud.meshery.io",description:"Meshery Cloud production server URL"},{url:"https://staging-cloud.meshery.io",description:"Meshery Cloud staging server URL"},{url:"http://localhost:9876",description:"Meshery Cloud development server URL"}],security:[{jwt:[]}],tags:[{name:"tokens",description:"Operations related to user tokens and sessions"}],paths:{"/api/identity/tokens":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get tokens",operationId:"getUserTokens",description:"Retrieves tokens associated with the authenticated user.",parameters:[{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}}],responses:{200:{description:"Tokens response",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},post:{"x-internal":["cloud"],tags:["tokens"],summary:"Generate token",operationId:"generateToken",description:"Generates a token for the authenticated user.",parameters:[{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}],responses:{201:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},delete:{"x-internal":["cloud"],tags:["tokens"],summary:"Delete token",operationId:"deleteUserToken",description:"Deletes a specific token for the authenticated user.",parameters:[{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token deleted",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/{tokenId}":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get token by ID",operationId:"getUserTokensById",description:"Retrieves a specific token by its ID.",parameters:[{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token response",content:{"application/json":{schema:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/infinite":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Issue indefinite lifetime token",operationId:"issueIndefiniteLifetimeToken",description:"Creates a non-expiring user token for provider admin use cases.",parameters:[{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}}],responses:{200:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}}},components:{securitySchemes:{jwt:{type:"http",scheme:"bearer",bearerFormat:"JWT"}},responses:{400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}},parameters:{tokenId:{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},tokenIdQuery:{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},userIdQuery:{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},providerQuery:{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}},page:{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},pagesize:{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},search:{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},order:{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}},isOauth:{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},name:{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},purpose:{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}},schemas:{UserToken:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},TokenPage:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},t=e;
2
2
  module.exports=t;
@@ -1,2 +1,2 @@
1
- var e={openapi:"3.0.0",info:{title:"token",description:"Documentation for Meshery Cloud REST APIs for user tokens and sessions",contact:{name:"Meshery Maintainers",email:"maintainers@meshery.io",url:"https://meshery.io"},license:{name:"Apache 2.0",url:"https://www.apache.org/licenses/LICENSE-2.0.html"},version:"v1beta3"},servers:[{url:"https://cloud.layer5.io",description:"Meshery Cloud production server URL"},{url:"https://staging-cloud.layer5.io",description:"Meshery Cloud staging server URL"},{url:"http://localhost:9876",description:"Meshery Cloud development server URL"}],security:[{jwt:[]}],tags:[{name:"tokens",description:"Operations related to user tokens and sessions"}],paths:{"/api/identity/tokens":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get tokens",operationId:"getUserTokens",description:"Retrieves tokens associated with the authenticated user.",parameters:[{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}}],responses:{200:{description:"Tokens response",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},post:{"x-internal":["cloud"],tags:["tokens"],summary:"Generate token",operationId:"generateToken",description:"Generates a token for the authenticated user.",parameters:[{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}],responses:{201:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},delete:{"x-internal":["cloud"],tags:["tokens"],summary:"Delete token",operationId:"deleteUserToken",description:"Deletes a specific token for the authenticated user.",parameters:[{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token deleted",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/{tokenId}":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get token by ID",operationId:"getUserTokensById",description:"Retrieves a specific token by its ID.",parameters:[{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token response",content:{"application/json":{schema:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/infinite":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Issue indefinite lifetime token",operationId:"issueIndefiniteLifetimeToken",description:"Creates a non-expiring user token for provider admin use cases.",parameters:[{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}}],responses:{200:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}}},components:{securitySchemes:{jwt:{type:"http",scheme:"bearer",bearerFormat:"JWT"}},responses:{400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}},parameters:{tokenId:{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},tokenIdQuery:{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},userIdQuery:{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},providerQuery:{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}},page:{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},pagesize:{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},search:{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},order:{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}},isOauth:{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},name:{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},purpose:{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}},schemas:{UserToken:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},TokenPage:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},t=e;
1
+ var e={openapi:"3.0.0",info:{title:"token",description:"Documentation for Meshery Cloud REST APIs for user tokens and sessions",contact:{name:"Meshery Maintainers",email:"maintainers@meshery.io",url:"https://meshery.io"},license:{name:"Apache 2.0",url:"https://www.apache.org/licenses/LICENSE-2.0.html"},version:"v1beta3"},servers:[{url:"https://cloud.meshery.io",description:"Meshery Cloud production server URL"},{url:"https://staging-cloud.meshery.io",description:"Meshery Cloud staging server URL"},{url:"http://localhost:9876",description:"Meshery Cloud development server URL"}],security:[{jwt:[]}],tags:[{name:"tokens",description:"Operations related to user tokens and sessions"}],paths:{"/api/identity/tokens":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get tokens",operationId:"getUserTokens",description:"Retrieves tokens associated with the authenticated user.",parameters:[{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}}],responses:{200:{description:"Tokens response",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},post:{"x-internal":["cloud"],tags:["tokens"],summary:"Generate token",operationId:"generateToken",description:"Generates a token for the authenticated user.",parameters:[{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}],responses:{201:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}},delete:{"x-internal":["cloud"],tags:["tokens"],summary:"Delete token",operationId:"deleteUserToken",description:"Deletes a specific token for the authenticated user.",parameters:[{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token deleted",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/{tokenId}":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Get token by ID",operationId:"getUserTokensById",description:"Retrieves a specific token by its ID.",parameters:[{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}}],responses:{200:{description:"Token response",content:{"application/json":{schema:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}},"/api/identity/tokens/infinite":{get:{"x-internal":["cloud"],tags:["tokens"],summary:"Issue indefinite lifetime token",operationId:"issueIndefiniteLifetimeToken",description:"Creates a non-expiring user token for provider admin use cases.",parameters:[{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}}],responses:{200:{description:"Token generated",content:{"application/json":{schema:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}}}}},components:{securitySchemes:{jwt:{type:"http",scheme:"bearer",bearerFormat:"JWT"}},responses:{400:{description:"Invalid request body or request param",content:{"text/plain":{schema:{type:"string"}}}},401:{description:"Expired JWT token used or insufficient privilege",content:{"text/plain":{schema:{type:"string"}}}},404:{description:"Result not found",content:{"text/plain":{schema:{type:"string"}}}},500:{description:"Internal server error",content:{"text/plain":{schema:{type:"string"}}}}},parameters:{tokenId:{name:"tokenId",in:"path",description:"Token ID",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},tokenIdQuery:{name:"tokenId",in:"query",description:"ID of the token to delete.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},userIdQuery:{name:"userId",in:"query",description:"UUID of the user to issue the indefinite token for.",required:true,schema:{type:"string",format:"uuid",description:"A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}}},providerQuery:{name:"provider",in:"query",description:"Authentication provider to associate with the indefinite token.",required:true,schema:{type:"string",maxLength:500}},page:{name:"page",in:"query",description:"Get responses by page",schema:{type:"string"}},pagesize:{name:"pagesize",in:"query",description:"Get responses by pagesize",schema:{type:"string"}},search:{name:"search",in:"query",description:"Get responses that match search param value",schema:{type:"string"}},order:{name:"order",in:"query",description:"Get ordered responses",schema:{type:"string"}},isOauth:{name:"isOauth",in:"query",description:"Whether to retrieve OAuth-backed sessions instead of API tokens.",schema:{type:"boolean"}},name:{name:"name",in:"query",description:"Name of the token.",required:true,schema:{type:"string",minLength:1,maxLength:255}},purpose:{name:"purpose",in:"query",description:"Purpose for which the token is generated.",schema:{type:"string",maxLength:500}}},schemas:{UserToken:{type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},TokenPage:{type:"object",description:"A paginated list of tokens.",required:["tokens","totalCount","page","pageSize"],properties:{tokens:{type:"array",items:{"x-go-type":"UserToken",type:"object",additionalProperties:false,description:"Represents a user-owned API token or OAuth session.",required:["id","userId","provider"],properties:{id:{description:"Unique identifier for the token.","x-oapi-codegen-extra-tags":{db:"id",json:"id"},"x-order":1,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},userId:{description:"UUID of the user who owns the token.","x-go-name":"UserID","x-oapi-codegen-extra-tags":{db:"user_id",json:"userId"},"x-order":2,type:"string",format:"uuid","x-go-type":"uuid.UUID","x-go-type-import":{path:"github.com/gofrs/uuid"}},provider:{type:"string",description:"Authentication provider associated with the token.","x-oapi-codegen-extra-tags":{db:"provider",json:"provider"},maxLength:500,"x-order":3},accessToken:{type:"string",description:"Access token value.","x-oapi-codegen-extra-tags":{db:"access_token",json:"accessToken"},maxLength:4096,"x-order":4},refreshToken:{type:"string",description:"Refresh token value when applicable.","x-oapi-codegen-extra-tags":{db:"refresh_token",json:"refreshToken"},maxLength:4096,"x-order":5},name:{type:"string",description:"Human-readable token name.","x-oapi-codegen-extra-tags":{db:"name",json:"name"},minLength:1,maxLength:255,"x-order":6},purpose:{type:"string",description:"Purpose for which the token was created.","x-oapi-codegen-extra-tags":{db:"purpose",json:"purpose"},maxLength:500,"x-order":7},isOauth:{type:"boolean",description:"Whether this entry represents an OAuth session.","x-go-name":"IsOAuth","x-oapi-codegen-extra-tags":{db:"is_oauth",json:"isOauth"},"x-order":8},createdAt:{type:"string",format:"date-time",description:"Timestamp when the token was created.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"created_at",json:"createdAt"},"x-order":9},updatedAt:{type:"string",format:"date-time",description:"Timestamp when the token was last updated.","x-go-type":"time.Time","x-go-type-skip-optional-pointer":true,"x-oapi-codegen-extra-tags":{db:"updated_at",json:"updatedAt"},"x-order":10}}},"x-order":1,description:"Tokens returned on the current page."},totalCount:{type:"integer",description:"Total number of tokens across all pages.",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":2,"x-oapi-codegen-extra-tags":{json:"totalCount"}},page:{type:"integer",description:"Current page number (zero-based).",minimum:0,"x-go-type-skip-optional-pointer":true,"x-order":3},pageSize:{type:"integer",description:"Number of tokens per page.",minimum:1,"x-go-type-skip-optional-pointer":true,"x-order":4,"x-oapi-codegen-extra-tags":{json:"pageSize"}}}}}}},t=e;
2
2
  export{t as default};
@@ -754,7 +754,7 @@ interface components {
754
754
  environments?: {
755
755
  /**
756
756
  * Format: uuid
757
- * @description ID
757
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
758
758
  */
759
759
  id: string;
760
760
  /**
@@ -776,12 +776,12 @@ interface components {
776
776
  description: string;
777
777
  /**
778
778
  * Format: uuid
779
- * @description Environment organization ID
779
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
780
780
  */
781
781
  organization_id: string;
782
782
  /**
783
783
  * Format: uuid
784
- * @description Environment owner
784
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
785
785
  */
786
786
  owner?: string;
787
787
  /**
@@ -2779,9 +2779,12 @@ interface operations {
2779
2779
  200: {
2780
2780
  content: {
2781
2781
  "application/json": {
2782
+ /** @description Zero-based page index returned in this response. */
2782
2783
  page?: number;
2783
- page_size?: number;
2784
- total_count?: number;
2784
+ /** @description Maximum number of items returned on each page. */
2785
+ pageSize?: number;
2786
+ /** @description Total number of items across all pages. */
2787
+ totalCount?: number;
2785
2788
  /** @description Environments associated with this resource. */
2786
2789
  environments?: {
2787
2790
  /**
@@ -2791,7 +2794,7 @@ interface operations {
2791
2794
  id: string;
2792
2795
  /**
2793
2796
  * @description Specifies the version of the schema to which the environment conforms.
2794
- * @default environments.meshery.io/v1beta1
2797
+ * @default environments.meshery.io/v1beta3
2795
2798
  * @example [
2796
2799
  * "v1",
2797
2800
  * "v1alpha1",
@@ -2810,7 +2813,7 @@ interface operations {
2810
2813
  * Format: uuid
2811
2814
  * @description Environment organization ID
2812
2815
  */
2813
- organization_id: string;
2816
+ organizationId: string;
2814
2817
  /**
2815
2818
  * Format: uuid
2816
2819
  * @description Environment owner
@@ -2818,23 +2821,23 @@ interface operations {
2818
2821
  owner?: string;
2819
2822
  /**
2820
2823
  * Format: date-time
2821
- * @description Timestamp when the resource was created.
2824
+ * @description Timestamp when the environment was created.
2822
2825
  */
2823
- created_at?: string;
2826
+ createdAt?: string;
2824
2827
  /** @description Additional metadata associated with the environment. */
2825
2828
  metadata?: {
2826
2829
  [key: string]: unknown;
2827
2830
  };
2828
2831
  /**
2829
2832
  * Format: date-time
2830
- * @description Timestamp when the resource was updated.
2833
+ * @description Timestamp when the environment was last updated.
2831
2834
  */
2832
- updated_at?: string;
2835
+ updatedAt?: string;
2833
2836
  /**
2834
2837
  * Format: date-time
2835
2838
  * @description Timestamp when the environment was soft deleted. Null while the environment remains active.
2836
2839
  */
2837
- deleted_at?: string | null;
2840
+ deletedAt?: string | null;
2838
2841
  }[];
2839
2842
  };
2840
2843
  };
@@ -3242,7 +3245,7 @@ interface operations {
3242
3245
  environments?: {
3243
3246
  /**
3244
3247
  * Format: uuid
3245
- * @description ID
3248
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
3246
3249
  */
3247
3250
  id: string;
3248
3251
  /**
@@ -3264,12 +3267,12 @@ interface operations {
3264
3267
  description: string;
3265
3268
  /**
3266
3269
  * Format: uuid
3267
- * @description Environment organization ID
3270
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
3268
3271
  */
3269
3272
  organization_id: string;
3270
3273
  /**
3271
3274
  * Format: uuid
3272
- * @description Environment owner
3275
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
3273
3276
  */
3274
3277
  owner?: string;
3275
3278
  /**
@@ -754,7 +754,7 @@ interface components {
754
754
  environments?: {
755
755
  /**
756
756
  * Format: uuid
757
- * @description ID
757
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
758
758
  */
759
759
  id: string;
760
760
  /**
@@ -776,12 +776,12 @@ interface components {
776
776
  description: string;
777
777
  /**
778
778
  * Format: uuid
779
- * @description Environment organization ID
779
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
780
780
  */
781
781
  organization_id: string;
782
782
  /**
783
783
  * Format: uuid
784
- * @description Environment owner
784
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
785
785
  */
786
786
  owner?: string;
787
787
  /**
@@ -2779,9 +2779,12 @@ interface operations {
2779
2779
  200: {
2780
2780
  content: {
2781
2781
  "application/json": {
2782
+ /** @description Zero-based page index returned in this response. */
2782
2783
  page?: number;
2783
- page_size?: number;
2784
- total_count?: number;
2784
+ /** @description Maximum number of items returned on each page. */
2785
+ pageSize?: number;
2786
+ /** @description Total number of items across all pages. */
2787
+ totalCount?: number;
2785
2788
  /** @description Environments associated with this resource. */
2786
2789
  environments?: {
2787
2790
  /**
@@ -2791,7 +2794,7 @@ interface operations {
2791
2794
  id: string;
2792
2795
  /**
2793
2796
  * @description Specifies the version of the schema to which the environment conforms.
2794
- * @default environments.meshery.io/v1beta1
2797
+ * @default environments.meshery.io/v1beta3
2795
2798
  * @example [
2796
2799
  * "v1",
2797
2800
  * "v1alpha1",
@@ -2810,7 +2813,7 @@ interface operations {
2810
2813
  * Format: uuid
2811
2814
  * @description Environment organization ID
2812
2815
  */
2813
- organization_id: string;
2816
+ organizationId: string;
2814
2817
  /**
2815
2818
  * Format: uuid
2816
2819
  * @description Environment owner
@@ -2818,23 +2821,23 @@ interface operations {
2818
2821
  owner?: string;
2819
2822
  /**
2820
2823
  * Format: date-time
2821
- * @description Timestamp when the resource was created.
2824
+ * @description Timestamp when the environment was created.
2822
2825
  */
2823
- created_at?: string;
2826
+ createdAt?: string;
2824
2827
  /** @description Additional metadata associated with the environment. */
2825
2828
  metadata?: {
2826
2829
  [key: string]: unknown;
2827
2830
  };
2828
2831
  /**
2829
2832
  * Format: date-time
2830
- * @description Timestamp when the resource was updated.
2833
+ * @description Timestamp when the environment was last updated.
2831
2834
  */
2832
- updated_at?: string;
2835
+ updatedAt?: string;
2833
2836
  /**
2834
2837
  * Format: date-time
2835
2838
  * @description Timestamp when the environment was soft deleted. Null while the environment remains active.
2836
2839
  */
2837
- deleted_at?: string | null;
2840
+ deletedAt?: string | null;
2838
2841
  }[];
2839
2842
  };
2840
2843
  };
@@ -3242,7 +3245,7 @@ interface operations {
3242
3245
  environments?: {
3243
3246
  /**
3244
3247
  * Format: uuid
3245
- * @description ID
3248
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
3246
3249
  */
3247
3250
  id: string;
3248
3251
  /**
@@ -3264,12 +3267,12 @@ interface operations {
3264
3267
  description: string;
3265
3268
  /**
3266
3269
  * Format: uuid
3267
- * @description Environment organization ID
3270
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
3268
3271
  */
3269
3272
  organization_id: string;
3270
3273
  /**
3271
3274
  * Format: uuid
3272
- * @description Environment owner
3275
+ * @description A Universally Unique Identifier used to uniquely identify entities in Meshery. The UUID core definition is used across different schemas.
3273
3276
  */
3274
3277
  owner?: string;
3275
3278
  /**