UNPKG

@rockset/cli

Version:
1,344 lines (1,343 loc) 392 kB
{ "swagger": "2.0", "info": { "description": "Rockset's REST API allows for creating and managing all resources in Rockset. Each supported endpoint is documented below.\n\nAll requests must be authorized with a Rockset API key, which can be created in the [Rockset console](https://console.rockset.com). The API key must be provided as `ApiKey <api_key>` in the `Authorization` request header. For example:\n```\nAuthorization: ApiKey aB35kDjg93J5nsf4GjwMeErAVd832F7ad4vhsW1S02kfZiab42sTsfW5Sxt25asT\n```\n\nAll endpoints are only accessible via https.\n\nBuild something awesome!", "version": "v1", "title": "REST API" }, "host": "api.rs2.usw2.rockset.com", "tags": [ { "name": "API Keys" }, { "name": "Aliases" }, { "name": "Collections" }, { "name": "Custom Roles (beta)" }, { "name": "Documents" }, { "name": "Integrations" }, { "name": "Organizations" }, { "name": "Queries" }, { "name": "Query Lambdas" }, { "name": "Users" }, { "name": "Views" }, { "name": "Virtual Instances" }, { "name": "Workspaces" } ], "schemes": [ "https" ], "paths": { "/v1/orgs/self": { "get": { "tags": [ "Organizations" ], "summary": "Get Organization", "description": "Retrieve information about current organization.", "operationId": "getOrganization", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [], "responses": { "200": { "description": "organization retrieved successfully", "schema": { "$ref": "#/definitions/OrganizationResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/aliases": { "get": { "tags": [ "Aliases" ], "summary": "List Aliases", "description": "Retrieve all aliases in an organization", "operationId": "listAliases", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [], "responses": { "200": { "description": "aliases retrieved successfully", "schema": { "$ref": "#/definitions/ListAliasesResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/collections": { "get": { "tags": [ "Collections" ], "summary": "List Collections", "description": "Retrieve all collections in an organization.", "operationId": "listCollections", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [], "responses": { "200": { "description": "collections retrieved successfully", "schema": { "$ref": "#/definitions/ListCollectionsResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/integrations": { "get": { "tags": [ "Integrations" ], "summary": "List Integrations", "description": "List all integrations in an organization.", "operationId": "listIntegrations", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [], "responses": { "200": { "description": "integrations retrieved successfully", "schema": { "$ref": "#/definitions/ListIntegrationsResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } }, "post": { "tags": [ "Integrations" ], "summary": "Create Integration", "description": "Create a new integration.", "operationId": "createIntegration", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [ { "in": "body", "name": "body", "description": "integration credentials", "required": true, "schema": { "$ref": "#/definitions/CreateIntegrationRequest" } } ], "responses": { "200": { "description": "integration created successfully", "schema": { "$ref": "#/definitions/CreateIntegrationResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/integrations/{integration}": { "get": { "tags": [ "Integrations" ], "summary": "Retrieve Integration", "description": "Retrieve information about a single integration.", "operationId": "getIntegration", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [ { "name": "integration", "in": "path", "description": "name of the integration", "required": true, "type": "string" } ], "responses": { "200": { "description": "integration retrieved successfully", "schema": { "$ref": "#/definitions/GetIntegrationResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } }, "delete": { "tags": [ "Integrations" ], "summary": "Delete Integration", "description": "Remove an integration.", "operationId": "deleteIntegration", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [ { "name": "integration", "in": "path", "description": "name of the integration", "required": true, "type": "string" } ], "responses": { "200": { "description": "integration deleted successfully", "schema": { "$ref": "#/definitions/DeleteIntegrationResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/lambdas": { "get": { "tags": [ "Query Lambdas" ], "summary": "List Query Lambdas", "description": "List all Query Lambdas in an organization.", "operationId": "listAllQueryLambdas", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [], "responses": { "200": { "description": "Query Lambdas listed successfully", "schema": { "$ref": "#/definitions/ListQueryLambdasResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/queries": { "post": { "tags": [ "Queries" ], "summary": "Query", "description": "Make a SQL query to Rockset.", "operationId": "query", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [ { "in": "body", "name": "body", "description": "JSON object", "required": true, "schema": { "$ref": "#/definitions/QueryRequest" } } ], "responses": { "200": { "description": "query executed successfully", "schema": { "$ref": "#/definitions/QueryResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/queries/validations": { "post": { "tags": [ "Queries" ], "summary": "Validate Query", "description": "Validate a SQL query with Rockset's parser and planner.", "operationId": "validate", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [ { "in": "body", "name": "body", "description": "JSON object", "required": true, "schema": { "$ref": "#/definitions/QueryRequest" } } ], "responses": { "200": { "description": "query validated successfully", "schema": { "$ref": "#/definitions/ValidateQueryResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/roles": { "get": { "tags": [ "Custom Roles (beta)" ], "summary": "List Roles", "description": "List all roles for your organization.", "operationId": "listRoles", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [], "responses": { "200": { "description": "roles retrived successfully", "schema": { "$ref": "#/definitions/ListRolesResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } }, "post": { "tags": [ "Custom Roles (beta)" ], "summary": "Create a Role", "description": "Create a role for your organization.", "operationId": "createRole", "consumes": [ "application/json" ], "produces": [ "application/json" ], "parameters": [ { "in": "body", "name": "body", "description": "JSON Object", "required": true, "schema": { "$ref": "#/definitions/CreateRoleRequest" } } ], "responses": { "200": { "description": "role created successfully", "schema": { "$ref": "#/definitions/RoleResponse" } }, "400": { "description": "bad request", "schema": { "$ref": "#/definitions/ErrorModel" } }, "401": { "description": "unauthorized", "schema": { "$ref": "#/definitions/ErrorModel" } }, "403": { "description": "forbidden", "schema": { "$ref": "#/definitions/ErrorModel" } }, "404": { "description": "not found", "schema": { "$ref": "#/definitions/ErrorModel" } }, "405": { "description": "not allowed", "schema": { "$ref": "#/definitions/ErrorModel" } }, "406": { "description": "not acceptable", "schema": { "$ref": "#/definitions/ErrorModel" } }, "408": { "description": "request timeout", "schema": { "$ref": "#/definitions/ErrorModel" } }, "415": { "description": "not supported", "schema": { "$ref": "#/definitions/ErrorModel" } }, "429": { "description": "resource exceeded", "schema": { "$ref": "#/definitions/ErrorModel" } }, "500": { "description": "internal error", "schema": { "$ref": "#/definitions/ErrorModel" } }, "501": { "description": "not implemented", "schema": { "$ref": "#/definitions/ErrorModel" } }, "502": { "description": "bad gateway", "schema": { "$ref": "#/definitions/ErrorModel" } }, "503": { "description": "not ready", "schema": { "$ref": "#/definitions/ErrorModel" } } } } }, "/v1/orgs/self/roles/{roleName}": { "post": { "tags": [ "Custom Roles (beta)"