mutations

@nishans/endpoints / Exports / Mutations

Class: Mutations#

Hierarchy#

Index#

Constructors#

Properties#

Methods#

Constructors#

constructor#

+ new Mutations(__namedParameters: CtorArgs): Mutations

Parameters:#

NameType
__namedParametersCtorArgs

Returns: Mutations

Inherited from: Queries

Defined in: src/Mutations.ts:33

Properties#

cache#

• cache: ICache

Inherited from: Queries.cache

Defined in: src/Cache.ts:6


createTransaction#

• createTransaction: (operations: IOperation[]) => SaveTransactionParams

Defined in: src/Mutations.ts:33


headers#

• headers: { headers: { cookie: string ; x-notion-active-user-header: string } }

Type declaration:#

NameType
headers{ cookie: string ; x-notion-active-user-header: string }

Inherited from: Queries.headers

Defined in: src/Cache.ts:9


interval#

• interval: number

Inherited from: Queries.interval

Defined in: src/Cache.ts:8


shard_id#

• shard_id: number

Defined in: src/Mutations.ts:32


space_id#

• space_id: string

Defined in: src/Mutations.ts:31


token#

• token: string

Inherited from: Queries.token

Defined in: src/Cache.ts:7


user_id#

• user_id: string

Inherited from: Queries.user_id

Defined in: src/Cache.ts:15

Methods#

createSpace#

â–¸ createSpace(arg: CreateSpaceParams): Promise<CreateSpaceResult>

Parameters:#

NameType
argCreateSpaceParams

Returns: Promise<CreateSpaceResult>

Defined in: src/Mutations.ts:60


enqueueTask#

â–¸ enqueueTask(params: EnqueueTaskParams): Promise<EnqueueTaskResult>

Parameters:#

NameType
paramsEnqueueTaskParams

Returns: Promise<EnqueueTaskResult>

Defined in: src/Mutations.ts:68


findUser#

â–¸ findUser(params: FindUserParams): Promise<FindUserResult>

Parameters:#

NameType
paramsFindUserParams

Returns: Promise<FindUserResult>

Inherited from: Queries

Defined in: src/Queries.ts:111


getBacklinksForBlock#

â–¸ getBacklinksForBlock(params: GetBackLinksForBlockParams): Promise<GetBackLinksForBlockResult>

Parameters:#

NameType
paramsGetBackLinksForBlockParams

Returns: Promise<GetBackLinksForBlockResult>

Inherited from: Queries

Defined in: src/Queries.ts:105


getConfigs#

â–¸ getConfigs(): Configs

Returns: Configs

Inherited from: Queries

Defined in: src/Cache.ts:39


getGenericEmbedBlockData#

â–¸ getGenericEmbedBlockData(arg: GetGenericEmbedBlockDataParams): Promise<GetGenericEmbedBlockDataResult>

Parameters:#

NameType
argGetGenericEmbedBlockDataParams

Returns: Promise<GetGenericEmbedBlockDataResult>

Inherited from: Queries

Defined in: src/Queries.ts:93


getGoogleDriveAccounts#

â–¸ getGoogleDriveAccounts(): Promise<GetGoogleDriveAccountsResult>

Returns: Promise<GetGoogleDriveAccountsResult>

Inherited from: Queries

Defined in: src/Queries.ts:101


getJoinableSpaces#

â–¸ getJoinableSpaces(): Promise<GetJoinableSpacesResult>

Returns: Promise<GetJoinableSpacesResult>

Inherited from: Queries

Defined in: src/Queries.ts:139


getPageVisits#

â–¸ getPageVisits(arg: GetPageVisitsParams): Promise<GetPageVisitsResult>

Parameters:#

NameType
argGetPageVisitsParams

Returns: Promise<GetPageVisitsResult>

Inherited from: Queries

Defined in: src/Queries.ts:57


getPublicPageData#

â–¸ getPublicPageData(arg: GetPublicPageDataParams): Promise<GetPublicPageDataResult>

Parameters:#

NameType
argGetPublicPageDataParams

Returns: Promise<GetPublicPageDataResult>

Inherited from: Queries

Defined in: src/Queries.ts:69


getPublicSpaceData#

â–¸ getPublicSpaceData(arg: GetPublicSpaceDataParams): Promise<GetPublicSpaceDataResult>

