CreateApiKeyReqPayload: {
    dataset_ids?: string[] | null;
    default_params?: ApiKeyRequestParams | null;
    expires_at?: string | null;
    name: string;
    role: number;
    scopes?: string[] | null;
}

Type declaration

  • Optionaldataset_ids?: string[] | null

    The dataset ids which the api key will have access to. If not provided or empty, the api key will have access to all datasets in the dataset.

  • Optionaldefault_params?: ApiKeyRequestParams | null
  • Optionalexpires_at?: string | null

    The expiration date of the api key. If not provided, the api key will not expire. This should be provided in UTC time.

  • name: string

    The name which will be assigned to the new api key.

  • role: number

    The role which will be assigned to the new api key. Either 0 (read), 1 (Admin) or 2 (Owner). The auth'ed user must have a role greater than or equal to the role being assigned.

  • Optionalscopes?: string[] | null

    The routes which the api key will have access to. If not provided or empty, the api key will have access to all routes. Specify the routes as a list of strings. For example, ["GET /api/dataset", "POST /api/dataset"].