# # Licensed to the Apache Software Foundation (ASF) under one # or more contributor license agreements. See the NOTICE file # distributed with this work for additional information # regarding copyright ownership. The ASF licenses this file # to you under the Apache License, Version 2.0 (the # "License"); you may not use this file except in compliance # with the License. You may obtain a copy of the License at # # http://www.apache.org/licenses/LICENSE-2.0 # # Unless required by applicable law or agreed to in writing, # software distributed under the License is distributed on an # "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY # KIND, either express or implied. See the License for the # specific language governing permissions and limitations # under the License. # openapi: 3.1.1 info: title: Apache Polaris and Apache Iceberg REST Catalog API license: name: Apache 2.0 url: https://www.apache.org/licenses/LICENSE-2.0.html version: 0.0.1 description: Defines the specification for the Polaris Catalog API, which encompasses both the Iceberg REST Catalog API and Polaris-native API. servers: - url: '{scheme}://{host}/{basePath}' description: Server URL when the port can be inferred from the scheme variables: scheme: description: The scheme of the URI, either http or https. default: https host: description: The host address for the specified server default: localhost basePath: description: Optional prefix to be appended to all routes default: '' - url: '{scheme}://{host}:{port}/{basePath}' description: Generic base server URL, with all parts configurable variables: scheme: description: The scheme of the URI, either http or https. default: https host: description: The host address for the specified server default: localhost port: description: The port used when addressing the host default: '443' basePath: description: Optional prefix to be appended to all routes default: '' security: - OAuth2: - catalog - BearerAuth: [] paths: /v1/config: get: tags: - Configuration API summary: List all catalog configuration settings operationId: getConfig parameters: - name: warehouse in: query required: false schema: type: string description: Warehouse location or identifier to request from the service description: |2- All REST clients should first call this route to get catalog configuration properties from the server to configure the catalog and its HTTP client. Configuration from the server consists of two sets of key/value pairs. - defaults - properties that should be used as default configuration; applied before client configuration - overrides - properties that should be used to override client configuration; applied after defaults and client configuration Catalog configuration is constructed by setting the defaults, then client- provided configuration, and finally overrides. The final property set is then used to configure the catalog. For example, a default configuration property might set the size of the client pool, which can be replaced with a client-specific setting. An override might be used to set the warehouse location, which is stored on the server rather than in client configuration. Common catalog configuration settings are documented at https://iceberg.apache.org/docs/latest/catalog-properties The catalog configuration also holds an optional `endpoints` field that contains information about the endpoints supported by the server. If a server does not send the `endpoints` field, a default set of endpoints is assumed: - GET /v1/{prefix}/namespaces - POST /v1/{prefix}/namespaces - GET /v1/{prefix}/namespaces/{namespace} - DELETE /v1/{prefix}/namespaces/{namespace} - POST /v1/{prefix}/namespaces/{namespace}/properties - GET /v1/{prefix}/namespaces/{namespace}/tables - POST /v1/{prefix}/namespaces/{namespace}/tables - GET /v1/{prefix}/namespaces/{namespace}/tables/{table} - POST /v1/{prefix}/namespaces/{namespace}/tables/{table} - DELETE /v1/{prefix}/namespaces/{namespace}/tables/{table} - POST /v1/{prefix}/namespaces/{namespace}/register - POST /v1/{prefix}/namespaces/{namespace}/tables/{table}/metrics - POST /v1/{prefix}/tables/rename - POST /v1/{prefix}/transactions/commit responses: '200': description: Server specified configuration values. content: application/json: schema: $ref: '#/components/schemas/CatalogConfig' example: overrides: warehouse: s3://bucket/warehouse/ defaults: clients: '4' idempotency-key-lifetime: PT30M endpoints: - GET /v1/{prefix}/namespaces/{namespace} - GET /v1/{prefix}/namespaces - POST /v1/{prefix}/namespaces - GET /v1/{prefix}/namespaces/{namespace}/tables/{table} - GET /v1/{prefix}/namespaces/{namespace}/views/{view} '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - Warehouse provided in the `warehouse` query parameter is not found. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NoSuchWarehouseExample: $ref: '#/components/examples/NoSuchWarehouseError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/oauth/tokens: post: tags: - OAuth2 API summary: Get a token using an OAuth2 flow (DEPRECATED for REMOVAL) deprecated: true operationId: getToken description: |- The `oauth/tokens` endpoint is **DEPRECATED for REMOVAL**. It is _not_ recommended to implement this endpoint, unless you are fully aware of the potential security implications. All clients are encouraged to explicitly set the configuration property `oauth2-server-uri` to the correct OAuth endpoint. Deprecated since Iceberg (Java) 1.6.0. The endpoint and related types will be removed from this spec in Iceberg (Java) 2.0. See [Security improvements in the Iceberg REST specification](https://github.com/apache/iceberg/issues/10537) Exchange credentials for a token using the OAuth2 client credentials flow or token exchange. This endpoint is used for three purposes - 1. To exchange client credentials (client ID and secret) for an access token This uses the client credentials flow. 2. To exchange a client token and an identity token for a more specific access token This uses the token exchange flow. 3. To exchange an access token for one with the same claims and a refreshed expiration period This uses the token exchange flow. For example, a catalog client may be configured with client credentials from the OAuth2 Authorization flow. This client would exchange its client ID and secret for an access token using the client credentials request with this endpoint (1). Subsequent requests would then use that access token. Some clients may also handle sessions that have additional user context. These clients would use the token exchange flow to exchange a user token (the "subject" token) from the session for a more specific access token for that user, using the catalog's access token as the "actor" token (2). The user ID token is the "subject" token and can be any token type allowed by the OAuth2 token exchange flow, including a unsecured JWT token with a sub claim. This request should use the catalog's bearer token in the "Authorization" header. Clients may also use the token exchange flow to refresh a token that is about to expire by sending a token exchange request (3). The request's "subject" token should be the expiring token. This request should use the subject token in the "Authorization" header. parameters: - name: Authorization in: header schema: type: string required: false requestBody: required: true content: application/x-www-form-urlencoded: schema: $ref: '#/components/schemas/OAuthTokenRequest' responses: '200': $ref: '#/components/responses/OAuthTokenResponse' '400': $ref: '#/components/responses/OAuthErrorResponse' '401': $ref: '#/components/responses/OAuthErrorResponse' 5XX: $ref: '#/components/responses/OAuthErrorResponse' security: - BearerAuth: [] /v1/{prefix}/namespaces: parameters: - $ref: '#/components/parameters/prefix' get: tags: - Catalog API summary: List namespaces, optionally providing a parent namespace to list underneath description: List all namespaces at a certain level, optionally starting from a given parent namespace. If table accounting.tax.paid.info exists, using 'SELECT NAMESPACE IN accounting' would translate into `GET /namespaces?parent=accounting` and must return a namespace, ["accounting", "tax"] only. Using 'SELECT NAMESPACE IN accounting.tax' would translate into `GET /namespaces?parent=accounting%1Ftax` and must return a namespace, ["accounting", "tax", "paid"]. If `parent` is not provided, all top-level namespaces should be listed. operationId: listNamespaces parameters: - $ref: '#/components/parameters/page-token' - $ref: '#/components/parameters/page-size' - name: parent in: query description: An optional namespace, underneath which to list namespaces. If not provided, all top-level namespaces should be listed. For backward compatibility, empty string is treated as absent for now. If parent is a multipart namespace, the parts must be separated by the namespace separator as indicated via the /config override `namespace-separator`, which defaults to the unit separator `0x1F` byte (url encoded `%1F`). To be compatible with older clients, servers must use both the advertised separator and `0x1F` as valid separators when decoding namespaces. The `namespace-separator` should be provided in a url encoded form. required: false schema: type: string example: accounting%1Ftax responses: '200': $ref: '#/components/responses/ListNamespacesResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - Namespace provided in the `parent` query parameter is not found. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NoSuchNamespaceExample: $ref: '#/components/examples/NoSuchNamespaceError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' post: tags: - Catalog API summary: Create a namespace parameters: - $ref: '#/components/parameters/idempotency-key' description: Create a namespace, with an optional set of properties. The server might also add properties, such as `last_modified_time` etc. operationId: createNamespace requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateNamespaceRequest' responses: '200': $ref: '#/components/responses/CreateNamespaceResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '406': $ref: '#/components/responses/UnsupportedOperationResponse' '409': description: Conflict - The namespace already exists content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceAlreadyExists: $ref: '#/components/examples/NamespaceAlreadyExistsError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' get: tags: - Catalog API summary: Load the metadata properties for a namespace operationId: loadNamespaceMetadata description: Return all stored metadata properties for a given namespace responses: '200': $ref: '#/components/responses/GetNamespaceResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - Namespace not found content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NoSuchNamespaceExample: $ref: '#/components/examples/NoSuchNamespaceError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' head: tags: - Catalog API summary: Check if a namespace exists operationId: namespaceExists description: Check if a namespace exists. The response does not contain a body. responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - Namespace not found content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NoSuchNamespaceExample: $ref: '#/components/examples/NoSuchNamespaceError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' delete: tags: - Catalog API summary: Drop a namespace from the catalog. Namespace must be empty. operationId: dropNamespace parameters: - $ref: '#/components/parameters/idempotency-key' responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - Namespace to delete does not exist. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NoSuchNamespaceExample: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Not Empty - Namespace to delete is not empty. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotEmptyExample: $ref: '#/components/examples/NamespaceNotEmptyError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/properties: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' post: tags: - Catalog API summary: Set or remove properties on a namespace operationId: updateProperties parameters: - $ref: '#/components/parameters/idempotency-key' description: |- Set and/or remove properties on a namespace. The request body specifies a list of properties to remove and a map of key value pairs to update. Properties that are not in the request are not modified or removed by this call. Server implementations are not required to support namespace properties. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateNamespacePropertiesRequest' examples: UpdateAndRemoveProperties: $ref: '#/components/examples/UpdateAndRemoveNamespacePropertiesRequest' responses: '200': $ref: '#/components/responses/UpdateNamespacePropertiesResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - Namespace not found content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '406': $ref: '#/components/responses/UnsupportedOperationResponse' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '422': description: Unprocessable Entity - A property key was included in both `removals` and `updates` content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: UnprocessableEntityDuplicateKey: $ref: '#/components/examples/UnprocessableEntityDuplicateKey' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/tables: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' get: tags: - Catalog API summary: List all table identifiers underneath a given namespace description: Return all table identifiers under this namespace operationId: listTables parameters: - $ref: '#/components/parameters/page-token' - $ref: '#/components/parameters/page-size' responses: '200': $ref: '#/components/responses/ListTablesResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' post: tags: - Catalog API summary: Create a table in the given namespace description: |- Create a table or start a create transaction, like atomic CTAS. If `stage-create` is false, the table is created immediately. If `stage-create` is true, the table is not created, but table metadata is initialized and returned. The service should prepare as needed for a commit to the table commit endpoint to complete the create transaction. The client uses the returned metadata to begin a transaction. To commit the transaction, the client sends all create and subsequent changes to the table commit route. Changes from the table create operation include changes like AddSchemaUpdate and SetCurrentSchemaUpdate that set the initial table state. operationId: createTable parameters: - $ref: '#/components/parameters/data-access' - $ref: '#/components/parameters/idempotency-key' requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateTableRequest' responses: '200': $ref: '#/components/responses/CreateTableResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Conflict - The identifier already exists as a table or view content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableAlreadyExists: $ref: '#/components/examples/TableAlreadyExistsError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/register: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' post: tags: - Catalog API summary: Register a table in the given namespace using given metadata file location parameters: - $ref: '#/components/parameters/data-access' - $ref: '#/components/parameters/idempotency-key' description: Register a table using given metadata file location. operationId: registerTable requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/RegisterTableRequest' responses: '200': $ref: '#/components/responses/LoadTableResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Conflict - The identifier already exists as a table or view content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableAlreadyExists: $ref: '#/components/examples/TableAlreadyExistsError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/tables/{table}: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/table' get: tags: - Catalog API summary: Load a table from the catalog operationId: loadTable description: |- Load a table from the catalog. The response contains both configuration and table metadata. The configuration, if non-empty is used as additional configuration for the table that overrides catalog configuration. For example, this configuration may change the FileIO implementation to be used for the table. The response also contains the table's full metadata, matching the table metadata JSON file. The catalog configuration may contain credentials that should be used for subsequent requests for the table. The configuration key "token" is used to pass an access token to be used as a bearer token for table requests. Otherwise, a token may be passed using a RFC 8693 token type as a configuration key. For example, "urn:ietf:params:oauth:token-type:jwt=". The response may include a read-restrictions field. A reader that supports read restrictions must fail any read against the loaded table that cannot apply a returned restriction in full. This includes unrecognized action or expression types, and actions whose definition cannot be loaded, parsed, or evaluated. These restrictions apply to every read performed using this response (including subsequent planTableScan and fetchScanTasks calls), but subsequent requests or requests made from a different authentication scope may have different restrictions. The response should not be cached outside of the authenticated scope. parameters: - $ref: '#/components/parameters/data-access' - name: If-None-Match in: header description: An optional header that allows the server to return 304 (Not Modified) if the metadata is current. The content is the value of the ETag received in a CreateTableResponse, LoadTableResponse or CommitTableResponse. required: false schema: type: string - in: query name: snapshots description: |- The snapshots to return in the body of the metadata via the `snapshots` field. Setting the value to `all` would return the full set of snapshots currently valid for the table. Setting the value to `refs` would load all snapshots referenced by branches or tags. Default if no param is provided is `all`. required: false schema: type: string enum: - all - refs - $ref: '#/components/parameters/referenced-by' responses: '200': $ref: '#/components/responses/LoadTableResponse' '304': description: Not Modified - Based on the content of the 'If-None-Match' header the table metadata has not changed since. '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, table to load does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToLoadDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' post: tags: - Catalog API summary: Commit updates to a table operationId: updateTable parameters: - $ref: '#/components/parameters/idempotency-key' description: |- Commit updates to a table. Commits have two parts, requirements and updates. Requirements are assertions that will be validated before attempting to make and commit changes. For example, `assert-ref-snapshot-id` will check that a named ref's snapshot ID has a certain value. Server implementations are required to fail with a 400 status code if any unknown updates or requirements are received. Updates are changes to make to table metadata. For example, after asserting that the current main ref is at the expected snapshot, a commit may add a new child snapshot and set the ref to the new snapshot id. Create table transactions that are started by createTable with `stage-create` set to true are committed using this route. Transactions should include all changes to the table, including table initialization, like AddSchemaUpdate and SetCurrentSchemaUpdate. The `assert-create` requirement is used to ensure that the table was not created concurrently. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CommitTableRequest' responses: '200': $ref: '#/components/responses/CommitTableResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, table to load does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToUpdateDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '409': description: Conflict - CommitFailedException, one or more requirements failed. The client may retry. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '500': description: An unknown server-side problem occurred; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Internal Server Error type: CommitStateUnknownException code: 500 '502': description: A gateway or proxy received an invalid response from the upstream server; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Invalid response from the upstream server type: CommitStateUnknownException code: 502 '503': $ref: '#/components/responses/ServiceUnavailableResponse' '504': description: A server-side gateway timeout occurred; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Gateway timed out during commit type: CommitStateUnknownException code: 504 5XX: description: A server-side problem that might not be addressable on the client. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Bad Gateway type: InternalServerError code: 502 delete: tags: - Catalog API summary: Drop a table from the catalog operationId: dropTable description: Remove a table from the catalog parameters: - $ref: '#/components/parameters/idempotency-key' - name: purgeRequested in: query required: false description: Whether the user requested to purge the underlying table's data and metadata schema: type: boolean default: false responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, Table to drop does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToDeleteDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' head: tags: - Catalog API summary: Check if a table exists operationId: tableExists description: Check if a table exists within a given namespace. The response does not contain a body. responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, Table not found content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToLoadDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/tables/{table}/credentials: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/table' get: tags: - Catalog API summary: Load vended credentials for a table from the catalog operationId: loadCredentials parameters: - name: planId in: query required: false schema: type: string description: The plan ID that has been used for server-side scan planning - $ref: '#/components/parameters/referenced-by' description: Load vended credentials for a table from the catalog. responses: '200': $ref: '#/components/responses/LoadCredentialsResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, table to load credentials for does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToLoadDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/tables/{table}/sign: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/table' post: tags: - Catalog API summary: Remotely signs requests to object storage operationId: signRequest requestBody: description: The request to be signed content: application/json: schema: $ref: '#/components/schemas/RemoteSignRequest' required: true responses: '200': $ref: '#/components/responses/RemoteSignResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/tables/rename: parameters: - $ref: '#/components/parameters/prefix' post: tags: - Catalog API summary: Rename a table from its current name to a new name parameters: - $ref: '#/components/parameters/idempotency-key' description: Rename a table from one identifier to another. It's valid to move a table across namespaces, but the server implementation is not required to support it. operationId: renameTable requestBody: description: Current table identifier to rename and new table identifier to rename to content: application/json: schema: $ref: '#/components/schemas/RenameTableRequest' examples: RenameTableSameNamespace: $ref: '#/components/examples/RenameTableSameNamespace' required: true responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, Table to rename does not exist - NoSuchNamespaceException, The target namespace of the new table identifier does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToRenameDoesNotExist: $ref: '#/components/examples/NoSuchTableError' NamespaceToRenameToDoesNotExist: $ref: '#/components/examples/NoSuchNamespaceError' '406': $ref: '#/components/responses/UnsupportedOperationResponse' '409': description: Conflict - The target identifier to rename to already exists as a table or view content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: summary: The requested table identifier already exists value: error: message: The requested table identifier already exists type: AlreadyExistsException code: 409 '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/tables/{table}/metrics: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/table' post: tags: - Catalog API summary: Send a metrics report to this endpoint to be processed by the backend operationId: reportMetrics requestBody: description: The request containing the metrics report to be sent content: application/json: schema: $ref: '#/components/schemas/ReportMetricsRequest' required: true responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, table to load does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToLoadDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/transactions/commit: parameters: - $ref: '#/components/parameters/prefix' post: tags: - Catalog API summary: Commit updates to multiple tables in an atomic operation operationId: commitTransaction parameters: - $ref: '#/components/parameters/idempotency-key' requestBody: description: |- Commit updates to multiple tables in an atomic operation A commit for a single table consists of a table identifier with requirements and updates. Requirements are assertions that will be validated before attempting to make and commit changes. For example, `assert-ref-snapshot-id` will check that a named ref's snapshot ID has a certain value. Server implementations are required to fail with a 400 status code if any unknown updates or requirements are received. Updates are changes to make to table metadata. For example, after asserting that the current main ref is at the expected snapshot, a commit may add a new child snapshot and set the ref to the new snapshot id. content: application/json: schema: $ref: '#/components/schemas/CommitTransactionRequest' required: true responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, table to load does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToUpdateDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '409': description: Conflict - CommitFailedException, one or more requirements failed. The client may retry. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '500': description: An unknown server-side problem occurred; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Internal Server Error type: CommitStateUnknownException code: 500 '502': description: A gateway or proxy received an invalid response from the upstream server; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Invalid response from the upstream server type: CommitStateUnknownException code: 502 '503': $ref: '#/components/responses/ServiceUnavailableResponse' '504': description: A server-side gateway timeout occurred; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Gateway timed out during commit type: CommitStateUnknownException code: 504 5XX: description: A server-side problem that might not be addressable on the client. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Bad Gateway type: InternalServerError code: 502 /v1/{prefix}/namespaces/{namespace}/views: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' get: tags: - Catalog API summary: List all view identifiers underneath a given namespace description: Return all view identifiers under this namespace operationId: listViews parameters: - $ref: '#/components/parameters/page-token' - $ref: '#/components/parameters/page-size' responses: '200': $ref: '#/components/responses/ListTablesResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/ErrorModel' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' post: tags: - Catalog API summary: Create a view in the given namespace description: Create a view in the given namespace. operationId: createView requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateViewRequest' responses: '200': $ref: '#/components/responses/LoadViewResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/ErrorModel' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Conflict - The identifier already exists as a table or view content: application/json: schema: $ref: '#/components/schemas/ErrorModel' examples: ViewAlreadyExists: $ref: '#/components/examples/ViewAlreadyExistsError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/register-view: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' post: tags: - Catalog API summary: Register a view in the catalog parameters: - $ref: '#/components/parameters/idempotency-key' description: Register a view in the given namespace using given metadata file location. operationId: registerView requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/RegisterViewRequest' responses: '200': $ref: '#/components/responses/LoadViewResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Conflict - The identifier already exists as a table or view content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: ViewAlreadyExists: $ref: '#/components/examples/ViewAlreadyExistsError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/views/{view}: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/view' get: tags: - Catalog API summary: Load a view from the catalog operationId: loadView description: |- Load a view from the catalog. The response contains both configuration and view metadata. The configuration, if non-empty is used as additional configuration for the view that overrides catalog configuration. The response also contains the view's full metadata, matching the view metadata JSON file. The catalog configuration may contain credentials that should be used for subsequent requests for the view. The configuration key "token" is used to pass an access token to be used as a bearer token for view requests. Otherwise, a token may be passed using a RFC 8693 token type as a configuration key. For example, "urn:ietf:params:oauth:token-type:jwt=". parameters: - $ref: '#/components/parameters/referenced-by' responses: '200': $ref: '#/components/responses/LoadViewResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchViewException, view to load does not exist content: application/json: schema: $ref: '#/components/schemas/ErrorModel' examples: ViewToLoadDoesNotExist: $ref: '#/components/examples/NoSuchViewError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' post: tags: - Catalog API summary: Replace a view operationId: replaceView parameters: - $ref: '#/components/parameters/idempotency-key' description: Commit updates to a view. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CommitViewRequest' responses: '200': $ref: '#/components/responses/LoadViewResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchViewException, view to load does not exist content: application/json: schema: $ref: '#/components/schemas/ErrorModel' examples: ViewToUpdateDoesNotExist: $ref: '#/components/examples/NoSuchViewError' '409': description: Conflict - CommitFailedException. The client may retry. content: application/json: schema: $ref: '#/components/schemas/ErrorModel' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '500': description: An unknown server-side problem occurred; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/ErrorModel' example: error: message: Internal Server Error type: CommitStateUnknownException code: 500 '502': description: A gateway or proxy received an invalid response from the upstream server; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/ErrorModel' example: error: message: Invalid response from the upstream server type: CommitStateUnknownException code: 502 '503': $ref: '#/components/responses/ServiceUnavailableResponse' '504': description: A server-side gateway timeout occurred; the commit state is unknown. content: application/json: schema: $ref: '#/components/schemas/ErrorModel' example: error: message: Gateway timed out during commit type: CommitStateUnknownException code: 504 5XX: description: A server-side problem that might not be addressable on the client. content: application/json: schema: $ref: '#/components/schemas/ErrorModel' example: error: message: Bad Gateway type: InternalServerError code: 502 delete: tags: - Catalog API summary: Drop a view from the catalog operationId: dropView description: Remove a view from the catalog parameters: - $ref: '#/components/parameters/idempotency-key' responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchViewException, view to drop does not exist content: application/json: schema: $ref: '#/components/schemas/ErrorModel' examples: ViewToDeleteDoesNotExist: $ref: '#/components/examples/NoSuchViewError' '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' head: tags: - Catalog API summary: Check if a view exists operationId: viewExists description: Check if a view exists within a given namespace. This request does not return a response body. responses: '204': description: Success, no content '400': description: Bad Request '401': description: Unauthorized '404': description: Not Found '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/views/rename: parameters: - $ref: '#/components/parameters/prefix' post: tags: - Catalog API summary: Rename a view from its current name to a new name description: Rename a view from one identifier to another. It's valid to move a view across namespaces, but the server implementation is not required to support it. operationId: renameView parameters: - $ref: '#/components/parameters/idempotency-key' requestBody: description: Current view identifier to rename and new view identifier to rename to content: application/json: schema: $ref: '#/components/schemas/RenameTableRequest' examples: RenameViewSameNamespace: $ref: '#/components/examples/RenameViewSameNamespace' required: true responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchViewException, view to rename does not exist - NoSuchNamespaceException, The target namespace of the new identifier does not exist content: application/json: schema: $ref: '#/components/schemas/ErrorModel' examples: ViewToRenameDoesNotExist: $ref: '#/components/examples/NoSuchViewError' NamespaceToRenameToDoesNotExist: $ref: '#/components/examples/NoSuchNamespaceError' '406': $ref: '#/components/responses/UnsupportedOperationResponse' '409': description: Conflict - The target identifier to rename to already exists as a table or view content: application/json: schema: $ref: '#/components/schemas/ErrorModel' example: summary: The requested view identifier already exists value: error: message: The requested view identifier already exists type: AlreadyExistsException code: 409 '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /v1/{prefix}/namespaces/{namespace}/tables/{table}/notifications: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/table' post: tags: - Catalog API summary: Sends a notification to the table operationId: sendNotification requestBody: description: |- The request containing the notification to be sent. For each table, Polaris will reject any notification where the timestamp in the request body is older than or equal to the most recent time Polaris has already processed for the table. The responsibility of ensuring the correct order of timestamps for a sequence of notifications lies with the caller of the API. This includes managing potential clock skew or inconsistencies when notifications are sent from multiple sources. A VALIDATE request behaves like a dry-run of a CREATE or UPDATE request up to but not including loading the contents of a metadata file; this includes validations of permissions, the specified metadata path being within ALLOWED_LOCATIONS, having an EXTERNAL catalog, etc. The intended use case for a VALIDATE notification is to allow a remote catalog to pre-validate the general settings of a receiving catalog against an intended new table location before possibly creating a table intended for sending notifications in the remote catalog at all. For a VALIDATE request, the specified metadata-location can either be a prospective full metadata file path, or a relevant parent directory of the intended table to validate against ALLOWED_LOCATIONS. content: application/json: schema: $ref: '#/components/schemas/NotificationRequest' required: true responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, table to load does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToLoadDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '409': description: Conflict - The timestamp of the received notification is older than or equal to the most recent timestamp Polaris has already processed for the specified table. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: summary: The timestamp of the received notification is older than or equal to the most recent timestamp Polaris has already processed for the specified table. value: error: message: A notification with a newer timestamp has been admitted for table type: AlreadyExistsException code: 409 '419': $ref: '#/components/responses/AuthenticationTimeoutResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/namespaces/{namespace}/generic-tables: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' get: tags: - Generic Table API summary: List all generic tables identifiers underneath a given namespace description: Return all generic table identifiers under this namespace operationId: listGenericTables parameters: - $ref: '#/components/parameters/page-token' - $ref: '#/components/parameters/page-size' responses: '200': $ref: '#/components/responses/ListGenericTablesResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' post: tags: - Generic Table API summary: Create a generic table under the given namespace description: Create a generic table under the given namespace, and return the created table information as a response. operationId: createGenericTable parameters: - $ref: '#/components/parameters/polaris-generic-table-data-access' requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateGenericTableRequest' responses: '200': $ref: '#/components/responses/CreateGenericTableResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Conflict - The table already exists under the given namespace content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableAlreadyExists: $ref: '#/components/examples/TableAlreadyExistsError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/namespaces/{namespace}/generic-tables/{generic-table}: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/generic-table' get: tags: - Generic Table API summary: Load a generic table under the given namespace from the catalog operationId: loadGenericTable description: |- Load a generic table from the catalog under the given namespace. The response contains all table information passed during create. parameters: - $ref: '#/components/parameters/polaris-generic-table-data-access' responses: '200': $ref: '#/components/responses/LoadGenericTableResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableError, generic table to load does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToLoadDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' delete: tags: - Generic Table API summary: Drop a generic table under the given namespace from the catalog operationId: dropGenericTable description: Remove a table under the given namespace from the catalog responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableError, Generic table to drop does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TableToDeleteDoesNotExist: $ref: '#/components/examples/NoSuchTableError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/namespaces/{namespace}/policies: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' post: tags: - Policy API summary: Create a policy in the given namespace operationId: createPolicy description: | Creates a policy within the specified namespace. A policy defines a set of rules governing actions on specified resources under predefined conditions. In Apache Polaris, policies are created, stored, and later referenced by external engines to enforce access controls on associated resources. User provides the following inputs when creating a policy - `name` (REQUIRED): The name of the policy. - `type` (REQUIRED): The type of the policy. - **Predefined Policies:** policies have a `system.*` prefix in their type, such as `system.data-compaction` - `description` (OPTIONAL): Provides details about the policy's purpose and functionality - `content` (OPTIONAL): Defines the rules that control actions and access conditions on resources. The format can be JSON, SQL, or any other format. The content field in the request body is validated using the policy's corresponding validator. The policy is created only if the content passes validation. Upon successful creation, the new policy's version will be 0. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreatePolicyRequest' responses: '200': $ref: '#/components/responses/CreatePolicyResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Conflict - The policy already exists under the given namespace content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyAlreadyExists: $ref: '#/components/examples/PolicyAlreadyExistsError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' get: tags: - Policy API summary: List all policy identifiers underneath a given namespace description: Return all policy identifiers under this namespace. Users can optionally filter the result by policy type operationId: listPolicies parameters: - $ref: '#/components/parameters/page-token' - $ref: '#/components/parameters/page-size' - $ref: '#/components/parameters/policy-type' responses: '200': $ref: '#/components/responses/ListPoliciesResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/namespaces/{namespace}/policies/{policy-name}: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/policy-name' get: tags: - Policy API summary: Load a policy operationId: loadPolicy description: | Load a policy from the catalog The response contains the policy's metadata and content. For more details, refer to the definition of the `Policy` model. responses: '200': $ref: '#/components/responses/LoadPolicyResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchPolicyException, policy to get does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyToGetDoesNotExist: $ref: '#/components/examples/NoSuchPolicyError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' put: tags: - Policy API summary: Update a policy operationId: updatePolicy description: | Update a policy A policy's description and content can be updated. The new content is validated against the policy's corresponding validator. Upon a successful update, the policy's version is incremented by 1. The update will only succeed if the current version matches the one in the catalog. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdatePolicyRequest' responses: '200': $ref: '#/components/responses/UpdatePolicyResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchPolicyException, policy to get does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyToUpdateDoesNotExist: $ref: '#/components/examples/NoSuchPolicyError' '409': description: The policy version doesn't match the current-policy-version, or the policy was concurrently modified; retry after fetching latest version content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyVersionMismatch: $ref: '#/components/examples/PolicyVersionMismatchError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' delete: tags: - Policy API summary: Drop a policy from the catalog operationId: dropPolicy description: | Remove a policy from the catalog. A policy can only be dropped if it is not attached to any resource entity. To remove the policy along with all its attachments, set detach-all to true. parameters: - name: detach-all in: query required: false description: | When set to true, the dropPolicy operation will also delete all mappings between the policy and its attached target entities. schema: type: boolean example: false responses: '204': description: Success, no content '400': description: Bad Request - the policy to be dropped is attached to one or more targets and detach-all is not set to true content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyInUse: $ref: '#/components/examples/PolicyInUseError' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchPolicyException, policy to get does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyToDeleteDoesNotExist: $ref: '#/components/examples/NoSuchPolicyError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/namespaces/{namespace}/policies/{policy-name}/mappings: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/policy-name' put: tags: - Policy API summary: Create a mapping between a policy and a resource entity operationId: attachPolicy description: | Create a mapping between a policy and a resource entity Policy can be attached to different levels: 1. **Table-like level:** Policies specific to individual tables or views. 2. **Namespace level:** Policies applies to a namespace. 3. **Catalog level:** Policies that applies to a catalog The ability to attach a policy to a specific entity type is governed by the PolicyValidator. A policy can only be attached if the resource entity is a valid target for the specified policy type. In addition to the validation rules enforced by the PolicyValidator, there are additional constraints on policy attachment: 1. For inheritable policies, only one policy of the same type can be attached to a given resource entity. 2. For non-inheritable policies, multiple policies of the same type can be attached to the same resource entity without restriction. For inheritable policies, the inheritance override rule is: 1. Table-like level policies override namespace and catalog policies. 2. Namespace-level policies override upper level namespace or catalog policies. Additional parameters can be provided in `parameters` when creating a mapping to define specific behavior or constraints. If the policy is already attached to the target entity, the existing mapping record will be updated with the new set of parameters, replacing the previous ones. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/AttachPolicyRequest' responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchPolicyException, NoSuchTargetException content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyToSetDoesNotExist: $ref: '#/components/examples/NoSuchPolicyError' TargetToSetDoesNotExist: $ref: '#/components/examples/NoSuchTargetError' '409': description: Conflict - The policy type is inheritable and there is already a policy of the same type attached to the target entity content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: AnotherPolicyOfSameInheritableAttached: $ref: '#/components/examples/ConflictPolicyAttachmentError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' post: tags: - Policy API summary: Remove a mapping between a policy and a target entity operationId: detachPolicy description: | Remove a mapping between a policy and a target entity A target entity can be a catalog, namespace, table or view. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/DetachPolicyRequest' responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchPolicyException, NoSuchTargetException, NoSuchMappingException content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: PolicyToUnsetDoesNotExist: $ref: '#/components/examples/NoSuchPolicyError' TargetToUnsetDoesNotExist: $ref: '#/components/examples/NoSuchTargetError' MappingToUnsetDoesNotExist: $ref: '#/components/examples/NoSuchMappingError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/applicable-policies: parameters: - $ref: '#/components/parameters/prefix' get: tags: - Policy API summary: Get Applicable policies for catalog, namespace, table, or views operationId: getApplicablePolicies description: | Retrieves all applicable policies for a specified entity, including inherited policies from parent entities. An entity can be a table/view, namespace, or catalog. The required parameters depend on the entity type: - Table/View: - The `namespace` parameter is required to specify the entity's namespace. - The `target-name` parameter is required to specify the entity name. - Namespace: - The `namespace` parameter is required to specify the identifier. - The `target-name` parameter should not be set. - Catalog: - Neither `namespace` nor `target-name` should be set. An optional policyType parameter filters results to return only policies of the specified type. This API evaluates the entity's hierarchy and applies inheritable policies from parent entities. The inheritance follows the following override rule: 1. Table-like level policies override namespace and catalog policies. 2. Namespace-level policies override upper level namespace or catalog policies. parameters: - $ref: '#/components/parameters/page-token' - $ref: '#/components/parameters/page-size' - name: namespace in: query required: false description: A namespace identifier as a single string. Multipart namespace parts should be separated by the unit separator (`0x1F`) byte. schema: type: string examples: singlepart_namespace: value: accounting multipart_namespace: value: accounting%1Ftax - name: target-name in: query required: false description: Name of the target table/view schema: type: string example: test_table - $ref: '#/components/parameters/policy-type' responses: '200': $ref: '#/components/responses/GetApplicablePoliciesResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - NoSuchTableException, target table does not exist - NoSuchViewException, target view does not exist - NoSuchNamespaceException, target namespace does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: TargetTableDoesNotExist: $ref: '#/components/examples/NoSuchTableError' TargetViewDoesNotExist: $ref: '#/components/examples/NoSuchViewError' TargetNamespaceDoesNotExist: $ref: '#/components/examples/NoSuchNamespaceError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/namespaces/{namespace}/semantic-models: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' post: tags: - Semantic Model API summary: Create a semantic model in the given namespace operationId: createSemanticModel description: | **Beta:** The semantic-model (Apache Ossie) API is under active development and may change in a backward-incompatible way. Creates a semantic model in the specified namespace. A semantic model is an Apache Ossie document describing datasets, fields, relationships, metrics, and AI context for a logical analytics surface above physical tables and views. Upon successful creation, the response returns the model's initial entity-version. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/CreateSemanticModelRequest' responses: '200': $ref: '#/components/responses/CreateSemanticModelResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '409': description: Conflict - A semantic model with this name already exists in the namespace content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: SemanticModelAlreadyExists: $ref: '#/components/examples/SemanticModelAlreadyExistsError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' get: tags: - Semantic Model API summary: List semantic models in the given namespace operationId: listSemanticModels description: | **Beta:** The semantic-model (Apache Ossie) API is under active development and may change in a backward-incompatible way. List semantic-model identifiers under a namespace. parameters: - $ref: '#/components/parameters/page-token' - $ref: '#/components/parameters/page-size' responses: '200': $ref: '#/components/responses/ListSemanticModelsResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - The namespace specified does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: NamespaceNotFound: $ref: '#/components/examples/NoSuchNamespaceError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/namespaces/{namespace}/semantic-models/{semantic-model-name}: parameters: - $ref: '#/components/parameters/prefix' - $ref: '#/components/parameters/namespace' - $ref: '#/components/parameters/semantic-model-name' get: tags: - Semantic Model API summary: Load a semantic model operationId: loadSemanticModel description: | **Beta:** The semantic-model (Apache Ossie) API is under active development and may change in a backward-incompatible way. Load a semantic model from the catalog. responses: '200': $ref: '#/components/responses/LoadSemanticModelResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - the requested semantic model does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: SemanticModelToGetDoesNotExist: $ref: '#/components/examples/NoSuchSemanticModelError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' put: tags: - Semantic Model API summary: Update a semantic model operationId: updateSemanticModel description: | **Beta:** The semantic-model (Apache Ossie) API is under active development and may change in a backward-incompatible way. Replace a semantic model's document with a new one. Upon a successful update, the model's entity-version changes and the new value is returned. Updates use optimistic concurrency: supply the `entity-version` you last read for this model, and the update succeeds only if it matches the version currently stored in the catalog. A mismatch fails with 409. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/UpdateSemanticModelRequest' responses: '200': $ref: '#/components/responses/UpdateSemanticModelResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - the requested semantic model does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: SemanticModelToUpdateDoesNotExist: $ref: '#/components/examples/NoSuchSemanticModelError' '409': description: Conflict - the supplied entity-version does not match the stored version. The client may retry after fetching the latest version. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: SemanticModelVersionMismatch: $ref: '#/components/examples/SemanticModelVersionMismatchError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' delete: tags: - Semantic Model API summary: Drop a semantic model from the catalog operationId: dropSemanticModel description: | **Beta:** The semantic-model (Apache Ossie) API is under active development and may change in a backward-incompatible way. Remove a semantic model from the catalog. responses: '204': description: Success, no content '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: Not Found - the requested semantic model does not exist content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' examples: SemanticModelToDeleteDoesNotExist: $ref: '#/components/examples/NoSuchSemanticModelError' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/discovery/v1/catalogs: get: tags: - Catalog Discovery API summary: List the catalogs the caller can access operationId: listAccessibleCatalogs description: | **Beta:** The catalog discovery API is under active development and may change in a backward-incompatible way. Lists the catalogs the caller can access, so that a client can find out what to configure. Each entry's name is the value a client passes as `warehouse` to the configuration endpoint (`/v1/config`). The list is the batch form of the configuration endpoint: it includes exactly the catalogs for which the caller is authorized to call `getConfig`, and an entry never carries more than that endpoint returns for the same catalog. In this version an entry is the catalog's name only. Storage configuration and other administrative details are never included. Administrators use the management API's `listCatalogs` for the full model. parameters: - $ref: '#/components/parameters/pageToken' - $ref: '#/components/parameters/pageSize' responses: '200': $ref: '#/components/responses/ListAccessibleCatalogsResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' /polaris/v1/{prefix}/metrics: parameters: - $ref: '#/components/parameters/prefix' post: tags: - Metrics Reports API summary: Query metrics reports for one or more catalog objects operationId: queryTableMetrics description: | **Experimental / Beta:** The Metrics Reports API is experimental and may change in a backward-incompatible way in any future release. It should not be used in production environments. Returns persisted metrics for the catalog objects listed in the request body. All requested objects must belong to the catalog identified by `prefix`. Requires the TABLE_READ_METRICS privilege on each requested table. Reports are returned for the requested tables that exist and for which the caller holds that privilege. Other requested tables are omitted without error, so the response does not reveal whether they exist. A 403 is returned when none of the requested tables is readable by the caller, whether because they do not exist or because the caller lacks the privilege. This applies only to a request without a `page-token`: when none of the tables is readable on a later page, for example because they were dropped or the privilege was revoked during the listing, the server returns an empty `reports` list with no `next-page-token`. A 404 is returned only when the catalog itself does not exist. The response may be paginated: clients should always check `next-page-token` and, when present, pass it as `page-token` to fetch the next page. Neither `page-token` nor `page-size` is required on the first request. The server decides the actual page size, which may be smaller than the `page-size` hint. Clients cannot request that all results be returned in a single response. requestBody: required: true content: application/json: schema: $ref: '#/components/schemas/QueryMetricsRequest' responses: '200': description: Paginated list of metrics reports content: application/json: schema: $ref: '#/components/schemas/ListMetricsResponse' '400': $ref: '#/components/responses/BadRequestErrorResponse' '401': $ref: '#/components/responses/UnauthorizedResponse' '403': $ref: '#/components/responses/ForbiddenResponse' '404': description: | Not Found - The catalog does not exist. Requested tables that do not exist never produce a 404; they are omitted from the result, or produce a 403 as described above. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' '503': $ref: '#/components/responses/ServiceUnavailableResponse' 5XX: $ref: '#/components/responses/ServerErrorResponse' components: securitySchemes: OAuth2: type: oauth2 description: |- This scheme is used for OAuth2 authorization. For unauthorized requests, services should return an appropriate 401 or 403 response. Implementations must not return altered success (200) responses when a request is unauthenticated or unauthorized. If a separate authorization server is used, substitute the tokenUrl with the full token path of the external authorization server, and use the resulting token to access the resources defined in the spec. flows: clientCredentials: tokenUrl: /v1/oauth/tokens scopes: catalog: Allows interacting with the Config and Catalog APIs BearerAuth: type: http scheme: bearer schemas: CatalogConfig: type: object description: Server-provided configuration for the catalog. required: - defaults - overrides properties: overrides: type: object additionalProperties: type: string description: Properties that should be used to override client configuration; applied after defaults and client configuration. defaults: type: object additionalProperties: type: string description: Properties that should be used as default configuration; applied before client configuration. endpoints: type: array items: type: string description: A list of endpoints that the server supports. The format of each endpoint must be " ". The HTTP verb and the resource path must be separated by a space character. example: - GET /v1/{prefix}/namespaces/{namespace} - GET /v1/{prefix}/namespaces - POST /v1/{prefix}/namespaces - GET /v1/{prefix}/namespaces/{namespace}/tables/{table} - GET /v1/{prefix}/namespaces/{namespace}/views/{view} idempotency-key-lifetime: type: string format: duration description: Client reuse window for an Idempotency-Key (ISO-8601 duration, e.g., PT30M, PT24H). Interpreted as the maximum time from the first submission using a key to the last retry during which a client may reuse that key. Servers SHOULD accept retries for at least this duration and MAY include a grace period to account for delays/clock skew. Clients SHOULD NOT reuse an Idempotency-Key after this window elapses; they SHOULD generate a new key for any subsequent attempt. Presence of this field indicates the server supports Idempotency-Key semantics for mutation endpoints. If absent, clients MUST assume idempotency is not supported. example: PT30M ErrorModel: type: object description: JSON error payload returned in a response with further details on the error required: - message - type - code properties: message: type: string description: Human-readable error message type: type: string description: Internal type definition of the error example: NoSuchNamespaceException code: type: integer minimum: 400 maximum: 600 description: HTTP response code example: 404 stack: type: array items: type: string IcebergErrorResponse: description: JSON wrapper for all error responses (non-2xx) type: object required: - error properties: error: $ref: '#/components/schemas/ErrorModel' additionalProperties: false example: error: message: The server does not support this operation type: UnsupportedOperationException code: 406 OAuthClientCredentialsRequest: deprecated: true description: |- The `oauth/tokens` endpoint and related schemas are **DEPRECATED for REMOVAL** from this spec, see description of the endpoint. OAuth2 client credentials request See https://datatracker.ietf.org/doc/html/rfc6749#section-4.4 type: object required: - grant_type - client_id - client_secret properties: grant_type: type: string enum: - client_credentials scope: type: string client_id: type: string description: |- Client ID This can be sent in the request body, but OAuth2 recommends sending it in a Basic Authorization header. client_secret: type: string description: |- Client secret This can be sent in the request body, but OAuth2 recommends sending it in a Basic Authorization header. TokenType: type: string enum: - urn:ietf:params:oauth:token-type:access_token - urn:ietf:params:oauth:token-type:refresh_token - urn:ietf:params:oauth:token-type:id_token - urn:ietf:params:oauth:token-type:saml1 - urn:ietf:params:oauth:token-type:saml2 - urn:ietf:params:oauth:token-type:jwt description: |- Token type identifier, from RFC 8693 Section 3 See https://datatracker.ietf.org/doc/html/rfc8693#section-3 OAuthTokenExchangeRequest: deprecated: true description: |- The `oauth/tokens` endpoint and related schemas are **DEPRECATED for REMOVAL** from this spec, see description of the endpoint. OAuth2 token exchange request See https://datatracker.ietf.org/doc/html/rfc8693 type: object required: - grant_type - subject_token - subject_token_type properties: grant_type: type: string enum: - urn:ietf:params:oauth:grant-type:token-exchange scope: type: string requested_token_type: $ref: '#/components/schemas/TokenType' subject_token: type: string description: Subject token for token exchange request subject_token_type: $ref: '#/components/schemas/TokenType' actor_token: type: string description: Actor token for token exchange request actor_token_type: $ref: '#/components/schemas/TokenType' OAuthTokenRequest: deprecated: true description: The `oauth/tokens` endpoint and related schemas are **DEPRECATED for REMOVAL** from this spec, see description of the endpoint. anyOf: - $ref: '#/components/schemas/OAuthClientCredentialsRequest' - $ref: '#/components/schemas/OAuthTokenExchangeRequest' OAuthTokenResponse: deprecated: true description: The `oauth/tokens` endpoint and related schemas are **DEPRECATED for REMOVAL** from this spec, see description of the endpoint. type: object required: - access_token - token_type properties: access_token: type: string description: The access token, for client credentials or token exchange token_type: type: string enum: - bearer - mac - N_A description: |- Access token type for client credentials or token exchange See https://datatracker.ietf.org/doc/html/rfc6749#section-7.1 expires_in: type: integer description: Lifetime of the access token in seconds for client credentials or token exchange issued_token_type: $ref: '#/components/schemas/TokenType' refresh_token: type: string description: Refresh token for client credentials or token exchange scope: type: string description: Authorization scope for client credentials or token exchange OAuthError: deprecated: true description: The `oauth/tokens` endpoint and related schemas are **DEPRECATED for REMOVAL** from this spec, see description of the endpoint. type: object required: - error properties: error: type: string enum: - invalid_request - invalid_client - invalid_grant - unauthorized_client - unsupported_grant_type - invalid_scope error_description: type: string error_uri: type: string PageToken: description: |- An opaque token that allows clients to make use of pagination for list APIs (e.g. ListTables). Clients may initiate the first paginated request by sending an empty query parameter `pageToken` to the server. Servers that support pagination should identify the `pageToken` parameter and return a `next-page-token` in the response if there are more results available. After the initial request, the value of `next-page-token` from each response must be used as the `pageToken` parameter value for the next request. The server must return `null` value for the `next-page-token` in the last response. Servers that support pagination must return all results in a single response with the value of `next-page-token` set to `null` if the query parameter `pageToken` is not set in the request. Servers that do not support pagination should ignore the `pageToken` parameter and return all results in a single response. The `next-page-token` must be omitted from the response. Clients must interpret either `null` or missing response value of `next-page-token` as the end of the listing results. type: - string - 'null' Namespace: description: Reference to one or more levels of a namespace type: array items: type: string example: - accounting - tax ListNamespacesResponse: type: object properties: next-page-token: $ref: '#/components/schemas/PageToken' namespaces: type: array uniqueItems: true items: $ref: '#/components/schemas/Namespace' CreateNamespaceRequest: type: object required: - namespace properties: namespace: $ref: '#/components/schemas/Namespace' properties: type: object description: Configured string to string map of properties for the namespace example: owner: Hank Bendickson default: {} additionalProperties: type: string CreateNamespaceResponse: type: object required: - namespace properties: namespace: $ref: '#/components/schemas/Namespace' properties: type: object additionalProperties: type: string description: Properties stored on the namespace, if supported by the server. example: owner: Ralph created_at: '1452120468' default: {} GetNamespaceResponse: type: object required: - namespace properties: namespace: $ref: '#/components/schemas/Namespace' properties: type: - object - 'null' description: Properties stored on the namespace, if supported by the server. If the server does not support namespace properties, it should return null for this field. If namespace properties are supported, but none are set, it should return an empty object. additionalProperties: type: string example: owner: Ralph transient_lastDdlTime: '1452120468' default: {} UpdateNamespacePropertiesRequest: type: object properties: removals: type: array uniqueItems: true items: type: string example: - department - access_group updates: type: object example: owner: Hank Bendickson additionalProperties: type: string UpdateNamespacePropertiesResponse: type: object required: - updated - removed properties: updated: description: List of property keys that were added or updated type: array uniqueItems: true items: type: string removed: description: List of properties that were removed type: array items: type: string missing: type: - array - 'null' items: type: string description: List of properties requested for removal that were not found in the namespace's properties. Represents a partial success response. Server's do not need to implement this. TableIdentifier: type: object required: - namespace - name properties: namespace: $ref: '#/components/schemas/Namespace' name: type: string ListTablesResponse: type: object properties: next-page-token: $ref: '#/components/schemas/PageToken' identifiers: type: array uniqueItems: true items: $ref: '#/components/schemas/TableIdentifier' VariantType: type: string const: variant PrimitiveType: type: string example: - long - string - fixed[16] - decimal(10,2) StructType: type: object required: - type - fields properties: type: type: string const: struct fields: type: array items: $ref: '#/components/schemas/StructField' Type: oneOf: - $ref: '#/components/schemas/VariantType' - $ref: '#/components/schemas/PrimitiveType' - $ref: '#/components/schemas/StructType' - $ref: '#/components/schemas/ListType' - $ref: '#/components/schemas/MapType' ListType: type: object required: - type - element-id - element - element-required properties: type: type: string const: list element-id: type: integer element: $ref: '#/components/schemas/Type' element-required: type: boolean MapType: type: object required: - type - key-id - key - value-id - value - value-required properties: type: type: string const: map key-id: type: integer key: $ref: '#/components/schemas/Type' value-id: type: integer value: $ref: '#/components/schemas/Type' value-required: type: boolean BooleanTypeValue: type: boolean example: true IntegerTypeValue: type: integer example: 42 LongTypeValue: type: integer format: int64 example: 9223372036854776000 FloatTypeValue: type: number format: float example: 3.14 DoubleTypeValue: type: number format: double example: 123.456 DecimalTypeValue: type: string description: Decimal type values are serialized as strings. Decimals with a positive scale serialize as numeric plain text, while decimals with a negative scale use scientific notation and the exponent will be equal to the negated scale. For instance, a decimal with a positive scale is '123.4500', with zero scale is '2', and with a negative scale is '2E+20' example: '123.4500' StringTypeValue: type: string example: hello UUIDTypeValue: type: string format: uuid pattern: ^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$ maxLength: 36 minLength: 36 description: UUID type values are serialized as a 36-character lowercase string in standard UUID format as specified by RFC-4122 example: eb26bdb1-a1d8-4aa6-990e-da940875492c DateTypeValue: type: string format: date description: Date type values follow the 'YYYY-MM-DD' ISO-8601 standard date format example: '2007-12-03' TimeTypeValue: type: string description: Time type values follow the 'HH:MM:SS.ssssss' ISO-8601 format with microsecond precision example: '22:31:08.123456' TimestampTypeValue: type: string description: Timestamp type values follow the 'YYYY-MM-DDTHH:MM:SS.ssssss' ISO-8601 format with microsecond precision example: '2007-12-03T10:15:30.123456' TimestampTzTypeValue: type: string description: TimestampTz type values follow the 'YYYY-MM-DDTHH:MM:SS.ssssss+00:00' ISO-8601 format with microsecond precision, and a timezone offset (+00:00 for UTC) example: '2007-12-03T10:15:30.123456+00:00' TimestampNanoTypeValue: type: string description: Timestamp_ns type values follow the 'YYYY-MM-DDTHH:MM:SS.sssssssss' ISO-8601 format with nanosecond precision example: '2007-12-03T10:15:30.123456789' TimestampTzNanoTypeValue: type: string description: Timestamp_ns type values follow the 'YYYY-MM-DDTHH:MM:SS.sssssssss+00:00' ISO-8601 format with nanosecond precision, and a timezone offset (+00:00 for UTC) example: '2007-12-03T10:15:30.123456789+00:00' FixedTypeValue: type: string description: Fixed length type values are stored and serialized as an uppercase hexadecimal string preserving the fixed length example: 78797A BinaryTypeValue: type: string description: Binary type values are stored and serialized as an uppercase hexadecimal string example: 78797A PrimitiveTypeValue: oneOf: - $ref: '#/components/schemas/BooleanTypeValue' - $ref: '#/components/schemas/IntegerTypeValue' - $ref: '#/components/schemas/LongTypeValue' - $ref: '#/components/schemas/FloatTypeValue' - $ref: '#/components/schemas/DoubleTypeValue' - $ref: '#/components/schemas/DecimalTypeValue' - $ref: '#/components/schemas/StringTypeValue' - $ref: '#/components/schemas/UUIDTypeValue' - $ref: '#/components/schemas/DateTypeValue' - $ref: '#/components/schemas/TimeTypeValue' - $ref: '#/components/schemas/TimestampTypeValue' - $ref: '#/components/schemas/TimestampTzTypeValue' - $ref: '#/components/schemas/TimestampNanoTypeValue' - $ref: '#/components/schemas/TimestampTzNanoTypeValue' - $ref: '#/components/schemas/FixedTypeValue' - $ref: '#/components/schemas/BinaryTypeValue' StructField: type: object required: - id - name - type - required properties: id: type: integer name: type: string type: $ref: '#/components/schemas/Type' required: type: boolean doc: type: string initial-default: $ref: '#/components/schemas/PrimitiveTypeValue' write-default: $ref: '#/components/schemas/PrimitiveTypeValue' Schema: allOf: - $ref: '#/components/schemas/StructType' - type: object properties: schema-id: type: integer readOnly: true identifier-field-ids: type: array items: type: integer Transform: type: string example: - identity - year - month - day - hour - bucket[256] - truncate[16] PartitionField: type: object required: - source-id - transform - name properties: field-id: type: integer source-id: type: integer name: type: string transform: $ref: '#/components/schemas/Transform' PartitionSpec: type: object required: - fields properties: spec-id: type: integer readOnly: true fields: type: array items: $ref: '#/components/schemas/PartitionField' SortDirection: type: string enum: - asc - desc NullOrder: type: string enum: - nulls-first - nulls-last SortField: type: object required: - source-id - transform - direction - null-order properties: source-id: type: integer transform: $ref: '#/components/schemas/Transform' direction: $ref: '#/components/schemas/SortDirection' null-order: $ref: '#/components/schemas/NullOrder' SortOrder: type: object required: - order-id - fields properties: order-id: type: integer readOnly: true fields: type: array items: $ref: '#/components/schemas/SortField' CreateTableRequest: type: object required: - name - schema properties: name: type: string location: type: string schema: $ref: '#/components/schemas/Schema' partition-spec: $ref: '#/components/schemas/PartitionSpec' write-order: $ref: '#/components/schemas/SortOrder' stage-create: type: boolean properties: type: object additionalProperties: type: string EncryptedKey: type: object required: - key-id - encrypted-key-metadata properties: key-id: type: string encrypted-key-metadata: type: string format: byte contentEncoding: base64 encrypted-by-id: type: string properties: type: object additionalProperties: type: string Snapshot: type: object required: - snapshot-id - timestamp-ms - manifest-list - summary properties: snapshot-id: type: integer format: int64 parent-snapshot-id: type: integer format: int64 sequence-number: type: integer format: int64 timestamp-ms: type: integer format: int64 manifest-list: type: string description: Location of the snapshot's manifest list file first-row-id: type: integer format: int64 description: The first _row_id assigned to the first row in the first data file in the first manifest added-rows: type: integer format: int64 description: The upper bound of the number of rows with assigned row IDs summary: type: object required: - operation properties: operation: type: string enum: - append - replace - overwrite - delete additionalProperties: type: string schema-id: type: integer SnapshotReference: type: object required: - type - snapshot-id properties: type: type: string enum: - tag - branch snapshot-id: type: integer format: int64 max-ref-age-ms: type: integer format: int64 max-snapshot-age-ms: type: integer format: int64 min-snapshots-to-keep: type: integer SnapshotReferences: type: object additionalProperties: $ref: '#/components/schemas/SnapshotReference' SnapshotLog: type: array items: type: object required: - snapshot-id - timestamp-ms properties: snapshot-id: type: integer format: int64 timestamp-ms: type: integer format: int64 MetadataLog: type: array items: type: object required: - metadata-file - timestamp-ms properties: metadata-file: type: string timestamp-ms: type: integer format: int64 BlobMetadata: type: object required: - type - snapshot-id - sequence-number - fields properties: type: type: string snapshot-id: type: integer format: int64 sequence-number: type: integer format: int64 fields: type: array items: type: integer properties: type: object additionalProperties: type: string StatisticsFile: type: object required: - snapshot-id - statistics-path - file-size-in-bytes - file-footer-size-in-bytes - blob-metadata properties: snapshot-id: type: integer format: int64 statistics-path: type: string file-size-in-bytes: type: integer format: int64 file-footer-size-in-bytes: type: integer format: int64 blob-metadata: type: array items: $ref: '#/components/schemas/BlobMetadata' PartitionStatisticsFile: type: object required: - snapshot-id - statistics-path - file-size-in-bytes properties: snapshot-id: type: integer format: int64 statistics-path: type: string file-size-in-bytes: type: integer format: int64 TableMetadata: type: object required: - format-version - table-uuid properties: format-version: type: integer minimum: 1 maximum: 3 table-uuid: type: string location: type: string last-updated-ms: type: integer format: int64 next-row-id: type: integer format: int64 description: A long higher than all assigned row IDs; the next snapshot's first-row-id. properties: type: object additionalProperties: type: string schemas: type: array items: $ref: '#/components/schemas/Schema' current-schema-id: type: integer last-column-id: type: integer partition-specs: type: array items: $ref: '#/components/schemas/PartitionSpec' default-spec-id: type: integer last-partition-id: type: integer sort-orders: type: array items: $ref: '#/components/schemas/SortOrder' default-sort-order-id: type: integer encryption-keys: type: array items: $ref: '#/components/schemas/EncryptedKey' snapshots: type: array items: $ref: '#/components/schemas/Snapshot' refs: $ref: '#/components/schemas/SnapshotReferences' current-snapshot-id: type: integer format: int64 last-sequence-number: type: integer format: int64 snapshot-log: $ref: '#/components/schemas/SnapshotLog' metadata-log: $ref: '#/components/schemas/MetadataLog' statistics: type: array items: $ref: '#/components/schemas/StatisticsFile' partition-statistics: type: array items: $ref: '#/components/schemas/PartitionStatisticsFile' StorageCredential: type: object required: - prefix - config properties: prefix: type: string description: Indicates a storage location prefix where the credential is relevant. Clients should choose the most specific prefix (by selecting the longest prefix) if several credentials of the same type are available. config: type: object additionalProperties: type: string MultiValuedMap: description: A map of string keys where each key can map to multiple string values. type: object additionalProperties: type: array items: type: string RemoteSigningConfig: description: Configuration for the remote signer client. type: object properties: properties: type: object additionalProperties: type: string description: | Static key-value pairs the signer client MUST pass through unchanged in the `properties` field of every `RemoteSignRequest` sent to the signing endpoint. headers: allOf: - $ref: '#/components/schemas/MultiValuedMap' description: | Static headers the signer client MUST include unchanged in every request to the signing endpoint. Action: discriminator: propertyName: action mapping: mask-alphanum: '#/components/schemas/MaskAlphanum' mask-to-fixed-value: '#/components/schemas/MaskToFixedValue' replace-with-null: '#/components/schemas/ReplaceWithNull' show-first-4: '#/components/schemas/ShowFirst4' show-last-4: '#/components/schemas/ShowLast4' truncate-to-year: '#/components/schemas/TruncateToYear' truncate-to-month: '#/components/schemas/TruncateToMonth' sha-256-global: '#/components/schemas/Sha256Global' sha-256-query-local: '#/components/schemas/Sha256QueryLocal' type: object required: - action - field-id properties: action: type: string field-id: type: integer description: Field ID of the column being projected. MaskAlphanum: description: | Redacts the column value using the following rules to transform Unicode code points: - Digits (U+0030–U+0039, 0-9) are replaced with 'n' - The following punctuation characters are kept as-is: U+0028 '(' LEFT PARENTHESIS U+0029 ')' RIGHT PARENTHESIS U+002C ',' COMMA U+002E '.' FULL STOP U+002D '-' HYPHEN-MINUS U+0040 '@' COMMERCIAL AT - All other Unicode characters (including letters, whitespace, and any punctuation not listed above) are replaced with 'x' For example: "iceberg16112018@apache.org" -> "xxxxxxxnnnnnnnn@xxxxxx.xxx" NULL input is preserved (NULL -> NULL). Applicable to: string allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: mask-alphanum MaskToFixedValue: description: | Replaces the column value with a type-specific fixed value. Readers must use exactly the values listed below to ensure consistency across implementations. Fixed values by type: - boolean: false - int: 0 - long: 0 - float: 0.0 - double: 0.0 - decimal(p, s): 0 (the unscaled value is 0) - string: "XXXXXXXX" - date: 1970-01-01 - time: 00:00:00 - timestamp: 1970-01-01T00:00:00 - timestamptz: 1970-01-01T00:00:00+00:00 - timestamp_ns: 1970-01-01T00:00:00.000000000 - timestamptz_ns: 1970-01-01T00:00:00.000000000+00:00 - uuid: 00000000-0000-0000-0000-000000000000 - fixed(n): n zero bytes - binary: empty byte sequence - variant: an empty variant object - list: empty list [] - map: empty map {} - struct: struct with each field set to its type-specific default (applied recursively) NULL input is also replaced with the type-specific fixed value; NULL is not preserved. Applicable to: the types with a fixed value defined above. A server must not return mask-to-fixed-value for any other type. allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: mask-to-fixed-value ReplaceWithNull: description: | Replaces the column value with NULL. NULL input is preserved (NULL -> NULL). Applicable to: all optional types. A server must not return replace-with-null for a required (non-nullable) field; a reader that receives one must fail the query. allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: replace-with-null ShowFirst4: description: | Preserves the first 4 Unicode code points of the column value and redacts the remainder using mask-alphanum rules (see MaskAlphanum for the exact character rules). Values with 4 or fewer Unicode code points are returned unchanged. For example: "iceberg16112018@apache.org" -> "icebxxxnnnnnnnn@xxxxxx.xxx" NULL input is preserved (NULL -> NULL). Applicable to: string allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: show-first-4 ShowLast4: description: | Redacts all Unicode code points except the last 4 using mask-alphanum rules (see MaskAlphanum for the exact character rules). Values with 4 or fewer Unicode code points are returned unchanged. For example: "4111-1111-1111-4444" -> "nnnn-nnnn-nnnn-4444" NULL input is preserved (NULL -> NULL). Applicable to: string allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: show-last-4 TruncateToYear: description: | Truncates the column value to year precision, setting month, day, and time components to their minimum values. The output type matches the input type. For example: 2024-07-15 -> 2024-01-01 For timestamptz and timestamptz_ns, truncation is performed in UTC. NULL input is preserved (NULL -> NULL). Applicable to: date, timestamp, timestamptz, timestamp_ns, timestamptz_ns allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: truncate-to-year TruncateToMonth: description: | Truncates the column value to year and month precision, setting day and time components to their minimum values. The output type matches the input type. For example: 2024-07-15 -> 2024-07-01 For timestamptz and timestamptz_ns, truncation is performed in UTC. NULL input is preserved (NULL -> NULL). Applicable to: date, timestamp, timestamptz, timestamp_ns, timestamptz_ns allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: truncate-to-month Sha256Global: description: | Applies SHA-256. Deterministic across all queries and readers: the same input always produces the same output. Input-to-bytes encoding by type: - string: UTF-8 encoded bytes - int: 4 bytes, little-endian - long: 8 bytes, little-endian - binary: raw bytes as-is Output encoding by type: - string: 64-character lowercase hexadecimal string - int: first 4 bytes of the digest, read as a little-endian int - long: first 8 bytes of the digest, read as a little-endian long - binary: the full 32-byte raw SHA-256 digest NULL input is preserved (NULL -> NULL). Applicable to: string, int, long, binary allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: sha-256-global Sha256QueryLocal: description: | Applies SHA-256 with a per-query random salt, making the output non-deterministic across queries while remaining consistent within a single query. The definition of a query is left to the implementation. The reader must generate a cryptographically random salt of at least 16 bytes for each query. For each column value, the reader must encode the value to bytes using sha-256-global's input rules, prepend the per-query salt, and compute SHA-256 over the result. Output encoding follows the same rules as sha-256-global. NULL input is preserved (NULL -> NULL). Applicable to: string, int, long, binary allOf: - $ref: '#/components/schemas/Action' properties: action: type: string const: sha-256-query-local ExpressionType: type: string example: - 'true' - 'false' - eq - and - or - not - in - not-in - lt - lt-eq - gt - gt-eq - not-eq - starts-with - not-starts-with - is-null - not-null - is-nan - not-nan TrueExpression: deprecated: true description: | Deprecated. Use the bare boolean literal `true` as a predicate instead. type: object required: - type properties: type: $ref: '#/components/schemas/ExpressionType' const: 'true' FalseExpression: deprecated: true description: | Deprecated. Use the bare boolean literal `false` as a predicate instead. type: object required: - type properties: type: $ref: '#/components/schemas/ExpressionType' const: 'false' Predicate: oneOf: - type: boolean - $ref: '#/components/schemas/TrueExpression' - $ref: '#/components/schemas/FalseExpression' - $ref: '#/components/schemas/AndOrPredicate' - $ref: '#/components/schemas/NotPredicate' - $ref: '#/components/schemas/UnaryPredicate' - $ref: '#/components/schemas/ComparisonPredicate' - $ref: '#/components/schemas/SetPredicate' AndOrPredicate: type: object required: - type - left - right properties: type: $ref: '#/components/schemas/ExpressionType' enum: - and - or left: $ref: '#/components/schemas/Predicate' right: $ref: '#/components/schemas/Predicate' NotPredicate: type: object required: - type - child properties: type: $ref: '#/components/schemas/ExpressionType' const: not child: $ref: '#/components/schemas/Predicate' Literal: description: | A literal is either a bare value, an untyped literal object, or a typed literal object. oneOf: - $ref: '#/components/schemas/PrimitiveTypeValue' - type: object additionalProperties: false required: - type - value properties: type: type: string const: literal value: $ref: '#/components/schemas/PrimitiveTypeValue' data-type: $ref: '#/components/schemas/PrimitiveType' IdReference: description: A bound reference to a field by field ID. type: object additionalProperties: false required: - type - id properties: type: type: string const: reference id: type: integer NamedReference: description: An unbound reference to a field by name. type: object additionalProperties: false required: - type - name properties: type: type: string const: reference name: type: string Reference: description: | A reference to a field. Either a bound reference (by field ID) or an unbound reference (by name). The context in which an expression is used determines which form is valid. oneOf: - $ref: '#/components/schemas/IdReference' - $ref: '#/components/schemas/NamedReference' CatalogObjectIdentifier: description: Reference to a catalog object (for example, table, view, or namespace) as an ordered list of hierarchical levels. The object kind is determined by context (e.g. the endpoint or a companion type discriminator), not by the identifier structure alone. type: array items: type: string example: - accounting - tax - paid ValueExpression: description: | A value expression: a literal, a field reference, or a function application. oneOf: - $ref: '#/components/schemas/Literal' - $ref: '#/components/schemas/Reference' - $ref: '#/components/schemas/Apply' FunctionArgument: anyOf: - $ref: '#/components/schemas/ValueExpression' - $ref: '#/components/schemas/Predicate' Apply: description: | A function application on zero or more value expressions or predicates. type: object additionalProperties: false required: - type - function - arguments properties: type: type: string const: apply function: oneOf: - type: string minLength: 1 - $ref: '#/components/schemas/CatalogObjectIdentifier' - type: object additionalProperties: false required: - identifier properties: catalog: type: string identifier: $ref: '#/components/schemas/CatalogObjectIdentifier' arguments: type: array items: $ref: '#/components/schemas/FunctionArgument' TermReference: deprecated: true description: | Deprecated string-form field reference used in older REST predicates. Use Reference (IdReference or NamedReference) instead. type: string example: - column-name TransformTerm: deprecated: true description: | Deprecated. Legacy transform-applied-to-a-term form. Use Apply with a Reference argument instead. type: object required: - type - transform - term properties: type: type: string const: transform transform: $ref: '#/components/schemas/Transform' term: $ref: '#/components/schemas/TermReference' Term: deprecated: true description: | Deprecated. Legacy term form used by older REST predicates. Use Reference or Apply instead. oneOf: - $ref: '#/components/schemas/TermReference' - $ref: '#/components/schemas/TransformTerm' UnaryPredicate: description: | A predicate that tests a single value expression. Accepts either 'child' (preferred) or 'term' (deprecated) to identify the operand. type: object additionalProperties: false required: - type properties: type: $ref: '#/components/schemas/ExpressionType' enum: - is-null - not-null - is-nan - not-nan child: $ref: '#/components/schemas/ValueExpression' term: deprecated: true description: Deprecated. Use 'child' instead. $ref: '#/components/schemas/Term' ComparisonPredicate: description: | A predicate that compares two value expressions. Accepts either 'left'/'right' (preferred) or 'term'/'value' (deprecated). type: object additionalProperties: false required: - type properties: type: $ref: '#/components/schemas/ExpressionType' enum: - lt - lt-eq - gt - gt-eq - eq - not-eq - starts-with - not-starts-with left: $ref: '#/components/schemas/ValueExpression' right: $ref: '#/components/schemas/ValueExpression' term: deprecated: true description: Deprecated. Use 'left' instead. $ref: '#/components/schemas/Term' value: deprecated: true description: Deprecated. Use 'right' instead. $ref: '#/components/schemas/Literal' Literals: description: | Literals is either a bare array of literals or a typed object with an explicit data-type applied to all values. oneOf: - type: array items: $ref: '#/components/schemas/Literal' - type: object additionalProperties: false required: - type - values - data-type properties: type: type: string const: literals values: type: array items: $ref: '#/components/schemas/PrimitiveTypeValue' data-type: $ref: '#/components/schemas/PrimitiveType' SetPredicate: description: | A predicate that tests whether a value is in a set of literals. Accepts either 'child' (preferred) or 'term' (deprecated) to identify the operand. type: object additionalProperties: false required: - type - values properties: type: $ref: '#/components/schemas/ExpressionType' enum: - in - not-in child: $ref: '#/components/schemas/ValueExpression' term: deprecated: true description: Deprecated. Use 'child' instead. $ref: '#/components/schemas/Term' values: $ref: '#/components/schemas/Literals' ReadRestrictions: type: object description: | Read restrictions for a table. A reader evaluates the row filter against original, untransformed column values, then applies required-column-projections to the surviving rows. Each action must produce a value of the same type as the input column. If a reader that supports read-restrictions cannot apply any returned restriction (a filter expression or an action), it must fail the query and must not silently return raw, partial, or empty results. A missing or empty ReadRestrictions object (no required-column-projections and no required-row-filter) imposes no restrictions. example: required-column-projections: - field-id: 4 action: show-last-4 - field-id: 6 action: replace-with-null - field-id: 8 action: truncate-to-year - field-id: 10 action: sha-256-global - field-id: 12 action: mask-alphanum required-row-filter: type: eq left: type: reference id: 14 right: type: literal value: US properties: required-column-projections: description: | A list of columns that require specific actions to be applied when reading. A server must not return an action for a column whose type is not listed in that action's "Applicable to" set. If absent or empty, no required actions apply; columns not listed are not subject to any required action. 1. For each column listed, the reader must apply the specified action before returning values for that column. 2. The reader must replace all output references to the column with the result of the action, presenting the result under the original field-id. For example, if the action for field-id `9` is mask-alphanum, the reader must return the masked value as field-id `9` in the query output. 3. A server must not return more than one projection for the same field-id in required-column-projections. If a duplicate field-id appears, the reader must fail the query. 4. A server must not return a projection that targets a map's key field-id; a reader that receives one must fail the query. Applying an action to keys can produce duplicate or null keys, which readers silently coalesce or reject, causing data loss. 5. A reader must enforce projections on the columns it is actually reading. Projections referencing columns that are not being read do not apply. 6. A server must not return projections on both a nested-typed field (struct, list, or map) and any field-id nested within it at any depth. A reader that receives such a response must fail the query. type: array items: $ref: '#/components/schemas/Action' required-row-filter: description: | An expression that limits which rows the reader may return. 1. The expression must evaluate to a boolean (TRUE or FALSE; Iceberg predicates never produce NULL). A reader must discard any row for which the filter evaluates to FALSE, and no information derived from discarded rows may be included in the query result. 2. If this property is absent, null, or always true then no mandatory filtering is required. 3. Column references within the expression must use field IDs (IdReference), not column names. This ensures the filter remains valid across column renames, consistent with required-column-projections which also reference columns by field-id. allOf: - $ref: '#/components/schemas/Predicate' CatalogObjectLabels: type: object description: Flat key-value labels attached to the object (table, view, ...) as a whole. additionalProperties: type: string FieldLabels: type: object description: Labels attached to a single field, identified by field-id. required: - field-id - labels properties: field-id: type: integer description: Field ID from the schema of the table or view labels: type: object description: Flat key-value labels for this field additionalProperties: type: string Labels: type: object description: | Catalog-provided metadata enrichment (for example ownership, classification, or cost attribution) returned with a table or view. Labels are catalog-provided and optional; clients may ignore them, and may cache them following the response ETag. The spec does not require how a catalog produces or stores labels, nor whether they are persisted or versioned. `object-labels` carries labels for the object as a whole; `fields` carries per-field labels, each identified by field-id. properties: object-labels: $ref: '#/components/schemas/CatalogObjectLabels' fields: type: array description: Field-level labels. Each entry identifies its field by field-id. items: $ref: '#/components/schemas/FieldLabels' LoadTableResult: description: | Result used when a table is successfully loaded. The table metadata JSON is returned in the `metadata` field. The corresponding file location of table metadata should be returned in the `metadata-location` field, unless the metadata is not yet committed. For example, a create transaction may return metadata that is staged but not committed. Clients can check whether metadata has changed by comparing metadata locations after the table has been created. The `config` map returns table-specific configuration for the table's resources, including its HTTP client and FileIO. For example, config may contain a specific FileIO implementation class for the table depending on its underlying storage. The following configurations should be respected by clients: ## General Configurations - `token`: Authorization bearer token to use for table requests if OAuth2 security is enabled - `scan-planning-mode`: Communicates to clients the supported planning mode. Clients should use this value to fail fast if the supported scanning mode is not available on the client. Valid values: - `client`: Clients MUST use client-side scan planning - `server`: Clients MUST use server-side scan planning via the `planTableScan` endpoint ## AWS Configurations The following configurations should be respected when working with tables stored in AWS S3 - `client.region`: region to configure client for making requests to AWS - `s3.access-key-id`: id for credentials that provide access to the data in S3 - `s3.secret-access-key`: secret for credentials that provide access to data in S3 - `s3.session-token`: if present, this value should be used for as the session token - `s3.remote-signing-enabled`: if `true` remote signing should be performed as described in the `RemoteSignRequest` schema section of this spec document. - `s3.cross-region-access-enabled`: if `true`, S3 Cross-Region bucket access is enabled ## Storage Credentials Credentials for ADLS / GCS / S3 / ... are provided through the `storage-credentials` field. Clients must first check whether the respective credentials exist in the `storage-credentials` field before checking the `config` for credentials. ## Remote Signing If remote signing for a specific storage provider is enabled, the server SHOULD use the `remote-signing-config` field to communicate all signer client settings. When the `remote-signing-config` field is present, clients SHOULD respect the provided configuration. For backward compatibility, the following `config` properties are still supported but **DEPRECATED** and SHOULD NOT be used by clients able to consume the remote signing configuration: - `signer.endpoint` **DEPRECATED**.: the remote signer endpoint. Can either be a relative path (to be resolved against `signer.uri`) or an absolute URI. - `signer.uri` **DEPRECATED**.: the base URI to resolve `signer.endpoint` against. Only meaningful if `signer.endpoint` is a relative path. Defaults to the catalog's base URI if not set. If any of these properties is present, clients SHOULD use them to compute the actual remote signing endpoint URI to contact. If none of these properties is present, clients SHOULD contact the default remote signing endpoint using the catalog's base URI. type: object required: - metadata properties: metadata-location: type: - string - 'null' description: May be null if the table is staged as part of a transaction metadata: $ref: '#/components/schemas/TableMetadata' config: type: object additionalProperties: type: string storage-credentials: type: array items: $ref: '#/components/schemas/StorageCredential' remote-signing-config: $ref: '#/components/schemas/RemoteSigningConfig' read-restrictions: $ref: '#/components/schemas/ReadRestrictions' labels: $ref: '#/components/schemas/Labels' RegisterTableRequest: type: object required: - name - metadata-location properties: name: type: string metadata-location: type: string overwrite: description: Whether to overwrite table metadata if the table already exists type: boolean default: false TableRequirement: type: object discriminator: propertyName: type mapping: assert-create: '#/components/schemas/AssertCreate' assert-table-uuid: '#/components/schemas/AssertTableUUID' assert-ref-snapshot-id: '#/components/schemas/AssertRefSnapshotId' assert-last-assigned-field-id: '#/components/schemas/AssertLastAssignedFieldId' assert-current-schema-id: '#/components/schemas/AssertCurrentSchemaId' assert-last-assigned-partition-id: '#/components/schemas/AssertLastAssignedPartitionId' assert-default-spec-id: '#/components/schemas/AssertDefaultSpecId' assert-default-sort-order-id: '#/components/schemas/AssertDefaultSortOrderId' properties: type: type: string required: - type AssertCreate: type: object description: The table must not already exist; used for create transactions allOf: - $ref: '#/components/schemas/TableRequirement' required: - type properties: type: type: string const: assert-create AssertTableUUID: description: The table UUID must match the requirement's `uuid` allOf: - $ref: '#/components/schemas/TableRequirement' required: - type - uuid properties: type: type: string const: assert-table-uuid uuid: type: string AssertRefSnapshotId: description: | The table branch or tag identified by the requirement's `ref` must reference the requirement's `snapshot-id`. The `snapshot-id` field is required in this object, but in the case of a `null` the ref must not already exist. allOf: - $ref: '#/components/schemas/TableRequirement' required: - type - ref - snapshot-id properties: type: type: string const: assert-ref-snapshot-id ref: type: string snapshot-id: type: - integer - 'null' format: int64 AssertLastAssignedFieldId: description: The table's last assigned column id must match the requirement's `last-assigned-field-id` allOf: - $ref: '#/components/schemas/TableRequirement' required: - type - last-assigned-field-id properties: type: type: string const: assert-last-assigned-field-id last-assigned-field-id: type: integer AssertCurrentSchemaId: description: The table's current schema id must match the requirement's `current-schema-id` allOf: - $ref: '#/components/schemas/TableRequirement' required: - type - current-schema-id properties: type: type: string const: assert-current-schema-id current-schema-id: type: integer AssertLastAssignedPartitionId: description: The table's last assigned partition id must match the requirement's `last-assigned-partition-id` allOf: - $ref: '#/components/schemas/TableRequirement' required: - type - last-assigned-partition-id properties: type: type: string const: assert-last-assigned-partition-id last-assigned-partition-id: type: integer AssertDefaultSpecId: description: The table's default spec id must match the requirement's `default-spec-id` allOf: - $ref: '#/components/schemas/TableRequirement' required: - type - default-spec-id properties: type: type: string const: assert-default-spec-id default-spec-id: type: integer AssertDefaultSortOrderId: description: The table's default sort order id must match the requirement's `default-sort-order-id` allOf: - $ref: '#/components/schemas/TableRequirement' required: - type - default-sort-order-id properties: type: type: string const: assert-default-sort-order-id default-sort-order-id: type: integer AssignUUIDUpdate: description: Assigning a UUID to a table/view should only be done when creating the table/view. It is not safe to re-assign the UUID if a table/view already has a UUID assigned allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - uuid properties: action: type: string const: assign-uuid uuid: type: string BaseUpdate: discriminator: propertyName: action mapping: assign-uuid: '#/components/schemas/AssignUUIDUpdate' upgrade-format-version: '#/components/schemas/UpgradeFormatVersionUpdate' add-schema: '#/components/schemas/AddSchemaUpdate' set-current-schema: '#/components/schemas/SetCurrentSchemaUpdate' add-spec: '#/components/schemas/AddPartitionSpecUpdate' set-default-spec: '#/components/schemas/SetDefaultSpecUpdate' add-sort-order: '#/components/schemas/AddSortOrderUpdate' set-default-sort-order: '#/components/schemas/SetDefaultSortOrderUpdate' add-snapshot: '#/components/schemas/AddSnapshotUpdate' set-snapshot-ref: '#/components/schemas/SetSnapshotRefUpdate' remove-snapshots: '#/components/schemas/RemoveSnapshotsUpdate' remove-snapshot-ref: '#/components/schemas/RemoveSnapshotRefUpdate' set-location: '#/components/schemas/SetLocationUpdate' set-properties: '#/components/schemas/SetPropertiesUpdate' remove-properties: '#/components/schemas/RemovePropertiesUpdate' add-view-version: '#/components/schemas/AddViewVersionUpdate' set-current-view-version: '#/components/schemas/SetCurrentViewVersionUpdate' set-statistics: '#/components/schemas/SetStatisticsUpdate' remove-statistics: '#/components/schemas/RemoveStatisticsUpdate' set-partition-statistics: '#/components/schemas/SetPartitionStatisticsUpdate' remove-partition-statistics: '#/components/schemas/RemovePartitionStatisticsUpdate' remove-partition-specs: '#/components/schemas/RemovePartitionSpecsUpdate' remove-schemas: '#/components/schemas/RemoveSchemasUpdate' add-encryption-key: '#/components/schemas/AddEncryptionKeyUpdate' remove-encryption-key: '#/components/schemas/RemoveEncryptionKeyUpdate' type: object required: - action properties: action: type: string UpgradeFormatVersionUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - format-version properties: action: type: string const: upgrade-format-version format-version: type: integer AddSchemaUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - schema properties: action: type: string const: add-schema schema: $ref: '#/components/schemas/Schema' last-column-id: type: integer deprecated: true description: |- This optional field is **DEPRECATED for REMOVAL** since it more safe to handle this internally, and shouldn't be exposed to the clients. The highest assigned column ID for the table. This is used to ensure columns are always assigned an unused ID when evolving schemas. When omitted, it will be computed on the server side. SetCurrentSchemaUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - schema-id properties: action: type: string const: set-current-schema schema-id: type: integer description: Schema ID to set as current, or -1 to set last added schema AddPartitionSpecUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - spec properties: action: type: string const: add-spec spec: $ref: '#/components/schemas/PartitionSpec' SetDefaultSpecUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - spec-id properties: action: type: string const: set-default-spec spec-id: type: integer description: Partition spec ID to set as the default, or -1 to set last added spec AddSortOrderUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - sort-order properties: action: type: string const: add-sort-order sort-order: $ref: '#/components/schemas/SortOrder' SetDefaultSortOrderUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - sort-order-id properties: action: type: string const: set-default-sort-order sort-order-id: type: integer description: Sort order ID to set as the default, or -1 to set last added sort order AddSnapshotUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - snapshot properties: action: type: string const: add-snapshot snapshot: $ref: '#/components/schemas/Snapshot' SetSnapshotRefUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' - $ref: '#/components/schemas/SnapshotReference' required: - action - ref-name properties: action: type: string const: set-snapshot-ref ref-name: type: string RemoveSnapshotsUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - snapshot-ids properties: action: type: string const: remove-snapshots snapshot-ids: type: array items: type: integer format: int64 RemoveSnapshotRefUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - ref-name properties: action: type: string const: remove-snapshot-ref ref-name: type: string SetLocationUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - location properties: action: type: string const: set-location location: type: string SetPropertiesUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - updates properties: action: type: string const: set-properties updates: type: object additionalProperties: type: string RemovePropertiesUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - removals properties: action: type: string const: remove-properties removals: type: array items: type: string SQLViewRepresentation: type: object required: - type - sql - dialect properties: type: type: string sql: type: string dialect: type: string ViewRepresentation: oneOf: - $ref: '#/components/schemas/SQLViewRepresentation' ViewVersion: type: object required: - version-id - timestamp-ms - schema-id - summary - representations - default-namespace properties: version-id: type: integer timestamp-ms: type: integer format: int64 schema-id: type: integer description: Schema ID to set as current, or -1 to set last added schema summary: type: object additionalProperties: type: string representations: type: array items: $ref: '#/components/schemas/ViewRepresentation' default-catalog: type: string default-namespace: $ref: '#/components/schemas/Namespace' AddViewVersionUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - view-version properties: action: type: string const: add-view-version view-version: $ref: '#/components/schemas/ViewVersion' SetCurrentViewVersionUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - view-version-id properties: action: type: string const: set-current-view-version view-version-id: type: integer description: The view version id to set as current, or -1 to set last added view version id SetStatisticsUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - statistics properties: action: type: string const: set-statistics snapshot-id: type: integer format: int64 deprecated: true description: This optional field is **DEPRECATED for REMOVAL** since it contains redundant information. Clients should use the `statistics.snapshot-id` field instead. statistics: $ref: '#/components/schemas/StatisticsFile' RemoveStatisticsUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - snapshot-id properties: action: type: string const: remove-statistics snapshot-id: type: integer format: int64 SetPartitionStatisticsUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - partition-statistics properties: action: type: string const: set-partition-statistics partition-statistics: $ref: '#/components/schemas/PartitionStatisticsFile' RemovePartitionStatisticsUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - snapshot-id properties: action: type: string const: remove-partition-statistics snapshot-id: type: integer format: int64 RemovePartitionSpecsUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - spec-ids properties: action: type: string const: remove-partition-specs spec-ids: type: array items: type: integer RemoveSchemasUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - schema-ids properties: action: type: string const: remove-schemas schema-ids: type: array items: type: integer AddEncryptionKeyUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - encryption-key properties: action: type: string const: add-encryption-key encryption-key: $ref: '#/components/schemas/EncryptedKey' RemoveEncryptionKeyUpdate: allOf: - $ref: '#/components/schemas/BaseUpdate' required: - action - key-id properties: action: type: string const: remove-encryption-key key-id: type: string TableUpdate: anyOf: - $ref: '#/components/schemas/AssignUUIDUpdate' - $ref: '#/components/schemas/UpgradeFormatVersionUpdate' - $ref: '#/components/schemas/AddSchemaUpdate' - $ref: '#/components/schemas/SetCurrentSchemaUpdate' - $ref: '#/components/schemas/AddPartitionSpecUpdate' - $ref: '#/components/schemas/SetDefaultSpecUpdate' - $ref: '#/components/schemas/AddSortOrderUpdate' - $ref: '#/components/schemas/SetDefaultSortOrderUpdate' - $ref: '#/components/schemas/AddSnapshotUpdate' - $ref: '#/components/schemas/SetSnapshotRefUpdate' - $ref: '#/components/schemas/RemoveSnapshotsUpdate' - $ref: '#/components/schemas/RemoveSnapshotRefUpdate' - $ref: '#/components/schemas/SetLocationUpdate' - $ref: '#/components/schemas/SetPropertiesUpdate' - $ref: '#/components/schemas/RemovePropertiesUpdate' - $ref: '#/components/schemas/SetStatisticsUpdate' - $ref: '#/components/schemas/RemoveStatisticsUpdate' - $ref: '#/components/schemas/SetPartitionStatisticsUpdate' - $ref: '#/components/schemas/RemovePartitionStatisticsUpdate' - $ref: '#/components/schemas/RemovePartitionSpecsUpdate' - $ref: '#/components/schemas/RemoveSchemasUpdate' - $ref: '#/components/schemas/AddEncryptionKeyUpdate' - $ref: '#/components/schemas/RemoveEncryptionKeyUpdate' CommitTableRequest: type: object required: - requirements - updates properties: identifier: description: Table identifier to update; must be present for CommitTransactionRequest $ref: '#/components/schemas/TableIdentifier' requirements: type: array items: $ref: '#/components/schemas/TableRequirement' updates: type: array items: $ref: '#/components/schemas/TableUpdate' CommitTableResponse: type: object required: - metadata-location - metadata properties: metadata-location: type: string metadata: $ref: '#/components/schemas/TableMetadata' LoadCredentialsResponse: type: object required: - storage-credentials properties: storage-credentials: type: array items: $ref: '#/components/schemas/StorageCredential' RemoteSignRequest: description: The request to be signed remotely. type: object required: - region - uri - method - headers properties: region: type: string uri: type: string method: type: string enum: - PUT - GET - HEAD - POST - DELETE - PATCH - OPTIONS headers: $ref: '#/components/schemas/MultiValuedMap' properties: type: object additionalProperties: type: string body: type: string description: Optional body of the request to send to the signing API. This should only be populated for requests where the body of the message contains content which must be validated before a request is signed, such as the S3 DeleteObjects call. provider: type: string description: The storage provider for which the request is to be signed. The provider should correspond to the scheme used for a storage native URI. For example `s3` for AWS S3 paths. For backwards compatibility, if this is not specified, the provider is assumed to be `s3`. RemoteSignResult: description: The result of a remote request signing operation. type: object required: - uri - headers properties: uri: type: string headers: $ref: '#/components/schemas/MultiValuedMap' RenameTableRequest: type: object required: - source - destination properties: source: $ref: '#/components/schemas/TableIdentifier' destination: $ref: '#/components/schemas/TableIdentifier' CounterResult: type: object required: - unit - value properties: unit: type: string value: type: integer format: int64 TimerResult: type: object required: - time-unit - count - total-duration properties: time-unit: type: string count: type: integer format: int64 total-duration: type: integer format: int64 MetricResult: anyOf: - $ref: '#/components/schemas/CounterResult' - $ref: '#/components/schemas/TimerResult' Metrics: type: object additionalProperties: $ref: '#/components/schemas/MetricResult' example: metrics: total-planning-duration: count: 1 time-unit: nanoseconds total-duration: 2644235116 result-data-files: unit: count value: 1 result-delete-files: unit: count value: 0 total-data-manifests: unit: count value: 1 total-delete-manifests: unit: count value: 0 scanned-data-manifests: unit: count value: 1 skipped-data-manifests: unit: count value: 0 total-file-size-bytes: unit: bytes value: 10 total-delete-file-size-bytes: unit: bytes value: 0 ScanReport: type: object required: - table-name - snapshot-id - filter - schema-id - projected-field-ids - projected-field-names - metrics properties: table-name: type: string snapshot-id: type: integer format: int64 filter: $ref: '#/components/schemas/Predicate' schema-id: type: integer projected-field-ids: type: array items: type: integer projected-field-names: type: array items: type: string metrics: $ref: '#/components/schemas/Metrics' metadata: type: object additionalProperties: type: string CommitReport: type: object required: - table-name - snapshot-id - sequence-number - operation - metrics properties: table-name: type: string snapshot-id: type: integer format: int64 sequence-number: type: integer format: int64 operation: type: string metrics: $ref: '#/components/schemas/Metrics' metadata: type: object additionalProperties: type: string ReportMetricsRequest: anyOf: - $ref: '#/components/schemas/ScanReport' - $ref: '#/components/schemas/CommitReport' required: - report-type properties: report-type: type: string CommitTransactionRequest: type: object required: - table-changes properties: table-changes: type: array items: description: Table commit request; must provide an `identifier` $ref: '#/components/schemas/CommitTableRequest' CreateViewRequest: type: object required: - name - schema - view-version - properties properties: name: type: string location: type: string schema: $ref: '#/components/schemas/Schema' view-version: $ref: '#/components/schemas/ViewVersion' description: The view version to create, will replace the schema-id sent within the view-version with the id assigned to the provided schema properties: type: object additionalProperties: type: string ViewHistoryEntry: type: object required: - version-id - timestamp-ms properties: version-id: type: integer timestamp-ms: type: integer format: int64 ViewMetadata: type: object required: - view-uuid - format-version - location - current-version-id - versions - version-log - schemas properties: view-uuid: type: string format-version: type: integer minimum: 1 maximum: 1 location: type: string current-version-id: type: integer versions: type: array items: $ref: '#/components/schemas/ViewVersion' version-log: type: array items: $ref: '#/components/schemas/ViewHistoryEntry' schemas: type: array items: $ref: '#/components/schemas/Schema' properties: type: object additionalProperties: type: string LoadViewResult: description: | Result used when a view is successfully loaded. The view metadata JSON is returned in the `metadata` field. The corresponding file location of view metadata is returned in the `metadata-location` field. Clients can check whether metadata has changed by comparing metadata locations after the view has been created. The `config` map returns view-specific configuration for the view's resources. The following configurations should be respected by clients: ## General Configurations - `token`: Authorization bearer token to use for view requests if OAuth2 security is enabled type: object required: - metadata-location - metadata properties: metadata-location: type: string metadata: $ref: '#/components/schemas/ViewMetadata' config: type: object additionalProperties: type: string labels: $ref: '#/components/schemas/Labels' RegisterViewRequest: type: object required: - name - metadata-location properties: name: type: string metadata-location: type: string AssertViewUUID: description: The view UUID must match the requirement's `uuid` required: - type - uuid properties: type: type: string const: assert-view-uuid uuid: type: string ViewRequirement: type: object discriminator: propertyName: type mapping: assert-view-uuid: '#/components/schemas/AssertViewUUID' oneOf: - $ref: '#/components/schemas/AssertViewUUID' ViewUpdate: anyOf: - $ref: '#/components/schemas/AssignUUIDUpdate' - $ref: '#/components/schemas/UpgradeFormatVersionUpdate' - $ref: '#/components/schemas/AddSchemaUpdate' - $ref: '#/components/schemas/SetLocationUpdate' - $ref: '#/components/schemas/SetPropertiesUpdate' - $ref: '#/components/schemas/RemovePropertiesUpdate' - $ref: '#/components/schemas/AddViewVersionUpdate' - $ref: '#/components/schemas/SetCurrentViewVersionUpdate' CommitViewRequest: type: object required: - updates properties: identifier: description: View identifier to update $ref: '#/components/schemas/TableIdentifier' requirements: type: array items: $ref: '#/components/schemas/ViewRequirement' updates: type: array items: $ref: '#/components/schemas/ViewUpdate' NotificationType: type: string enum: - UNKNOWN - CREATE - UPDATE - DROP - VALIDATE TableUpdateNotification: type: object required: - table-name - timestamp - table-uuid - metadata-location properties: table-name: type: string timestamp: type: integer format: int64 table-uuid: type: string metadata-location: type: string metadata: $ref: '#/components/schemas/TableMetadata' NotificationRequest: required: - notification-type - payload properties: notification-type: $ref: '#/components/schemas/NotificationType' payload: $ref: '#/components/schemas/TableUpdateNotification' ListGenericTablesResponse: type: object properties: next-page-token: $ref: '#/components/schemas/PageToken' identifiers: type: array uniqueItems: true items: $ref: '#/components/schemas/TableIdentifier' CreateGenericTableRequest: type: object required: - name - format properties: name: type: string format: type: string base-location: type: string doc: type: string properties: type: object additionalProperties: type: string GenericTable: type: object description: | Generic Table information. - `name` (REQUIRED): name for the generic table - `format` (REQUIRED): format for the generic table, i.e. "delta", "csv" - `base-location` (OPTIONAL): table base location in URI format. For example: s3:///path/to/table. - The table base location is a location that includes all files for the table. - A table with multiple disjoint locations (i.e. containing files that are outside the configured base location) is not compliant with the current generic table support in Polaris. - If no location is provided, clients or users are responsible for managing the location. - `properties` (OPTIONAL): properties for the generic table passed on creation - `doc` (OPTIONAL): comment or description for the generic table required: - name - format properties: name: type: string format: type: string base-location: type: string doc: type: string properties: type: object additionalProperties: type: string StorageAccessConfig: type: object required: - prefix - config properties: prefix: type: string description: Indicates a storage location prefix where the configuration is relevant. Clients should choose the most specific prefix (by selecting the longest common prefix) if several configurations of the same type are available. If multiple configurations share the same longest matching prefix, the client may select any of them. However, a server should avoid generating multiple configurations for the same prefix. config: type: object description: | Storage access configurations for S3, GCP GCS, and Azure ADLS are supported. The following outlines the currently supported configuration options: ## S3 Configurations The following configurations should be respected when working with tables stored on S3, including AWS S3, S3-Compatible systems: - `s3.access-key-id`: id for credentials that provide access to the data in S3 - `s3.secret-access-key`: secret for credentials that provide access to data in S3 - `s3.session-token`: if present, this value should be used for as the session token - `s3.session-token-expires-at-ms`: the time the aws session token expires, in milliseconds - `s3.client.region`: region to configure client for making requests to S3 - `s3.client.refresh-credentials-endpoint`: the endpoint to load vended credentials for a table from the catalog ## GCP GCS Configurations The following configurations should be respected when working with tables stored in GCP GCS: - `gcs.oauth2.token`: the gcs scoped access token - `gcs.oauth2.token-expires-at`: the time the gcs access token expires, in milliseconds - `gcs.oauth2.refresh-credentials-endpoint`: the endpoint to load vended credentials for a table from the catalog ## AZURE ADLS Configuration The following configurations should be respected when working with tables stored in AZURE ADLS: - `adls.sas-token.`: an azure shared access signature token - `adls.sas-token-expires-at-ms.`: the expiration time for the access token, in milliseconds - `adls.refresh-credentials-endpoint`: the endpoint to load vended credentials for a table from the catalog additionalProperties: type: string LoadGenericTableResponse: description: Result used when a table is successfully loaded. type: object required: - table properties: table: $ref: '#/components/schemas/GenericTable' storage-access-configs: type: array description: | Storage configurations required to access the table, encompassing both credentials and other necessary settings for storage access, such as the client region for S3. items: $ref: '#/components/schemas/StorageAccessConfig' PolicyType: description: The type of a policy type: - string - 'null' example: system.data-compaction PolicyIdentifier: type: object required: - namespace - name properties: namespace: $ref: '#/components/schemas/Namespace' name: type: string ListPoliciesResponse: type: object properties: next-page-token: $ref: '#/components/schemas/PageToken' identifiers: type: array uniqueItems: true items: $ref: '#/components/schemas/PolicyIdentifier' PolicyName: type: string description: A policy name. A valid policy name should only consist of uppercase and lowercase letters (A-Z, a-z), digits (0-9), hyphens (-), underscores (_). pattern: ^[A-Za-z0-9\-_]+$ example: compaction CreatePolicyRequest: type: object required: - name - type properties: name: $ref: '#/components/schemas/PolicyName' type: type: string description: type: string content: type: string Policy: type: object description: | A policy in Apache Polaris defines a set of rules for governing access, data usage, and operational consistency across various catalog resources. Policies are stored within Polaris and can be attached to catalogs, namespaces, tables, or views. For example, they can be used for fine-grained control over who can perform specific actions on certain resources. The policy object includes - **policy-type:** The type of the policy, which determines the expected format and semantics of the policy content. - **inheritable:** A boolean flag indicating whether the policy is inheritable. - **name:** A human-readable name for the policy, which must be unique within a given namespace. - **description:** Detailed description of the purpose and functionalities of the policy. - **content:** Policy content, which can be validated against predefined schemas of a policy type. - **version:** Indicates the current version of the policy. Versions increased monotonically, the default value is 0 Policies stored in Polaris serve as the persistent definition for access control and governance rules. required: - policy-type - name - version - inheritable properties: policy-type: type: string inheritable: type: boolean name: $ref: '#/components/schemas/PolicyName' description: type: string content: type: string version: type: integer LoadPolicyResponse: type: object properties: policy: $ref: '#/components/schemas/Policy' UpdatePolicyRequest: type: object properties: description: type: string content: type: string current-policy-version: type: integer PolicyAttachmentTarget: type: object required: - type properties: type: type: string description: | Policy can be attached to different levels: 1. table-like: Policies specific to individual tables or views. 2. namespace: Policies applies to a namespace. 3. catalog: Policies that applies to a catalog enum: - catalog - namespace - table-like example: table-like path: type: array items: type: string description: | A list representing the hierarchical path to the target, ordered from the namespace level down to the entity. If the target is catalog, the path should be either empty or not set. example: - NS1 - NS2 - test_table_1 AttachPolicyRequest: type: object required: - target properties: target: $ref: '#/components/schemas/PolicyAttachmentTarget' parameters: type: object additionalProperties: type: string DetachPolicyRequest: type: object required: - target properties: target: $ref: '#/components/schemas/PolicyAttachmentTarget' ApplicablePolicy: allOf: - type: object description: | For policies returned by GetApplicablePolicies, there are 2 additional fields - **inherited:** A boolean flag indicating whether the policy is inherited from target's parents. For non-inheritable policy, it should always be `false`. - **namespace:** A list representing the hierarchical parent path to the policy, ordered from higher level namespace to lower. required: - inherited - namespace properties: inherited: type: boolean default: false namespace: $ref: '#/components/schemas/Namespace' - $ref: '#/components/schemas/Policy' GetApplicablePoliciesResponse: type: object required: - applicable-policies properties: next-page-token: $ref: '#/components/schemas/PageToken' applicable-policies: type: array uniqueItems: true items: $ref: '#/components/schemas/ApplicablePolicy' SemanticModelName: type: string description: A semantic model name. A valid name consists of uppercase and lowercase letters (A-Z, a-z), digits (0-9), hyphens (-), and underscores (_). pattern: ^[A-Za-z0-9\-_]+$ example: tpcds_retail_model SemanticModelIdentifier: type: object required: - namespace - name properties: namespace: $ref: '#/components/schemas/Namespace' name: $ref: '#/components/schemas/SemanticModelName' ListSemanticModelsResponse: type: object properties: next-page-token: $ref: '#/components/schemas/PageToken' identifiers: type: array uniqueItems: true items: $ref: '#/components/schemas/SemanticModelIdentifier' SemanticModelDocument: type: object description: An Apache Ossie document body. required: - version - semantic_model properties: version: type: string description: The Apache Ossie spec version. example: 0.2.0.dev0 semantic_model: type: string description: The Apache Ossie semantic model serialized as a JSON object string. example: version: 0.2.0.dev0 semantic_model: '{"name":"tpcds_retail_model","description":"retail analytics","datasets":[{"name":"store_sales","source":"public.store_sales","primary_key":["ss_item_sk","ss_ticket_number"]}],"metrics":[{"name":"total_sales","expression":{"dialects":[{"dialect":"ANSI_SQL","expression":"SUM(ss_ext_sales_price)"}]}}]}' CreateSemanticModelRequest: type: object required: - name - document properties: name: $ref: '#/components/schemas/SemanticModelName' document: $ref: '#/components/schemas/SemanticModelDocument' EntityVersion: type: string maxLength: 255 description: | An opaque UTF-8 string (at most 255 characters) identifying a version of a semantic-model entity, used for optimistic concurrency. A create/load/update response returns the entity's current version; supply the value you last read on a subsequent update so the change applies only if it still matches the version stored in the catalog. LoadSemanticModelResponse: type: object required: - document - entity-version properties: document: $ref: '#/components/schemas/SemanticModelDocument' entity-version: $ref: '#/components/schemas/EntityVersion' UpdateSemanticModelRequest: type: object required: - document - entity-version properties: document: $ref: '#/components/schemas/SemanticModelDocument' entity-version: $ref: '#/components/schemas/EntityVersion' AccessibleCatalog: type: object description: A catalog the caller can access required: - name properties: name: type: string description: The catalog's name, as passed to the configuration endpoint's `warehouse` parameter ListAccessibleCatalogsResponse: type: object required: - catalogs properties: next-page-token: type: string description: The token for the next page, passed as pageToken. Absent on the last page catalogs: type: array uniqueItems: true items: $ref: '#/components/schemas/AccessibleCatalog' MetricType: type: string description: | Identifies the type of a metrics report. Standard types currently defined by this specification are `iceberg-scan` and `iceberg-commit`. Additional standard types may be introduced in future versions. Implementation-specific types SHOULD use an `x-` prefix followed by an implementation namespace, for example, `x-my-metric`, to avoid collisions with standard types. This is a naming convention, not a schema constraint. CatalogObject: type: object description: | Identifies a catalog object and, optionally, one of its snapshots. The identifier, type and snapshot ID of an entry must match together. required: - identifier properties: identifier: $ref: '#/components/schemas/CatalogObjectIdentifier' type: type: string default: iceberg-table description: | The catalog object type. Combined with identifier, identifies the exact catalog object. Defaults to `iceberg-table` when omitted. Currently, only `iceberg-table` is supported; entries with unsupported values are ignored. snapshot-id: type: string description: | Optional snapshot filter for this object. An opaque identifier whose format depends on the object's table format; for `iceberg-table` it is the decimal Iceberg snapshot ID. If omitted, no snapshot filter is applied. QueryMetricsRequest: type: object required: - metric-types - objects properties: metric-types: type: array minItems: 1 description: | Types of metrics to retrieve. Reports of any of the listed types are returned. Unsupported types yield no reports. items: $ref: '#/components/schemas/MetricType' objects: type: array minItems: 1 description: | Catalog objects to query, all belonging to the catalog identified by prefix in the path. Entries are combined with OR semantics. Omitting `snapshot-id` on an entry applies no snapshot filter; the other query filters still apply. If the same object appears both with and without a snapshot ID, the entry without a snapshot ID takes precedence. Overlapping entries do not duplicate reports. The server limits the number of entries per request and rejects larger requests with a 400. Entries naming a table that does not exist, or one the caller may not read metrics of, are omitted from the result. items: $ref: '#/components/schemas/CatalogObject' page-token: type: string description: | Opaque token returned as `next-page-token` by a previous response. Omit it to request the first page. Any response may be paginated, whether or not the request carried a `page-token` or a `page-size`. page-size: type: integer minimum: 1 description: | A hint for the maximum number of reports per page. The server decides the actual page size and may return fewer reports than requested. timestamp-from: type: integer format: int64 description: | Inclusive lower bound on report timestamp (Unix epoch milliseconds). When omitted, the server applies a default window that ends at `timestamp-to`, or at the time of the request when `timestamp-to` is also omitted. timestamp-to: type: integer format: int64 description: | Exclusive upper bound on report timestamp (Unix epoch milliseconds). Must be greater than `timestamp-from` when both are given. MetricsReport: type: object description: | Envelope for a single persisted metrics report. The `payload` is an opaque JSON object so fields can be added without requiring a change to this API's schema. required: - metric-type - object - timestamp-ms - payload properties: metric-type: $ref: '#/components/schemas/MetricType' object: $ref: '#/components/schemas/CatalogObject' timestamp-ms: type: integer format: int64 description: Server-side timestamp when the report was received (Unix epoch milliseconds) payload: type: object additionalProperties: true description: | Opaque metrics report payload, e.g. `{"type": "iceberg.metrics.scan", "version": 1, "data": {...}}`. The payload is a projection reconstructed from the persisted metrics record, not the original report as received: `data` contains only the metric fields the persistence backend stores, and fields of the original report that are not persisted (e.g. custom metrics or report metadata) are not returned. Clients must not assume every field of the original Iceberg report is present. When available, request correlation identifiers are returned under `request` (`request-id`, `otel-trace-id`, `otel-span-id`). ListMetricsResponse: type: object required: - reports properties: next-page-token: type: string nullable: true description: | Opaque cursor for fetching the next page. Null or absent when no further pages exist. A cursor is valid only with the same `metric-types`, `objects`, `timestamp-from` and `timestamp-to` as the request that produced it; the server rejects it with a 400 otherwise. reports: type: array items: $ref: '#/components/schemas/MetricsReport' responses: BadRequestErrorResponse: description: Indicates a bad request error. It could be caused by an unexpected request body format or other forms of request validation failure, such as invalid json. Usually serves application/json content, although in some cases simple text/plain content might be returned by the server's middleware. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Malformed request type: BadRequestException code: 400 UnauthorizedResponse: description: Unauthorized. The REST Catalog SHOULD respond with the 401 UnauthorizedResponse when the access token provided is expired, revoked, malformed, or invalid for other reasons. The client MAY request a new access token and retry the request. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Not authorized to make this request type: NotAuthorizedException code: 401 ForbiddenResponse: description: Forbidden. Authenticated user does not have the necessary permissions. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Not authorized to make this request type: NotAuthorizedException code: 403 AuthenticationTimeoutResponse: description: This is an optional status response type that the REST Catalog can issue when the token has expired. The client MAY request a new access token and retry the request. 401 UnauthorizedResponse SHOULD be preferred over this response type on token expiry. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Credentials have timed out type: AuthenticationTimeoutException code: 419 ServiceUnavailableResponse: description: |- The service is not ready to handle the request, request could have been partially processed. The service may additionally send a Retry-After header to indicate when to retry, a non idempotent request should only be retried by the client when the Retry-After header is present. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Slow down type: SlowDownException code: 503 ServerErrorResponse: description: A server-side problem that might not be addressable from the client side. Used for server 5xx errors without more specific documentation in individual routes. content: application/json: schema: $ref: '#/components/schemas/IcebergErrorResponse' example: error: message: Internal Server Error type: InternalServerError code: 500 OAuthTokenResponse: description: OAuth2 token response for client credentials or token exchange content: application/json: schema: $ref: '#/components/schemas/OAuthTokenResponse' OAuthErrorResponse: description: OAuth2 error response content: application/json: schema: $ref: '#/components/schemas/OAuthError' ListNamespacesResponse: description: A list of namespaces content: application/json: schema: $ref: '#/components/schemas/ListNamespacesResponse' examples: NonEmptyResponse: $ref: '#/components/examples/ListNamespacesNonEmptyExample' EmptyResponse: $ref: '#/components/examples/ListNamespacesEmptyExample' CreateNamespaceResponse: description: Represents a successful call to create a namespace. Returns the namespace created, as well as any properties that were stored for the namespace, including those the server might have added. Implementations are not required to support namespace properties. content: application/json: schema: $ref: '#/components/schemas/CreateNamespaceResponse' example: namespace: - accounting - tax properties: owner: Ralph created_at: '1452120468' UnsupportedOperationResponse: description: Not Acceptable / Unsupported Operation. The server does not support this operation. content: application/json: schema: $ref: '#/components/schemas/ErrorModel' example: error: message: The server does not support this operation type: UnsupportedOperationException code: 406 GetNamespaceResponse: description: Returns a namespace, as well as any properties stored on the namespace if namespace properties are supported by the server. content: application/json: schema: $ref: '#/components/schemas/GetNamespaceResponse' UpdateNamespacePropertiesResponse: description: JSON data response for a synchronous update properties request. content: application/json: schema: $ref: '#/components/schemas/UpdateNamespacePropertiesResponse' example: updated: - owner removed: - foo missing: - bar ListTablesResponse: description: A list of table identifiers content: application/json: schema: $ref: '#/components/schemas/ListTablesResponse' examples: ListTablesResponseNonEmpty: $ref: '#/components/examples/ListTablesNonEmptyExample' ListTablesResponseEmpty: $ref: '#/components/examples/ListTablesEmptyExample' CreateTableResponse: description: Table metadata result after creating a table content: application/json: schema: $ref: '#/components/schemas/LoadTableResult' headers: etag: $ref: '#/components/headers/etag' LoadTableResponse: description: Table metadata result when loading a table content: application/json: schema: $ref: '#/components/schemas/LoadTableResult' headers: etag: $ref: '#/components/headers/etag' CommitTableResponse: description: |- Response used when a table is successfully updated. The table metadata JSON is returned in the metadata field. The corresponding file location of table metadata must be returned in the metadata-location field. Clients can check whether metadata has changed by comparing metadata locations. content: application/json: schema: $ref: '#/components/schemas/CommitTableResponse' headers: etag: $ref: '#/components/headers/etag' LoadCredentialsResponse: description: Table credentials result when loading credentials for a table content: application/json: schema: $ref: '#/components/schemas/LoadCredentialsResponse' RemoteSignResponse: description: The response containing signed & unsigned headers. The server will also send a Cache-Control header, indicating whether the response can be cached (Cache-Control = ["private"]) or not (Cache-Control = ["no-cache"]). content: application/json: schema: $ref: '#/components/schemas/RemoteSignResult' LoadViewResponse: description: View metadata result when loading a view content: application/json: schema: $ref: '#/components/schemas/LoadViewResult' ListGenericTablesResponse: description: List of generic table identifiers. content: application/json: schema: $ref: '#/components/schemas/ListGenericTablesResponse' CreateGenericTableResponse: description: Table result if successfully created a generic table. content: application/json: schema: $ref: '#/components/schemas/LoadGenericTableResponse' LoadGenericTableResponse: description: Table result if successfully load a generic table. content: application/json: schema: $ref: '#/components/schemas/LoadGenericTableResponse' ListPoliciesResponse: description: a list of policy identifiers content: application/json: schema: $ref: '#/components/schemas/ListPoliciesResponse' examples: ListPoliciesResponseNonEmpty: $ref: '#/components/examples/ListPoliciesNonEmptyExample' ListPoliciesResponseEmpty: $ref: '#/components/examples/ListPoliciesEmptyExample' CreatePolicyResponse: description: Policy object result after creating a policy content: application/json: schema: $ref: '#/components/schemas/LoadPolicyResponse' LoadPolicyResponse: description: Policy object result when getting a policy content: application/json: schema: $ref: '#/components/schemas/LoadPolicyResponse' UpdatePolicyResponse: description: |- Response used when a policy is successfully updated The updated policy JSON is returned in the policy field content: application/json: schema: $ref: '#/components/schemas/LoadPolicyResponse' GetApplicablePoliciesResponse: description: A list of policies applicable to the table content: application/json: schema: $ref: '#/components/schemas/GetApplicablePoliciesResponse' ListSemanticModelsResponse: description: A list of semantic model identifiers content: application/json: schema: $ref: '#/components/schemas/ListSemanticModelsResponse' examples: ListSemanticModelsResponseNonEmpty: $ref: '#/components/examples/ListSemanticModelsNonEmptyExample' ListSemanticModelsResponseEmpty: $ref: '#/components/examples/ListSemanticModelsEmptyExample' CreateSemanticModelResponse: description: Semantic model object result after creating a semantic model content: application/json: schema: $ref: '#/components/schemas/LoadSemanticModelResponse' LoadSemanticModelResponse: description: Semantic model object result when loading a semantic model content: application/json: schema: $ref: '#/components/schemas/LoadSemanticModelResponse' UpdateSemanticModelResponse: description: | Response when a semantic model is successfully updated. The updated Apache Ossie document is returned in the `document` field. content: application/json: schema: $ref: '#/components/schemas/LoadSemanticModelResponse' ListAccessibleCatalogsResponse: description: A page of the catalogs the caller can access content: application/json: schema: $ref: '#/components/schemas/ListAccessibleCatalogsResponse' example: catalogs: - name: sales - name: marketing examples: NoSuchWarehouseError: summary: The requested warehouse does not exist value: error: message: The given warehouse does not exist type: NoSuchWarehouseException code: 404 ListNamespacesNonEmptyExample: summary: A non-empty list of namespaces value: namespaces: - - accounting - tax - - accounting - credits ListNamespacesEmptyExample: summary: An empty list of namespaces value: namespaces: [] NoSuchNamespaceError: summary: The requested namespace does not exist value: error: message: The given namespace does not exist type: NoSuchNamespaceException code: 404 NamespaceAlreadyExistsError: summary: The requested namespace already exists value: error: message: The given namespace already exists type: AlreadyExistsException code: 409 NamespaceNotEmptyError: summary: The requested namespace is not empty value: error: message: The given namespace is not empty type: NamespaceNotEmptyException code: 409 UpdateAndRemoveNamespacePropertiesRequest: summary: An update namespace properties request with both properties to remove and properties to upsert. value: removals: - foo - bar updates: owner: Raoul UnprocessableEntityDuplicateKey: summary: The request body either has the same key multiple times in what should be a map with unique keys or the request body has keys in two or more fields which should be disjoint sets. value: error: message: The request cannot be processed as there is a key present multiple times type: UnprocessableEntityException code: 422 ListTablesNonEmptyExample: summary: A non-empty list of table identifiers value: identifiers: - namespace: - accounting - tax name: paid - namespace: - accounting - tax name: owed ListTablesEmptyExample: summary: An empty list for a namespace with no tables value: identifiers: [] TableAlreadyExistsError: summary: The requested table identifier already exists value: error: message: The requested table identifier already exists type: AlreadyExistsException code: 409 NoSuchTableError: summary: The requested table does not exist value: error: message: The given table does not exist type: NoSuchTableException code: 404 RenameTableSameNamespace: summary: Rename a table in the same namespace value: source: namespace: - accounting - tax name: paid destination: namespace: - accounting - tax name: owed ViewAlreadyExistsError: summary: The requested view identifier already exists value: error: message: The requested view identifier already exists type: AlreadyExistsException code: 409 NoSuchViewError: summary: The requested view does not exist value: error: message: The given view does not exist type: NoSuchViewException code: 404 RenameViewSameNamespace: summary: Rename a view in the same namespace value: source: namespace: - accounting - tax name: paid-view destination: namespace: - accounting - tax name: owed-view ListPoliciesNonEmptyExample: summary: A non-empty list of policy identifiers value: identifiers: - namespace: - accounting - tax name: policy1 - namespace: - accounting - tax name: policy2 ListPoliciesEmptyExample: summary: An empty list for a namespace with no policies value: identifiers: [] PolicyAlreadyExistsError: summary: The requested policy identifier already exists value: error: message: The given policy already exists type: AlreadyExistsException code: 409 NoSuchPolicyError: summary: The requested policy does not exist value: error: message: The given policy does not exist type: NoSuchPolicyException code: 404 PolicyVersionMismatchError: summary: The policy version doesn't match the current-policy-version value: error: message: The policy version doesn't match the current-policy-version type: PolicyVersionMismatchException code: 409 PolicyInUseError: summary: The policy is attached to one or more targets value: error: message: The policy is attached to one or more targets type: PolicyInUseException code: 400 NoSuchTargetError: summary: The requested target does not exist value: error: message: The given target does not exist type: NoSuchTargetException code: 404 ConflictPolicyAttachmentError: summary: The policy type is inheritable and there is already a policy of the same type attached to the target entity value: error: message: The policy type is inheritable and there is already a policy of the same type attached to the target entity type: ConflictPolicyAttachmentException code: 409 NoSuchMappingError: summary: The requested mapping between policy and target does not exist value: error: message: The given mapping between policy and target does not exist type: NoSuchMappingException code: 404 ListSemanticModelsNonEmptyExample: summary: A non-empty list of semantic model identifiers value: identifiers: - namespace: - sales name: tpcds_retail_model - namespace: - sales name: orders_funnel ListSemanticModelsEmptyExample: summary: An empty list for a namespace with no semantic models value: identifiers: [] SemanticModelAlreadyExistsError: summary: A semantic model with this name already exists in the namespace value: error: message: The given semantic model already exists type: AlreadyExistsException code: 409 NoSuchSemanticModelError: summary: The requested semantic model does not exist value: error: message: The given semantic model does not exist type: NoSuchSemanticModelException code: 404 SemanticModelVersionMismatchError: summary: The supplied entity-version does not match the stored version value: error: message: The semantic model version doesn't match the supplied entity-version type: SemanticModelVersionMismatchException code: 409 parameters: prefix: name: prefix in: path schema: type: string required: true description: An optional prefix in the path page-token: name: pageToken in: query required: false schema: $ref: '#/components/schemas/PageToken' page-size: name: pageSize in: query description: For servers that support pagination, this signals an upper bound of the number of results that a client will receive. For servers that do not support pagination, clients may receive results larger than the indicated `pageSize`. required: false schema: type: integer minimum: 1 idempotency-key: name: Idempotency-Key in: header required: false schema: type: string format: uuid minLength: 36 maxLength: 36 example: 017F22E2-79B0-7CC3-98C4-DC0C0C07398F description: | Optional client-provided idempotency key for safe request retries. When present, the server ensures no additional effects for requests that carry the same Idempotency-Key. If a prior request with this key has been finalized, the server returns an equivalent final response without re-running the operation. The response body may reflect a newer state of the catalog than existed at the time of the commit. Finalization rules: - Finalize & replay: 200, 201, 204, and deterministic terminal 4xx (including 409 such as AlreadyExists, NamespaceNotEmpty, etc.) - Do not finalize (not stored/replayed): 5xx Key Requirements: - Key format: UUIDv7 in string form (RFC 9562). - The idempotency key must be globally unique (no reuse across different operations). - Catalogs SHOULD NOT expire keys before the end of the advertised token lifetime. - If Idempotency-Key is used, clients MUST reuse the same key when retrying the same logical operation and MUST generate a new key for a different operation. namespace: name: namespace in: path required: true description: A namespace identifier as a single string. Multipart namespace parts must be separated by the namespace separator as indicated via the /config override `namespace-separator`, which defaults to the unit separator `0x1F` byte (url encoded `%1F`). To be compatible with older clients, servers must use both the advertised separator and `0x1F` as valid separators when decoding namespaces. The `namespace-separator` should be provided in a url encoded form. schema: type: string examples: singlepart_namespace: value: accounting multipart_namespace: value: accounting%1Ftax data-access: name: X-Iceberg-Access-Delegation in: header description: | Optional signal to the server that the client supports delegated access via a comma-separated list of access mechanisms. The server may choose to supply access via any or none of the requested mechanisms. Specific properties and handling for `vended-credentials` and `remote-signing` are documented in the `LoadTableResult` schema section of this spec document. required: false schema: type: array items: type: string enum: - vended-credentials - remote-signing style: simple explode: false example: vended-credentials,remote-signing table: name: table in: path description: A table name required: true schema: type: string example: sales referenced-by: name: referenced-by in: query description: |- A comma-separated list of fully qualified view names (namespace and view name) representing the view reference chain when an entity (table or view) is loaded via a view. The list should be ordered with the outermost view first, followed by any intermediate views it references, down to the view that directly references the entity. For a simple case where a view directly references the entity, the list contains a single view identifier. For nested views (a view referencing another view which references the entity), the list contains multiple view identifiers representing the complete dependency chain. The view identifier is a composite string of the format {namespace}{separator}{viewName}. The namespace-separator (defined in /config) acts as the delimiter. When parsing, the last occurrence of this separator identifies the boundary between the namespace and the view name. Multipart namespaces must follow the encoding rules of the parent parameter in the list namespaces endpoint. Multiple view identifiers are separated by commas. Servers should split the parameter value on comma characters to parse individual view identifiers. If view names contain commas, they must be url-encoded as %2C. Example with multiple views (where prod%1Fanalytics is a nested namespace which has a quarterly_view which references to monthly_view which then references the entity being loaded) - prod%1Fanalytics%1Fquarterly_view,prod%1Fanalytics%1Fmonthly_view required: false schema: type: string view: name: view in: path description: A view name required: true schema: type: string example: sales polaris-generic-table-data-access: name: Polaris-Generic-Table-Access-Delegation in: header description: | Optional header indicating that the client supports delegated access using a specific mechanism. If the header is present, the server must either provide access using the requested mechanism or fail the request. If `vended-credentials` is specified, the server must return scoped storage credentials in the `storage-access-configs` field of the response. required: false schema: type: string enum: - vended-credentials style: simple explode: false example: vended-credentials generic-table: name: generic-table in: path description: A generic table name required: true schema: type: string example: sales policy-type: name: policyType in: query required: false allowEmptyValue: true schema: $ref: '#/components/schemas/PolicyType' policy-name: name: policy-name in: path required: true schema: $ref: '#/components/schemas/PolicyName' semantic-model-name: name: semantic-model-name in: path required: true schema: $ref: '#/components/schemas/SemanticModelName' pageToken: name: pageToken in: query required: false description: The continuation token returned with the previous page. Absent for the first page schema: type: string pageSize: name: pageSize in: query required: false description: Maximum number of items to return, at least 1. If absent, or larger than the service's maximum, the service's maximum is used schema: type: integer minimum: 1 headers: etag: name: ETag in: header description: |- Identifies a unique version of the table metadata. Implementations that support ETags should produce unique tags for responses that return different metadata content but represent the same version of table metadata. For example, the `snapshots` query parameter may result in different metadata representations depending on whether `refs` or `all` is provided, therefore should have distinct ETags. required: false schema: type: string