/**
 * Contentful Space API. Contains methods to access any operations at a space
 * level, such as creating and reading entities contained in a space.
 */
import type { MakeRequest, PaginationQueryOptions, QueryOptions } from './common-types';
import type { CreateApiKeyProps } from './entities/api-key';
import type { CreateEnvironmentProps } from './entities/environment';
import type { CreateEnvironmentAliasProps } from './entities/environment-alias';
import type { CreateRoleProps, RoleProps } from './entities/role';
import type { ScheduledActionProps, ScheduledActionQueryOptions } from './entities/scheduled-action';
import type { UpdateSpaceAddOnAllocationProps } from './entities/space-add-on';
import type { CreateSpaceMembershipProps } from './entities/space-membership';
import type { CreateTeamSpaceMembershipProps } from './entities/team-space-membership';
import type { CreateWebhooksProps, UpsertWebhookSigningSecretPayload, WebhookRetryPolicyPayload } from './entities/webhook';
import type { AiActionProps, AiActionQueryOptions, CreateAiActionProps } from './entities/ai-action';
/**
 * @internal
 */
export type ContentfulSpaceAPI = ReturnType<typeof createSpaceApi>;
/**
 * Creates API object with methods to access the Space API
 * @param {MakeRequest} makeRequest - function to make requests via an adapter
 * @returns {ContentfulSpaceAPI}
 * @internal
 */