Parameters:#

NameType
argGetPublicSpaceDataParams

Returns: Promise<GetPublicSpaceDataResult>

Inherited from: Queries

Defined in: src/Queries.ts:73


getSpaces#

â–¸ getSpaces(): Promise<GetSpacesResult>

Returns: Promise<GetSpacesResult>

Inherited from: Queries

Defined in: src/Queries.ts:87


getSubscriptionData#

â–¸ getSubscriptionData(arg: GetSubscriptionDataParams): Promise<GetSubscriptionDataResult>

Parameters:#

NameType
argGetSubscriptionDataParams

Returns: Promise<GetSubscriptionDataResult>

Inherited from: Queries

Defined in: src/Queries.ts:77


getTasks#

â–¸ getTasks(params: GetTasksParams): Promise<GetTasksResult>

Parameters:#

NameType
paramsGetTasksParams

Returns: Promise<GetTasksResult>

Inherited from: Queries

Defined in: src/Queries.ts:155


getUploadFileUrl#

â–¸ getUploadFileUrl(arg: GetUploadFileUrlParams): Promise<GetUploadFileUrlResult>

Parameters:#

NameType
argGetUploadFileUrlParams

Returns: Promise<GetUploadFileUrlResult>

Inherited from: Queries

Defined in: src/Queries.ts:97


getUserNotifications#

â–¸ getUserNotifications(params: GetUserNotificationsParams): Promise<GetUserNotificationsResult>

Parameters:#

NameType
paramsGetUserNotificationsParams

Returns: Promise<GetUserNotificationsResult>

Inherited from: Queries

Defined in: src/Queries.ts:151


getUserSharedPages#

â–¸ getUserSharedPages(arg: GetUserSharedPagesParams): Promise<GetUserSharedPagesResult>

Parameters:#

NameType
argGetUserSharedPagesParams

Returns: Promise<GetUserSharedPagesResult>

Inherited from: Queries

Defined in: src/Queries.ts:61


getUserTasks#

â–¸ getUserTasks(): Promise<GetUserTasksResult>

Returns: Promise<GetUserTasksResult>

Inherited from: Queries

Defined in: src/Queries.ts:65


initializeCache#

â–¸ initializeCache(): Promise<void>

Returns: Promise<void>

Inherited from: Queries

Defined in: src/Cache.ts:66


initializeCacheForSpecificData#

â–¸ initializeCacheForSpecificData(id: string, type: block | collection | collection_view | space | notion_user | space_view | user_root | user_settings): Promise<void>

Parameters:#

NameType
idstring
typeblock | collection | collection_view | space | notion_user | space_view | user_root | user_settings

Returns: Promise<void>

Inherited from: Queries

Defined in: src/Cache.ts:110


initializeGoogleDriveBlock#

â–¸ initializeGoogleDriveBlock(arg: InitializeGoogleDriveBlockParams): Promise<InitializeGoogleDriveBlockResult>

Parameters:#

NameType
argInitializeGoogleDriveBlockParams

Returns: Promise<InitializeGoogleDriveBlockResult>

Defined in: src/Mutations.ts:76


initializePageTemplate#

â–¸ initializePageTemplate(arg: InitializePageTemplateParams): Promise<InitializePageTemplateResult>

Parameters:#

NameType
argInitializePageTemplateParams

Returns: Promise<InitializePageTemplateResult>

Defined in: src/Mutations.ts:82


inviteGuestsToSpace#

â–¸ inviteGuestsToSpace(arg: InviteGuestsToSpaceParams): Promise<unknown>

Parameters:#

NameType
argInviteGuestsToSpaceParams

Returns: Promise<unknown>

Defined in: src/Mutations.ts:56


isEmailEducation#

â–¸ isEmailEducation(): Promise<IsEmailEducationResult>

Returns: Promise<IsEmailEducationResult>

Inherited from: Queries

Defined in: src/Queries.ts:147


isUserDomainJoinable#

â–¸ isUserDomainJoinable(): Promise<IsUserDomainJoinableResult>

Returns: Promise<IsUserDomainJoinableResult>

Inherited from: Queries

Defined in: src/Queries.ts:143


loadBlockSubtree#

â–¸ loadBlockSubtree(arg: LoadBlockSubtreeParams): Promise<LoadBlockSubtreeResult>

