1 | import { _SPInstance, SPInit } from "../spqueryable.js";
|
2 | import { IWeb } from "../webs/types.js";
|
3 | import { IChangeQuery } from "../types.js";
|
4 | export declare class _Site extends _SPInstance {
|
5 | constructor(base: SPInit, path?: string);
|
6 | /**
|
7 | * Gets the root web of the site collection
|
8 | *
|
9 | */
|
10 | get rootWeb(): IWeb;
|
11 | /**
|
12 | * Returns the collection of changes from the change log that have occurred within the list, based on the specified query
|
13 | *
|
14 | * @param query The change query
|
15 | */
|
16 | getChanges(query: IChangeQuery): Promise<any>;
|
17 | /**
|
18 | * Opens a web by id (using POST)
|
19 | *
|
20 | * @param webId The GUID id of the web to open
|
21 | */
|
22 | openWebById(webId: string): Promise<IOpenWebByIdResult>;
|
23 | /**
|
24 | * Gets a Web instance representing the root web of the site collection
|
25 | * correctly setup for chaining within the library
|
26 | */
|
27 | getRootWeb(): Promise<IWeb>;
|
28 | /**
|
29 | * Gets the context information for this site collection
|
30 | */
|
31 | getContextInfo(): Promise<IContextInfo>;
|
32 | /**
|
33 | * Deletes the current site
|
34 | *
|
35 | */
|
36 | delete(): Promise<void>;
|
37 | /**
|
38 | * Gets the document libraries on a site. Static method. (SharePoint Online only)
|
39 | *
|
40 | * @param absoluteWebUrl The absolute url of the web whose document libraries should be returned
|
41 | */
|
42 | getDocumentLibraries(absoluteWebUrl: string): Promise<IDocumentLibraryInformation[]>;
|
43 | /**
|
44 | * Gets the site url from a page url
|
45 | *
|
46 | * @param absolutePageUrl The absolute url of the page
|
47 | */
|
48 | getWebUrlFromPageUrl(absolutePageUrl: string): Promise<string>;
|
49 | /**
|
50 | * Creates a Modern communication site.
|
51 | *
|
52 | * @param title The title of the site to create
|
53 | * @param lcid The language to use for the site. If not specified will default to 1033 (English).
|
54 | * @param shareByEmailEnabled If set to true, it will enable sharing files via Email. By default it is set to false
|
55 | * @param url The fully qualified URL (e.g. https:
|
56 | * @param description The description of the communication site.
|
57 | * @param classification The Site classification to use. For instance 'Contoso Classified'. See https:
|
58 | * @param siteDesignId The Guid of the site design to be used.
|
59 | * You can use the below default OOTB GUIDs:
|
60 | * Topic: 00000000-0000-0000-0000-000000000000
|
61 | * Showcase: 6142d2a0-63a5-4ba0-aede-d9fefca2c767
|
62 | * Blank: f6cc5403-0d63-442e-96c0-285923709ffc
|
63 | * @param hubSiteId The id of the hub site to which the new site should be associated
|
64 | * @param owner Optional owner value, required if executing the method in app only mode
|
65 | */
|
66 | createCommunicationSite(title: string, lcid: number, shareByEmailEnabled: boolean, url: string, description?: string, classification?: string, siteDesignId?: string, hubSiteId?: string, owner?: string): Promise<ISiteCreationResponse>;
|
67 | createCommunicationSiteFromProps(props: ICreateCommSiteProps): Promise<ISiteCreationResponse>;
|
68 | |
69 |
|
70 |
|
71 |
|
72 | exists(url: string): Promise<boolean>;
|
73 | |
74 |
|
75 |
|
76 |
|
77 |
|
78 |
|
79 |
|
80 |
|
81 |
|
82 |
|
83 |
|
84 | createModernTeamSite(displayName: string, alias: string, isPublic?: boolean, lcid?: number, description?: string, classification?: string, owners?: string[], hubSiteId?: string, siteDesignId?: string): Promise<ISiteCreationResponse>;
|
85 | createModernTeamSiteFromProps(props: ICreateTeamSiteProps): Promise<ISiteCreationResponse>;
|
86 | }
|
87 | export interface ISite extends _Site {
|
88 | }
|
89 | export declare const Site: import("../spqueryable.js").ISPInvokableFactory<ISite>;
|
90 |
|
91 |
|
92 |
|
93 | export interface IOpenWebByIdResult {
|
94 | data: any;
|
95 | web: IWeb;
|
96 | }
|
97 |
|
98 |
|
99 |
|
100 | export interface IContextInfo {
|
101 | FormDigestTimeoutSeconds?: number;
|
102 | FormDigestValue?: number;
|
103 | LibraryVersion?: string;
|
104 | SiteFullUrl?: string;
|
105 | SupportedSchemaVersions?: string[];
|
106 | WebFullUrl?: string;
|
107 | }
|
108 |
|
109 |
|
110 |
|
111 | export interface IDocumentLibraryInformation {
|
112 | AbsoluteUrl?: string;
|
113 | Modified?: Date;
|
114 | ModifiedFriendlyDisplay?: string;
|
115 | ServerRelativeUrl?: string;
|
116 | Title?: string;
|
117 | }
|
118 | export interface ICreateCommSiteProps {
|
119 | Classification?: string;
|
120 | Description?: string;
|
121 | HubSiteId?: string;
|
122 | Lcid?: number;
|
123 | Owner?: string;
|
124 | ShareByEmailEnabled?: boolean;
|
125 | SiteDesignId?: string;
|
126 | Title: string;
|
127 | Url: string;
|
128 | WebTemplate?: "SITEPAGEPUBLISHING#0" | "STS#3";
|
129 | WebTemplateExtensionId?: string;
|
130 | }
|
131 | export interface ICreateTeamSiteProps {
|
132 | displayName: string;
|
133 | alias: string;
|
134 | isPublic?: boolean;
|
135 | lcid?: number;
|
136 | description?: string;
|
137 | classification?: string;
|
138 | owners?: string[];
|
139 | hubSiteId?: string;
|
140 | siteDesignId?: string;
|
141 | }
|
142 | export interface ISiteCreationResponse {
|
143 | "SiteId": string;
|
144 | "SiteStatus": 0 | 1 | 2 | 3;
|
145 | "SiteUrl": string;
|
146 | }
|
147 |
|
\ | No newline at end of file |