export default function createSpaceApi(makeRequest: MakeRequest): {
    /**
     * Deletes the space
     * @returns Promise for the deletion. It contains no data, but the Promise error case should be handled.
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     *   .then((space) => space.delete())
     *   .then(() => console.log('Space deleted.'))
     *   .catch(console.error)
     * ```
     */
    delete: () => Promise<void>;
    /**
     * Updates the space
     * @returns Promise for the updated space.
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => {
     *   space.name = 'New name'
     *   return space.update()
     * })
     * .then((space) => console.log(`Space ${space.sys.id} renamed.`)
     * .catch(console.error)
     * ```
     */
    update: () => Promise<import("./export-types").Space>;
    /**
     * Unarchives the space
     * @returns Promise for the unarchived space.
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => {
     *   return space.unarchive({productId: 'id'})
     * })
     * .then((space) => console.log(`Space ${space.sys.id} unarchived.`)
     * .catch(console.error)
     * ```
     */
    unarchive: (productId: string) => Promise<import("./export-types").Space>;
    /**
     * Gets an environment
     * @param id - Environment ID
     * @returns Promise for an Environment
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getEnvironment('<environment_id>'))
     * .then((environment) => console.log(environment))
     * .catch(console.error)
     * ```
     */
    getEnvironment(environmentId: string): Promise<import("./export-types").Environment>;
    /**
     * Gets a collection of Environments
     * @returns Promise for a collection of Environment
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getEnvironments())
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getEnvironments(query?: PaginationQueryOptions): Promise<import("./common-types").Collection<import("./export-types").Environment, import("./export-types").EnvironmentProps>>;
    /**
     * Creates an environment
     * @param data - Object representation of the Environment to be created
     * @returns Promise for the newly created Environment
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createEnvironment({ name: 'Staging' }))
     * .then((environment) => console.log(environment))
     * .catch(console.error)
     * ```
     */
    createEnvironment(data?: CreateEnvironmentProps): Promise<import("./export-types").Environment>;
    /**
     * Creates an Environment with a custom ID
     * @param id - Environment ID
     * @param data - Object representation of the Environment to be created
     * @param sourceEnvironmentId - ID of the source environment that will be copied to create the new environment. Default is "master"
     * @returns Promise for the newly created Environment
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createEnvironmentWithId('<environment-id>', { name: 'Staging'}, 'master'))
     * .then((environment) => console.log(environment))
     * .catch(console.error)
     * ```
     */
    createEnvironmentWithId(id: string, data: CreateEnvironmentProps, sourceEnvironmentId?: string): Promise<import("./export-types").Environment>;
    /**
     * Gets a Webhook
     * @param id - Webhook ID
     * @returns Promise for a Webhook
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getWebhook('<webhook_id>'))
     * .then((webhook) => console.log(webhook))
     * .catch(console.error)
     * ```
     */
    getWebhook(id: string): Promise<import("./export-types").WebHooks>;
    /**
     * Gets a collection of Webhooks
     * @returns Promise for a collection of Webhooks
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getWebhooks())
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getWebhooks(): Promise<import("./common-types").Collection<import("./export-types").WebHooks, import("./export-types").WebhookProps>>;
    /**
     * Fetch a webhook signing secret
     * @returns Promise for the redacted webhook signing secret in this space
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     *   .then((space) => space.getWebhookSigningSecret())
     *   .then((response) => console.log(response.redactedValue))
     *   .catch(console.error)
     * ```
     */
    getWebhookSigningSecret: () => Promise<import("./export-types").WebhookSigningSecretProps>;
    /**
     * Fetch a webhook retry policy
     * @returns Promise for the redacted webhook retry policy in this space
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     *   .then((space) => space.getRetryPolicy())
     *   .then((response) => console.log(response.redactedValue))
     *   .catch(console.error)
     * ```
     */
    getWebhookRetryPolicy: () => Promise<import("./entities/webhook").WebhookRetryPolicyProps>;
    /**
     * Creates a Webhook
     * @param data - Object representation of the Webhook to be created
     * @returns Promise for the newly created Webhook
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createWebhook({
     *   'name': 'My webhook',
     *   'url': 'https://www.example.com/test',
     *   'topics': [
     *     'Entry.create',
     *     'ContentType.create',
     *     '*.publish',
     *     'Asset.*'
     *   ]
     * }))
     * .then((webhook) => console.log(webhook))
     * .catch(console.error)
     * ```
     */
    createWebhook(data: CreateWebhooksProps): Promise<import("./export-types").WebHooks>;
    /**
     * Creates a Webhook with a custom ID
     * @param id - Webhook ID
     * @param  data - Object representation of the Webhook to be created
     * @returns Promise for the newly created Webhook
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createWebhookWithId('<webhook_id>', {
     *   'name': 'My webhook',
     *   'url': 'https://www.example.com/test',
     *   'topics': [
     *     'Entry.create',
     *     'ContentType.create',
     *     '*.publish',
     *     'Asset.*'
     *   ]
     * }))
     * .then((webhook) => console.log(webhook))
     * .catch(console.error)
     * ```
     */
    createWebhookWithId(id: string, data: CreateWebhooksProps): Promise<import("./export-types").WebHooks>;
    /**
     * Create or update the webhook signing secret for this space
     * @param data 64 character string that will be used to sign the webhook calls
     * @returns Promise for the redacted webhook signing secret that was created or updated
     * @example ```javascript
     * const contentful = require('contentful-management')
     * const crypto = require('crypto')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * const signingSecret = client.getSpace('<space_id>')
     *   .then((space) => space.upsertWebhookSigningSecret({
     *     value: crypto.randomBytes(32).toString('hex')
     *   }))
     *   .then((response) => console.log(response.redactedValue))
     *   .catch(console.error)
     * ```
     */
    upsertWebhookSigningSecret: (data: UpsertWebhookSigningSecretPayload) => Promise<import("./export-types").WebhookSigningSecretProps>;
    /**
     * Create or update the webhook retry policy for this space
     * @param data the maxRetries with integer value >= 2 and <= 99 value to set in the Retry Policy
     * @returns Promise for the redacted webhook retry policy that was created or updated
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * const retryPolicy = client.getSpace('<space_id>')
     *   .then((space) => space.upsertWebhookRetryPolicy({
     *     maxRetries: 15
     *   }))
     *   .then((response) => console.log(response.redactedValue))
     *   .catch(console.error)
     * ```
     */
    upsertWebhookRetryPolicy: (data: WebhookRetryPolicyPayload) => Promise<import("./entities/webhook").WebhookRetryPolicyProps>;
    /**
     * Delete the webhook signing secret for this space
     * @returns Promise<void>
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     *   .then((space) => space.deleteWebhookSigningSecret())
     *   .then(() => console.log("success"))
     *   .catch(console.error)
     * ```
     */
    deleteWebhookSigningSecret: () => Promise<void>;
    /**
     * Delete the webhook retry policy for this space
     * @returns Promise<void>
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     *   .then((space) => space.deleteWebhookRetryPolicy())
     *   .then(() => console.log("success"))
     *   .catch(console.error)
     * ```
     */
    deleteWebhookRetryPolicy: () => Promise<void>;
    /**
     * Gets a Role
     * @param id - Role ID
     * @returns Promise for a Role
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createRole({
     *   fields: {
     *     title: {
     *       'en-US': 'Role title'
     *     }
     *   }
     * }))
     * .then((role) => console.log(role))
     * .catch(console.error)
     * ```
     */
    getRole(id: string): Promise<import("./export-types").Role>;
    /**
     * Gets a collection of Roles
     * @returns Promise for a collection of Roles
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getRoles())
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getRoles(query?: QueryOptions): Promise<import("./common-types").Collection<import("./export-types").Role, RoleProps>>;
    /**
     * Creates a Role
     * @param data - Object representation of the Role to be created
     * @returns  Promise for the newly created Role
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     * client.getSpace('<space_id>')
     * .then((space) => space.createRole({
     *   name: 'My Role',
     *   description: 'foobar role',
     *   permissions: {
     *     ContentDelivery: 'all',
     *     ContentModel: ['read'],
     *     Settings: []
     *   },
     *   policies: [
     *     {
     *       effect: 'allow',
     *       actions: 'all',
     *       constraint: {
     *         and: [
     *           {
     *             equals: [
     *               { doc: 'sys.type' },
     *               'Entry'
     *             ]
     *           },
     *           {
     *             equals: [
     *               { doc: 'sys.type' },
     *               'Asset'
     *             ]
     *           }
     *         ]
     *       }
     *     }
     *   ]
     * }))
     * .then((role) => console.log(role))
     * .catch(console.error)
     * ```
     */
    createRole(data: CreateRoleProps): Promise<import("./export-types").Role>;
    /**
     * Creates a Role with a custom ID
     * @param id - Role ID
     * @param data - Object representation of the Role to be created
     * @returns Promise for the newly created Role
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     * client.getSpace('<space_id>')
     * .then((space) => space.createRoleWithId('<role-id>', {
     *   name: 'My Role',
     *   description: 'foobar role',
     *   permissions: {
     *     ContentDelivery: 'all',
     *     ContentModel: ['read'],
     *     Settings: []
     *   },
     *   policies: [
     *     {
     *       effect: 'allow',
     *       actions: 'all',
     *       constraint: {
     *         and: [
     *           {
     *             equals: [
     *               { doc: 'sys.type' },
     *               'Entry'
     *             ]
     *           },
     *           {
     *             equals: [
     *               { doc: 'sys.type' },
     *               'Asset'
     *             ]
     *           }
     *         ]
     *       }
     *     }
     *   ]
     * }))
     * .then((role) => console.log(role))
     * .catch(console.error)
     * ```
     */
    createRoleWithId(id: string, roleData: Omit<RoleProps, "sys">): Promise<import("./export-types").Role>;
    /**
     * Gets a User
     * @param userId - User ID
     * @returns Promise for a User
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getSpaceUser('id'))
     * .then((user) => console.log(user))
     * .catch(console.error)
     * ```
     */
    getSpaceUser(userId: string): Promise<import("./export-types").UserProps & {
        toPlainObject(): import("./export-types").UserProps;
    }>;
    /**
     * Gets a collection of Users in a space
     * @param query - Object with search parameters. Check the <a href="https://www.contentful.com/developers/docs/javascript/tutorials/using-js-cda-sdk/#retrieving-entries-with-search-parameters">JS SDK tutorial</a> and the <a href="https://www.contentful.com/developers/docs/references/content-delivery-api/#/reference/search-parameters">REST API reference</a> for more details.
     * @returns Promise a collection of Users in a space
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getSpaceUsers(query))
     * .then((data) => console.log(data))
     * .catch(console.error)
     * ```
     */
    getSpaceUsers(query?: QueryOptions): Promise<import("./common-types").Collection<import("./export-types").UserProps & {
        toPlainObject(): import("./export-types").UserProps;
    }, import("./export-types").UserProps>>;
    /**
     * Gets a collection of teams for a space
     * @param query
     * @returns Promise for a collection of teams for a space
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getTeams())
     * .then((teamsCollection) => console.log(teamsCollection))
     * .catch(console.error)
     * ```
     */
    getTeams(query?: QueryOptions): Promise<import("./common-types").Collection<import("./export-types").Team, import("./export-types").TeamProps>>;
    /**
     * Gets a Space Member
     * @param id Get Space Member by user_id
     * @returns Promise for a Space Member
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getSpaceMember(id))
     * .then((spaceMember) => console.log(spaceMember))
     * .catch(console.error)
     * ```
     */
    getSpaceMember(id: string): Promise<import("./export-types").SpaceMemberProps & {
        toPlainObject(): import("./export-types").SpaceMemberProps;
    }>;
    /**
     * Gets a collection of Space Members
     * @param query
     * @returns Promise for a collection of Space Members
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getSpaceMembers({'limit': 100}))
     * .then((spaceMemberCollection) => console.log(spaceMemberCollection))
     * .catch(console.error)
     * ```
     */
    getSpaceMembers(query?: QueryOptions): Promise<import("./common-types").Collection<import("./export-types").SpaceMemberProps & {
        toPlainObject(): import("./export-types").SpaceMemberProps;
    }, import("./export-types").SpaceMemberProps>>;
    /**
     * Gets a Space Membership
     * Warning: the user attribute in the space membership root is deprecated. The attribute has been moved inside the sys  object (i.e. sys.user).
     * @param id - Space Membership ID
     * @returns Promise for a Space Membership
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getSpaceMembership('id'))
     * .then((spaceMembership) => console.log(spaceMembership))
     * .catch(console.error)
     * ```
     */
    getSpaceMembership(id: string): Promise<import("./export-types").SpaceMembership>;
    /**
     * Gets a collection of Space Memberships
     * Warning: the user attribute in the space membership root is deprecated. The attribute has been moved inside the sys  object (i.e. sys.user).
     * @param query - Object with search parameters. Check the <a href="https://www.contentful.com/developers/docs/javascript/tutorials/using-js-cda-sdk/#retrieving-entries-with-search-parameters">JS SDK tutorial</a> and the <a href="https://www.contentful.com/developers/docs/references/content-delivery-api/#/reference/search-parameters">REST API reference</a> for more details.
     * @returns Promise for a collection of Space Memberships
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getSpaceMemberships({'limit': 100})) // you can add more queries as 'key': 'value'
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getSpaceMemberships(query?: QueryOptions): Promise<import("./common-types").Collection<import("./export-types").SpaceMembership, import("./export-types").SpaceMembershipProps>>;
    /**
     * Creates a Space Membership
     * Warning: the user attribute in the space membership root is deprecated. The attribute has been moved inside the sys  object (i.e. sys.user).
     * @param  data - Object representation of the Space Membership to be created
     * @returns Promise for the newly created Space Membership
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createSpaceMembership({
     *   admin: false,
     *   roles: [
     *     {
     *       type: 'Link',
     *       linkType: 'Role',
     *       id: '<role_id>'
     *     }
     *   ],
     *   email: 'foo@example.com'
     * }))
     * .then((spaceMembership) => console.log(spaceMembership))
     * .catch(console.error)
     * ```
     */
    createSpaceMembership(data: CreateSpaceMembershipProps): Promise<import("./export-types").SpaceMembership>;
    /**
     * Creates a Space Membership with a custom ID
     * Warning: the user attribute in the space membership root is deprecated. The attribute has been moved inside the sys  object (i.e. sys.user).
     * @param id - Space Membership ID
     * @param data - Object representation of the Space Membership to be created
     * @returns Promise for the newly created Space Membership
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createSpaceMembershipWithId('<space-membership-id>', {
     *   admin: false,
     *   roles: [
     *     {
     *       type: 'Link',
     *       linkType: 'Role',
     *       id: '<role_id>'
     *     }
     *   ],
     *   email: 'foo@example.com'
     * }))
     * .then((spaceMembership) => console.log(spaceMembership))
     * .catch(console.error)
     * ```
     */
    createSpaceMembershipWithId(id: string, data: CreateSpaceMembershipProps): Promise<import("./export-types").SpaceMembership>;
    /**
     * Gets a Team Space Membership
     * @param id - Team Space Membership ID
     * @returns Promise for a Team Space Membership
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getTeamSpaceMembership('team_space_membership_id'))
     * .then((teamSpaceMembership) => console.log(teamSpaceMembership))
     * .catch(console.error)
     * ```
     */
    getTeamSpaceMembership(teamSpaceMembershipId: string): Promise<import("./export-types").TeamSpaceMembership>;
    /**
     * Gets a collection of Team Space Memberships
     * @param query - Object with search parameters. Check the <a href="https://www.contentful.com/developers/docs/javascript/tutorials/using-js-cda-sdk/#retrieving-entries-with-search-parameters">JS SDK tutorial</a> and the <a href="https://www.contentful.com/developers/docs/references/content-delivery-api/#/reference/search-parameters">REST API reference</a> for more details.
     * @returns Promise for a collection of Team Space Memberships
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getTeamSpaceMemberships())
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getTeamSpaceMemberships(query?: QueryOptions): Promise<import("./common-types").Collection<import("./export-types").TeamSpaceMembership, import("./export-types").TeamSpaceMembershipProps>>;
    /**
   * Creates a Team Space Membership
   * @param id - Team ID
   * @param data - Object representation of the Team Space Membership to be created
   * @returns Promise for the newly created Team Space Membership
   * @example ```javascript
   * const contentful = require('contentful-management')
   *
   * const client = contentful.createClient({
   *   accessToken: '<content_management_api_key>'
   * })
   *
   * client.getSpace('<space_id>')
   * .then((space) => space.createTeamSpaceMembership('team_id', {
   *   admin: false,
   *   roles: [
   *    {
          sys: {
   *       type: 'Link',
   *       linkType: 'Role',
   *       id: '<role_id>'
   *      }
   *    }
   *   ],
   * }))
   * .then((teamSpaceMembership) => console.log(teamSpaceMembership))
   * .catch(console.error)
   * ```
   */
    createTeamSpaceMembership(teamId: string, data: CreateTeamSpaceMembershipProps): Promise<import("./export-types").TeamSpaceMembership>;
    /**
     * Gets a Api Key
     * @param id - API Key ID
     * @returns  Promise for a Api Key
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getApiKey('<apikey-id>'))
     * .then((apikey) => console.log(apikey))
     * .catch(console.error)
     * ```
     */
    getApiKey(id: string): Promise<import("./export-types").ApiKey>;
    /**
     * Gets a collection of Api Keys
     * @returns Promise for a collection of Api Keys
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getApiKeys())
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getApiKeys(): Promise<import("./common-types").Collection<import("./export-types").ApiKey, import("./export-types").ApiKeyProps>>;
    /**
     * Gets a collection of preview Api Keys
     * @returns Promise for a collection of Preview Api Keys
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getPreviewApiKeys())
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getPreviewApiKeys(): Promise<import("./common-types").Collection<import("./export-types").PreviewApiKey, import("./export-types").PreviewApiKeyProps>>;
    /**
     * Gets a preview Api Key
     * @param id - Preview API Key ID
     * @returns  Promise for a Preview Api Key
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getPreviewApiKey('<preview-apikey-id>'))
     * .then((previewApikey) => console.log(previewApikey))
     * .catch(console.error)
     * ```
     */
    getPreviewApiKey(id: string): Promise<import("./export-types").PreviewApiKey>;
    /**
     * Creates a Api Key
     * @param payload - Object representation of the Api Key to be created
     * @returns Promise for the newly created Api Key
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createApiKey({
     *   name: 'API Key name',
     *   environments:[
     *    {
     *     sys: {
     *      type: 'Link'
     *      linkType: 'Environment',
     *      id:'<environment_id>'
     *     }
     *    }
     *   ]
     *   }
     * }))
     * .then((apiKey) => console.log(apiKey))
     * .catch(console.error)
     * ```
     */
    createApiKey: (payload: CreateApiKeyProps) => Promise<import("./export-types").ApiKey>;
    /**
     * Creates a Api Key with a custom ID
     * @param id - Api Key ID
     * @param payload - Object representation of the Api Key to be created
     * @returns Promise for the newly created Api Key
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createApiKeyWithId('<api-key-id>', {
     *   name: 'API Key name'
     *   environments:[
     *    {
     *     sys: {
     *      type: 'Link'
     *      linkType: 'Environment',
     *      id:'<environment_id>'
     *     }
     *    }
     *   ]
     *   }
     * }))
     * .then((apiKey) => console.log(apiKey))
     * .catch(console.error)
     * ```
     */
    createApiKeyWithId(id: string, payload: CreateApiKeyProps): Promise<import("./export-types").ApiKey>;
    /**
     * Creates an EnvironmentAlias with a custom ID
     * @param environmentAliasId - EnvironmentAlias ID
     * @param data - Object representation of the EnvironmentAlias to be created
     * @returns Promise for the newly created EnvironmentAlias
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.createEnvironmentAliasWithId('<environment-alias-id>', {
     *   environment: {
     *     sys: { type: 'Link', linkType: 'Environment', id: 'targetEnvironment' }
     *   }
     * }))
     * .then((environmentAlias) => console.log(environmentAlias))
     * .catch(console.error)
     * ```
     */
    createEnvironmentAliasWithId(environmentAliasId: string, data: CreateEnvironmentAliasProps): Promise<import("./export-types").EnvironmentAlias>;
    /**
     * Gets an Environment Alias
     * @param Environment Alias ID
     * @returns Promise for an Environment Alias
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getEnvironmentAlias('<alias-id>'))
     * .then((alias) => console.log(alias))
     * .catch(console.error)
     * ```
     */
    getEnvironmentAlias(environmentAliasId: string): Promise<import("./export-types").EnvironmentAlias>;
    /**
     * Gets a collection of Environment Aliases
     * @returns Promise for a collection of Environment Aliases
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getEnvironmentAliases()
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getEnvironmentAliases(): Promise<import("./common-types").Collection<import("./export-types").EnvironmentAlias, import("./export-types").EnvironmentAliasProps>>;
    /**
     * Query for scheduled actions in space.
     * @param query - Object with search parameters. The enviroment id field is mandatory. Check the <a href="https://www.contentful.com/developers/docs/references/content-management-api/#/reference/scheduled-actions/scheduled-actions-collection">REST API reference</a> for more details.
     * @returns Promise for the scheduled actions query
     *
     * @example ```javascript
     *  const contentful = require('contentful-management');
     *
     *  const client = contentful.createClient({
     *    accessToken: '<content_management_api_key>'
     *  })
     *
     *  client.getSpace('<space_id>')
     *    .then((space) => space.getScheduledActions({
     *      'environment.sys.id': '<environment_id>',
     *      'sys.status': 'scheduled'
     *    }))
     *    .then((scheduledActionCollection) => console.log(scheduledActionCollection.items))
     *    .catch(console.error)
     * ```
     */
    getScheduledActions(query: ScheduledActionQueryOptions): Promise<import("./common-types").Collection<import("./export-types").ScheduledAction, ScheduledActionProps>>;
    /**
     * Get a Scheduled Action in the current space by environment and ID.
     *
     * @throws if the Scheduled Action cannot be found or the user doesn't have permission to read schedules from the entity of the scheduled action itself.
     * @returns Promise with the Scheduled Action
     * @example ```javascript
     *  const contentful = require('contentful-management');
     *
     *  const client = contentful.createClient({
     *    accessToken: '<content_management_api_key>'
     *  })
     *
     *  client.getSpace('<space_id>')
     *    .then((space) => space.getScheduledAction({
     *      scheduledActionId: '<scheduled-action-id>',
     *      environmentId: '<environmentId>'
     *    }))
     *    .then((scheduledAction) => console.log(scheduledAction))
     *    .catch(console.error)
     * ```
     */
    getScheduledAction({ scheduledActionId, environmentId, }: {
        scheduledActionId: string;
        environmentId: string;
    }): Promise<import("./export-types").ScheduledAction>;
    /**
     * Creates a scheduled action
     * @param data - Object representation of the scheduled action to be created
     * @returns Promise for the newly created scheduled actions
     * @example ```javascript
     *  const contentful = require('contentful-management');
     *
     *  const client = contentful.createClient({
     *    accessToken: '<content_management_api_key>'
     *  })
     *
     *  client.getSpace('<space_id>')
     *    .then((space) => space.createScheduledAction({
     *      entity: {
     *        sys: {
     *          type: 'Link',
     *          linkType: 'Entry',
     *          id: '<entry_id>'
     *        }
     *      },
     *      environment: {
     *        sys: {
     *          type: 'Link',
     *          linkType: 'Environment',
     *          id: '<environment_id>'
     *        }
     *      },
     *      action: 'publish',
     *      scheduledFor: {
     *        datetime: <ISO_date_string>,
     *        timezone: 'Europe/Berlin'
     *      }
     *    }))
     *    .then((scheduledAction) => console.log(scheduledAction))
     *    .catch(console.error)
     * ```
     */
    createScheduledAction(data: Omit<ScheduledActionProps, "sys">): Promise<import("./export-types").ScheduledAction>;
    /**
     * Update a scheduled action
     * @param {object} options
     * @param options.scheduledActionId the id of the scheduled action to update
     * @param options.version the sys.version of the scheduled action to be updated
     * @param payload the scheduled actions object with updates, omitting sys object
     * @returns Promise containing a wrapped scheduled action with helper methods
     * @example ```javascript
     *  const contentful = require('contentful-management');
     *
     *  const client = contentful.createClient({
     *    accessToken: '<content_management_api_key>'
     *  })
     *
     *  client.getSpace('<space_id>')
     *    .then((space) => {
     *      return space.createScheduledAction({
     *        entity: {
     *          sys: {
     *            type: 'Link',
     *            linkType: 'Entry',
     *            id: '<entry_id>'
     *          }
     *        },
     *        environment: {
     *          sys: {
     *            type: 'Link',
     *            linkType: 'Environment',
     *            id: '<environment_id>'
     *          }
     *        },
     *        action: 'publish',
     *        scheduledFor: {
     *          datetime: <ISO_date_string>,
     *          timezone: 'Europe/Berlin'
     *        }
     *      })
     *      .then((scheduledAction) => {
     *        const { _sys, ...payload } = scheduledAction;
     *        return space.updateScheduledAction({
     *          ...payload,
     *          scheduledFor: {
     *            ...payload.scheduledFor,
     *            timezone: 'Europe/Paris'
     *          }
     *        })
     *      })
     *    .then((scheduledAction) => console.log(scheduledAction))
     *    .catch(console.error);
     * ```
     */
    updateScheduledAction({ scheduledActionId, payload, version, }: {
        scheduledActionId: string;
        payload: Omit<ScheduledActionProps, "sys">;
        version: number;
    }): Promise<import("./export-types").ScheduledAction>;
    /**
     * Cancels a Scheduled Action.
     * Only cancels actions that have not yet executed.
     *
     * @param {object} options
     * @param options.scheduledActionId the id of the scheduled action to be canceled
     * @param options.environmentId the environment ID of the scheduled action to be canceled
     * @throws if the Scheduled Action cannot be found or the user doesn't have permissions in the entity in the action.
     * @returns Promise containing a wrapped Scheduled Action with helper methods
     * @example ```javascript
     *  const contentful = require('contentful-management');
     *
     *  const client = contentful.createClient({
     *    accessToken: '<content_management_api_key>'
     *  })
     *
     *  // Given that an Scheduled Action is scheduled
     *  client.getSpace('<space_id>')
     *    .then((space) => space.deleteScheduledAction({
     *        environmentId: '<environment-id>',
     *        scheduledActionId: '<scheduled-action-id>'
     *     }))
     *     // The scheduled Action sys.status is now 'canceled'
     *    .then((scheduledAction) => console.log(scheduledAction))
     *    .catch(console.error);
     * ```
     */
    deleteScheduledAction({ scheduledActionId, environmentId, }: {
        scheduledActionId: string;
        environmentId: string;
    }): Promise<import("./export-types").ScheduledAction>;
    /**
     * Gets a single AI Action.
     * @param aiActionId - AI Action ID
     * @returns Promise for an AI Action
     * @example
     * ```javascript
     * client.getSpace('<space_id>')
     *   .then((space) => space.getAiAction('<ai_action_id>'))
     *   .then((aiAction) => console.log(aiAction))
     *   .catch(console.error)
     * ```
     */
    getAiAction(aiActionId: string): Promise<import("./export-types").AiAction>;
    /**
     * Gets a collection of AI Actions.
     * @param query - Object with search parameters.
     * @returns Promise for a collection of AI Actions
     * @example
     * ```javascript
     * client.getSpace('<space_id>')
     *   .then((space) => space.getAiActions({ limit: 10 }))
     *   .then((response) => console.log(response.items))
     *   .catch(console.error)
     * ```
     */
    getAiActions(query?: AiActionQueryOptions): Promise<import("./common-types").Collection<import("./export-types").AiAction, AiActionProps>>;
    /**
     * Creates an AI Action.
     * @param data - Object representation of the AI Action to be created
     * @returns Promise for the newly created AI Action
     * @example
     * ```javascript
     * client.getSpace('<space_id>')
     *   .then((space) => space.createAiAction({
     *     name: 'My AI Action',
     *     description: 'Description here',
     *     configuration: { modelType: 'model-x', modelTemperature: 0.7 },
     *     instruction: { template: 'Do something: {{var.input}}', variables: [], conditions: [] },
     *     testCases: []
     *   }))
     *   .then((aiAction) => console.log(aiAction))
     *   .catch(console.error)
     * ```
     */
    createAiAction(data: CreateAiActionProps): Promise<import("./export-types").AiAction>;
    /**
     * Updates an AI Action.
     * @param aiActionId - AI Action ID
     * @param data - Object representation of the AI Action update
     * @returns Promise for the updated AI Action
     * @example
     * ```javascript
     * client.getSpace('<space_id>')
     *   .then((space) => space.updateAiAction('<ai_action_id>', { name: 'New Name', ... }))
     *   .then((aiAction) => console.log(aiAction))
     *   .catch(console.error)
     * ```
     */
    updateAiAction(aiActionId: string, data: AiActionProps): Promise<import("./export-types").AiAction>;
    /**
     * Publishes an AI Action.
     * @param aiActionId - AI Action ID
     * @param data - Object representation of the AI Action to be published
     * @returns Promise for the published AI Action
     * @example
     * ```javascript
     * client.getSpace('<space_id>')
     *   .then((space) => space.publishAiAction('<ai_action_id>', { ... }))
     *   .then((aiAction) => console.log(aiAction))
     *   .catch(console.error)
     * ```
     */
    publishAiAction(aiActionId: string, { version }: {
        version: number;
    }): Promise<import("./export-types").AiAction>;
    /**
     * Unpublishes an AI Action.
     * @param aiActionId - AI Action ID
     * @returns Promise for the unpublished AI Action
     * @example
     * ```javascript
     * client.getSpace('<space_id>')
     *   .then((space) => space.unpublishAiAction('<ai_action_id>'))
     *   .then((aiAction) => console.log(aiAction))
     *   .catch(console.error)
     * ```
     */
    unpublishAiAction(aiActionId: string): Promise<import("./export-types").AiAction>;
    /**
     * Deletes an AI Action.
     * @param aiActionId - AI Action ID
     * @returns Promise for deletion (void)
     * @example
     * ```javascript
     * client.getSpace('<space_id>')
     *   .then((space) => space.deleteAiAction('<ai_action_id>'))
     *   .then(() => console.log('AI Action deleted'))
     *   .catch(console.error)
     * ```
     */
    deleteAiAction(aiActionId: string): Promise<any>;
    /**
     * Gets a collection of Space Add-ons
     * @param query - Object with search parameters (skip, limit)
     * @returns Promise for a collection of Space Add-ons
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getSpaceAddOns())
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getSpaceAddOns(query?: QueryOptions): Promise<import("./common-types").Collection<import("./export-types").SpaceAddOn, import("./export-types").SpaceAddOnProps>>;
    /**
     * Gets a collection of Eligible Licenses for the space
     * @param query - Object with search parameters. The API supports pagination with skip and limit parameters.
     * @returns Promise for a collection of Eligible Licenses that can be assigned to this space
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.getEligibleLicenses({ limit: 10, skip: 0 }))
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    getEligibleLicenses(query?: QueryOptions): Promise<import("./common-types").Collection<import("./entities/eligible-license").EligibleLicense, import("./entities/eligible-license").EligibleLicenseProps>>;
    /**
     * Updates Space Add-on allocations
     * @param allocations - Array of add-on allocation updates
     * @returns Promise for the updated collection of Space Add-ons
     * @example ```javascript
     * const contentful = require('contentful-management')
     *
     * const client = contentful.createClient({
     *   accessToken: '<content_management_api_key>'
     * })
     *
     * client.getSpace('<space_id>')
     * .then((space) => space.updateSpaceAddOnAllocations([
     *   { add_on: 'contentTypes', allocation: 10 },
     *   { add_on: 'records', allocation: 1000 }
     * ]))
     * .then((response) => console.log(response.items))
     * .catch(console.error)
     * ```
     */
    updateSpaceAddOnAllocations(allocations: UpdateSpaceAddOnAllocationProps[]): Promise<import("./common-types").Collection<import("./export-types").SpaceAddOn, import("./export-types").SpaceAddOnProps>>;
};