Parameters:#

NameType
argLoadBlockSubtreeParams

Returns: Promise<LoadBlockSubtreeResult>

Inherited from: Queries

Defined in: src/Queries.ts:81


loadPageChunk#

â–¸ loadPageChunk(params: LoadPageChunkParams): Promise<LoadPageChunkResult>

Parameters:#

NameType
paramsLoadPageChunkParams

Returns: Promise<LoadPageChunkResult>

Inherited from: Queries

Defined in: src/Queries.ts:133


loadUserContent#

â–¸ loadUserContent(): Promise<LoadUserContentResult>

Returns: Promise<LoadUserContentResult>

Inherited from: Queries

Defined in: src/Queries.ts:127


queryCollection#

â–¸ queryCollection(params: QueryCollectionParams): Promise<QueryCollectionResult>

Parameters:#

NameType
paramsQueryCollectionParams

Returns: Promise<QueryCollectionResult>

Inherited from: Queries

Defined in: src/Queries.ts:121


recordPageVisit#

â–¸ recordPageVisit(params: RecordPageVisitParams): Promise<GetPageVisitsResult>

Parameters:#

NameType
paramsRecordPageVisitParams

Returns: Promise<GetPageVisitsResult>

Inherited from: Queries

Defined in: src/Queries.ts:159


removeUsersFromSpace#

â–¸ removeUsersFromSpace(arg: RemoveUsersFromSpaceParams): Promise<RemoveUsersFromSpaceResult>

Parameters:#

NameType
argRemoveUsersFromSpaceParams

Returns: Promise<RemoveUsersFromSpaceResult>

Defined in: src/Mutations.ts:50


returnNonCachedData#

â–¸ returnNonCachedData(ids: UpdateCacheManuallyParam): UpdateCacheManuallyParam

Parameters:#

NameType
idsUpdateCacheManuallyParam

Returns: UpdateCacheManuallyParam

Inherited from: Queries

Defined in: src/Cache.ts:60


saveToCache#

â–¸ saveToCache(recordMap: Partial<RecordMap>): void

Save the passed recordMap to cache

Parameters:#

NameTypeDescription
recordMapPartial<RecordMap>RecordMap map to save to cache

Returns: void

Inherited from: Queries

Defined in: src/Cache.ts:51


saveTransactions#

â–¸ saveTransactions(Operations: IOperation[]): Promise<unknown>

Parameters:#

NameType
OperationsIOperation[]

Returns: Promise<unknown>

Defined in: src/Mutations.ts:64


setBookmarkMetadata#

â–¸ setBookmarkMetadata(arg: SetBookmarkMetadataParams): Promise<void>

Parameters:#

NameType
argSetBookmarkMetadataParams

Returns: Promise<void>

Defined in: src/Mutations.ts:72


setPageNotificationsAsRead#

â–¸ setPageNotificationsAsRead(arg: SetPageNotificationsAsReadParams): Promise<unknown>

Parameters:#

NameType
argSetPageNotificationsAsReadParams

Returns: Promise<unknown>

Defined in: src/Mutations.ts:42


setSpaceNotificationsAsRead#

â–¸ setSpaceNotificationsAsRead(arg: SetSpaceNotificationsAsReadParams): Promise<unknown>

Parameters:#

NameType
argSetSpaceNotificationsAsReadParams

Returns: Promise<unknown>

Defined in: src/Mutations.ts:46


syncRecordValues#

â–¸ syncRecordValues(params: SyncRecordValuesParams): Promise<SyncRecordValuesResult>

Parameters:#

NameType
paramsSyncRecordValuesParams

Returns: Promise<SyncRecordValuesResult>

Inherited from: Queries

Defined in: src/Queries.ts:115


updateCacheIfNotPresent#

â–¸ updateCacheIfNotPresent(arg: UpdateCacheManuallyParam): Promise<void>

Parameters:#

NameType
argUpdateCacheManuallyParam

Returns: Promise<void>

Inherited from: Queries

Defined in: src/Cache.ts:96


updateCacheManually#

â–¸ updateCacheManually(arg: string | UpdateCacheManuallyParam): Promise<void>

Parameters:#

NameType
argstring | UpdateCacheManuallyParam

Returns: Promise<void>

Inherited from: Queries

Defined in: src/Cache.ts:82