Create a view in the given namespace
post
{scheme}://{host}/{basePath}/v1/{prefix}/namespaces/{namespace}/views
Create a view in the given namespace.
Request
Path Parameters
-
namespace(required): string
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.Examples
-
prefix(required): string
An optional prefix in the path
Supported Media Types
- application/json
Nested Schema : ViewVersion
Type:
Show Source
object-
default-catalog: string
-
default-namespace(required): array
Namespace
Reference to one or more levels of a namespace
-
representations(required): array
representations
-
schema-id(required): integer
Schema ID to set as current, or -1 to set last added schema
-
summary(required): object
summary
Additional Properties Allowed: additionalProperties
-
timestamp-ms(required): integer
(int64)
-
version-id(required): integer
Nested Schema : Schema-allOf[1]
Type:
Show Source
object-
identifier-field-ids: array
identifier-field-ids
-
schema-id: integer
Read Only:
true
Nested Schema : PrimitiveTypeValue
Match One Schema
Show Source
-
boolean
Title:
BooleanTypeValueExample:true -
integer
Title:
IntegerTypeValueExample:42 -
integer(int64)
Title:
LongTypeValueExample:9223372036854776000 -
number(float)
Title:
FloatTypeValueExample:3.14 -
number(double)
Title:
DoubleTypeValueExample:123.456 -
string
Title:
DecimalTypeValueDecimal 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.45 -
string
Title:
StringTypeValueExample:hello -
string(uuid)
Title:
UUIDTypeValueMinimum Length:36Maximum Length:36Pattern:^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$UUID type values are serialized as a 36-character lowercase string in standard UUID format as specified by RFC-4122Example:eb26bdb1-a1d8-4aa6-990e-da940875492c -
string(date)
Title:
DateTypeValueDate type values follow the 'YYYY-MM-DD' ISO-8601 standard date formatExample:2007-12-03 -
string
Title:
TimeTypeValueTime type values follow the 'HH:MM:SS.ssssss' ISO-8601 format with microsecond precisionExample:22:31:08.123456 -
string
Title:
TimestampTypeValueTimestamp type values follow the 'YYYY-MM-DDTHH:MM:SS.ssssss' ISO-8601 format with microsecond precisionExample:2007-12-03T10:15:30.123456 -
string
Title:
TimestampTzTypeValueTimestampTz 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 -
string
Title:
TimestampNanoTypeValueTimestamp_ns type values follow the 'YYYY-MM-DDTHH:MM:SS.sssssssss' ISO-8601 format with nanosecond precisionExample:2007-12-03T10:15:30.123456789 -
string
Title:
TimestampTzNanoTypeValueTimestamp_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 -
string
Title:
FixedTypeValueFixed length type values are stored and serialized as an uppercase hexadecimal string preserving the fixed lengthExample:78797A -
string
Title:
BinaryTypeValueBinary type values are stored and serialized as an uppercase hexadecimal stringExample:78797A
Nested Schema : Namespace
Type:
arrayReference to one or more levels of a namespace
Show Source
Example:
[
"accounting",
"tax"
]Nested Schema : ViewRepresentation
Match One Schema
Show Source
-
object
SQLViewRepresentation
Title:
SQLViewRepresentation
Response
Supported Media Types
- application/json
200 Response
View metadata result when loading a view
Root Schema : LoadViewResult
Type:
objectResult 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
Show Source
-
config: object
config
Additional Properties Allowed: additionalProperties
-
metadata(required): object
ViewMetadata
-
metadata-location(required): string
Nested Schema : ViewMetadata
Type:
Show Source
object-
current-version-id(required): integer
-
format-version(required): integer
Minimum Value:
1Maximum Value:1 -
location(required): string
-
properties: object
properties
Additional Properties Allowed: additionalProperties
-
schemas(required): array
schemas
-
version-log(required): array
version-log
-
versions(required): array
versions
-
view-uuid(required): string
Nested Schema : Schema-allOf[1]
Type:
Show Source
object-
identifier-field-ids: array
identifier-field-ids
-
schema-id: integer
Read Only:
true
Nested Schema : PrimitiveTypeValue
Match One Schema
Show Source
-
boolean
Title:
BooleanTypeValueExample:true -
integer
Title:
IntegerTypeValueExample:42 -
integer(int64)
Title:
LongTypeValueExample:9223372036854776000 -
number(float)
Title:
FloatTypeValueExample:3.14 -
number(double)
Title:
DoubleTypeValueExample:123.456 -
string
Title:
DecimalTypeValueDecimal 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.45 -
string
Title:
StringTypeValueExample:hello -
string(uuid)
Title:
UUIDTypeValueMinimum Length:36Maximum Length:36Pattern:^[0-9a-f]{8}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{4}-[0-9a-f]{12}$UUID type values are serialized as a 36-character lowercase string in standard UUID format as specified by RFC-4122Example:eb26bdb1-a1d8-4aa6-990e-da940875492c -
string(date)
Title:
DateTypeValueDate type values follow the 'YYYY-MM-DD' ISO-8601 standard date formatExample:2007-12-03 -
string
Title:
TimeTypeValueTime type values follow the 'HH:MM:SS.ssssss' ISO-8601 format with microsecond precisionExample:22:31:08.123456 -
string
Title:
TimestampTypeValueTimestamp type values follow the 'YYYY-MM-DDTHH:MM:SS.ssssss' ISO-8601 format with microsecond precisionExample:2007-12-03T10:15:30.123456 -
string
Title:
TimestampTzTypeValueTimestampTz 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 -
string
Title:
TimestampNanoTypeValueTimestamp_ns type values follow the 'YYYY-MM-DDTHH:MM:SS.sssssssss' ISO-8601 format with nanosecond precisionExample:2007-12-03T10:15:30.123456789 -
string
Title:
TimestampTzNanoTypeValueTimestamp_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 -
string
Title:
FixedTypeValueFixed length type values are stored and serialized as an uppercase hexadecimal string preserving the fixed lengthExample:78797A -
string
Title:
BinaryTypeValueBinary type values are stored and serialized as an uppercase hexadecimal stringExample:78797A
Nested Schema : ViewVersion
Type:
Show Source
object-
default-catalog: string
-
default-namespace(required): array
Namespace
Reference to one or more levels of a namespace
-
representations(required): array
representations
-
schema-id(required): integer
Schema ID to set as current, or -1 to set last added schema
-
summary(required): object
summary
Additional Properties Allowed: additionalProperties
-
timestamp-ms(required): integer
(int64)
-
version-id(required): integer
Nested Schema : Namespace
Type:
arrayReference to one or more levels of a namespace
Show Source
Example:
[
"accounting",
"tax"
]Nested Schema : ViewRepresentation
Match One Schema
Show Source
-
object
SQLViewRepresentation
Title:
SQLViewRepresentation
400 Response
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.
Root Schema : IcebergErrorResponse
Type:
objectJSON wrapper for all error responses (non-2xx)
Show Source
-
error(required): object
ErrorModel
JSON error payload returned in a response with further details on the error
Example:
{
"error":{
"message":"The server does not support this operation",
"type":"UnsupportedOperationException",
"code":406
}
}Nested Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException
401 Response
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.
Root Schema : IcebergErrorResponse
Type:
objectJSON wrapper for all error responses (non-2xx)
Show Source
-
error(required): object
ErrorModel
JSON error payload returned in a response with further details on the error
Example:
{
"error":{
"message":"The server does not support this operation",
"type":"UnsupportedOperationException",
"code":406
}
}Nested Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException
403 Response
Forbidden. Authenticated user does not have the necessary permissions.
Root Schema : IcebergErrorResponse
Type:
objectJSON wrapper for all error responses (non-2xx)
Show Source
-
error(required): object
ErrorModel
JSON error payload returned in a response with further details on the error
Example:
{
"error":{
"message":"The server does not support this operation",
"type":"UnsupportedOperationException",
"code":406
}
}Nested Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException
404 Response
Not Found - The namespace specified does not exist
Root Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException
Examples
409 Response
Conflict - The view already exists
Root Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException
Examples
419 Response
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.
Root Schema : IcebergErrorResponse
Type:
objectJSON wrapper for all error responses (non-2xx)
Show Source
-
error(required): object
ErrorModel
JSON error payload returned in a response with further details on the error
Example:
{
"error":{
"message":"The server does not support this operation",
"type":"UnsupportedOperationException",
"code":406
}
}Nested Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException
503 Response
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.
Root Schema : IcebergErrorResponse
Type:
objectJSON wrapper for all error responses (non-2xx)
Show Source
-
error(required): object
ErrorModel
JSON error payload returned in a response with further details on the error
Example:
{
"error":{
"message":"The server does not support this operation",
"type":"UnsupportedOperationException",
"code":406
}
}Nested Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException
5XX Response
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.
Root Schema : IcebergErrorResponse
Type:
objectJSON wrapper for all error responses (non-2xx)
Show Source
-
error(required): object
ErrorModel
JSON error payload returned in a response with further details on the error
Example:
{
"error":{
"message":"The server does not support this operation",
"type":"UnsupportedOperationException",
"code":406
}
}Nested Schema : ErrorModel
Type:
objectJSON error payload returned in a response with further details on the error
Show Source
-
code(required): integer
Minimum Value:
400Maximum Value:600HTTP response codeExample:404 -
message(required): string
Human-readable error message
-
stack: array
stack
-
type(required): string
Internal type definition of the errorExample:
NoSuchNamespaceException