UNPKG

@datocms/cma-client

Version:
219 lines (218 loc) 8.83 kB
import BaseResource from '../../BaseResource'; import type * as SchemaTypes from '../SchemaTypes'; import type * as SimpleSchemaTypes from '../SimpleSchemaTypes'; export default class Site extends BaseResource { static readonly TYPE: "site"; /** * Retrieve the site * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/self * * @throws {ApiError} * @throws {TimeoutError} */ find(queryParams?: SimpleSchemaTypes.SiteSelfHrefSchema): Promise<SimpleSchemaTypes.Site>; /** * Retrieve the site * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/self * * @throws {ApiError} * @throws {TimeoutError} */ rawFind(queryParams?: SchemaTypes.SiteSelfHrefSchema): Promise<SchemaTypes.SiteSelfTargetSchema>; /** * Update the site's settings * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/update * * @throws {ApiError} * @throws {TimeoutError} */ update(body: SimpleSchemaTypes.SiteUpdateSchema): Promise<SimpleSchemaTypes.Site>; /** * Update the site's settings * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/update * * @throws {ApiError} * @throws {TimeoutError} */ rawUpdate(body: SchemaTypes.SiteUpdateSchema): Promise<SchemaTypes.SiteUpdateJobSchema>; /** * Activate improved timezone management * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_timezone_management * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ activateImprovedTimezoneManagement(): Promise<SimpleSchemaTypes.Site>; /** * Activate improved timezone management * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_timezone_management * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawActivateImprovedTimezoneManagement(): Promise<SchemaTypes.SiteActivateImprovedTimezoneManagementJobSchema>; /** * Activate improved hex management * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_hex_management * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ activateImprovedHexManagement(): Promise<SimpleSchemaTypes.Site>; /** * Activate improved hex management * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_hex_management * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawActivateImprovedHexManagement(): Promise<SchemaTypes.SiteActivateImprovedHexManagementTargetSchema>; /** * Activate improved GraphQL multi-locale fields option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_gql_multilocale_fields * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ activateImprovedGqlMultilocaleFields(): Promise<SimpleSchemaTypes.Site>; /** * Activate improved GraphQL multi-locale fields option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_gql_multilocale_fields * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawActivateImprovedGqlMultilocaleFields(): Promise<SchemaTypes.SiteActivateImprovedGqlMultilocaleFieldsTargetSchema>; /** * Activate improved GraphQL visibility control option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_gql_visibility_control * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ activateImprovedGqlVisibilityControl(): Promise<SimpleSchemaTypes.Site>; /** * Activate improved GraphQL visibility control option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_gql_visibility_control * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawActivateImprovedGqlVisibilityControl(): Promise<SchemaTypes.SiteActivateImprovedGqlVisibilityControlTargetSchema>; /** * Activate improved Boolean fields option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_boolean_fields * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ activateImprovedBooleanFields(): Promise<SimpleSchemaTypes.Site>; /** * Activate improved Boolean fields option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_boolean_fields * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawActivateImprovedBooleanFields(): Promise<SchemaTypes.SiteActivateImprovedBooleanFieldsTargetSchema>; /** * Set draft mode default to true for all environment's models * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_draft_mode_as_default * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ activateDraftModeAsDefault(): Promise<SimpleSchemaTypes.Site>; /** * Set draft mode default to true for all environment's models * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_draft_mode_as_default * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawActivateDraftModeAsDefault(): Promise<SchemaTypes.SiteActivateDraftModeAsDefaultTargetSchema>; /** * Activate improved validation at publishing option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_validation_at_publishing * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ activateImprovedValidationAtPublishing(): Promise<SimpleSchemaTypes.Site>; /** * Activate improved validation at publishing option * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/activate_improved_validation_at_publishing * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawActivateImprovedValidationAtPublishing(): Promise<SchemaTypes.SiteActivateImprovedValidationAtPublishingTargetSchema>; /** * Update CDN settings default assets * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/update_assets_cdn_default_settings * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ updateAssetsCdnDefaultSettings(body: SimpleSchemaTypes.SiteUpdateAssetsCdnDefaultSettingsSchema): Promise<SimpleSchemaTypes.Site>; /** * Update CDN settings default assets * * Read more: https://www.datocms.com/docs/content-management-api/resources/site/update_assets_cdn_default_settings * * @throws {ApiError} * @throws {TimeoutError} * * @deprecated This API call is to be considered private and might change without notice */ rawUpdateAssetsCdnDefaultSettings(body: SchemaTypes.SiteUpdateAssetsCdnDefaultSettingsSchema): Promise<SchemaTypes.SiteUpdateAssetsCdnDefaultSettingsTargetSchema>; }