@hostinger/sdk 1.57.0 → 1.58.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/api.ts +464 -1
- package/base.ts +1 -1
- package/common.ts +1 -1
- package/configuration.ts +2 -2
- package/dist/api.d.ts +296 -1
- package/dist/api.js +308 -10
- package/dist/base.d.ts +1 -1
- package/dist/base.js +1 -1
- package/dist/common.d.ts +1 -1
- package/dist/common.js +1 -1
- package/dist/configuration.d.ts +1 -1
- package/dist/configuration.js +2 -2
- package/dist/esm/api.d.ts +296 -1
- package/dist/esm/api.js +299 -1
- package/dist/esm/base.d.ts +1 -1
- package/dist/esm/base.js +1 -1
- package/dist/esm/common.d.ts +1 -1
- package/dist/esm/common.js +1 -1
- package/dist/esm/configuration.d.ts +1 -1
- package/dist/esm/configuration.js +2 -2
- package/dist/esm/index.d.ts +1 -1
- package/dist/esm/index.js +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/docs/HostingGitApi.md +228 -0
- package/docs/HostingV1GitDeployWebsiteGitRepositoryRequest.md +24 -0
- package/docs/HostingV1GitGitDeployOutputResource.md +23 -0
- package/docs/HostingV1GitGitSshKeyResource.md +21 -0
- package/docs/HostingV1GitWebsiteGitRepositoryResource.md +27 -0
- package/docs/HostingV1GitWebsiteGitRepositoryWebhookResource.md +27 -0
- package/docs/WordPressV1McpExecuteMcpToolRequest.md +24 -0
- package/index.ts +1 -1
- package/package.json +1 -1
package/dist/esm/api.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.
|
|
6
|
+
* API Version: 1.58.1
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
9
9
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
|
@@ -1126,6 +1126,10 @@ export const WordPressV1MaintenanceMaintenanceStatusResourceStatusEnum = {
|
|
|
1126
1126
|
Enabled: 'enabled',
|
|
1127
1127
|
Disabled: 'disabled'
|
|
1128
1128
|
};
|
|
1129
|
+
export const WordPressV1McpExecuteMcpToolRequestServerEnum = {
|
|
1130
|
+
McpAdapterDefaultServer: 'mcp-adapter-default-server',
|
|
1131
|
+
HostingerAiAssistantMcpServer: 'hostinger-ai-assistant-mcp-server'
|
|
1132
|
+
};
|
|
1129
1133
|
export const WordPressV1MemcachedMemcachedStatusResourceStatusEnum = {
|
|
1130
1134
|
Active: 'active',
|
|
1131
1135
|
Inactive: 'inactive'
|
|
@@ -14856,6 +14860,79 @@ export const HostingGitApiAxiosParamCreator = function (configuration) {
|
|
|
14856
14860
|
options: localVarRequestOptions,
|
|
14857
14861
|
};
|
|
14858
14862
|
}),
|
|
14863
|
+
/**
|
|
14864
|
+
* Clones a Git repository into a directory of the website, or pulls it again. An empty or missing directory gets a clone of the branch. A directory that already holds this repository and branch is reset to its last commit and pulled: changes made on the server to files the repository tracks are discarded, files it does not track stay. A directory that holds other files, including another repository or another branch of this one, is rejected. `composer install` runs after the clone or pull when the repository has a `composer.json`. The call waits for the deployment and returns its log. `is_success` false means Git or composer failed and the log says why. A second call for the same directory is rejected while the first is still waiting for the server. If the request times out, the deployment may still finish on the server; calling again later with the same repository and branch pulls. Private repositories need an SSH URL and the account\'s Git SSH key from `Generate Git SSH key`, added to the repository as a deploy key.
|
|
14865
|
+
* @summary Deploy website Git repository
|
|
14866
|
+
* @param {string} username
|
|
14867
|
+
* @param {string} domain Domain name
|
|
14868
|
+
* @param {HostingV1GitDeployWebsiteGitRepositoryRequest} hostingV1GitDeployWebsiteGitRepositoryRequest
|
|
14869
|
+
* @param {*} [options] Override http request option.
|
|
14870
|
+
* @throws {RequiredError}
|
|
14871
|
+
*/
|
|
14872
|
+
deployWebsiteGitRepositoryV1: (username_1, domain_1, hostingV1GitDeployWebsiteGitRepositoryRequest_1, ...args_1) => __awaiter(this, [username_1, domain_1, hostingV1GitDeployWebsiteGitRepositoryRequest_1, ...args_1], void 0, function* (username, domain, hostingV1GitDeployWebsiteGitRepositoryRequest, options = {}) {
|
|
14873
|
+
// verify required parameter 'username' is not null or undefined
|
|
14874
|
+
assertParamExists('deployWebsiteGitRepositoryV1', 'username', username);
|
|
14875
|
+
// verify required parameter 'domain' is not null or undefined
|
|
14876
|
+
assertParamExists('deployWebsiteGitRepositoryV1', 'domain', domain);
|
|
14877
|
+
// verify required parameter 'hostingV1GitDeployWebsiteGitRepositoryRequest' is not null or undefined
|
|
14878
|
+
assertParamExists('deployWebsiteGitRepositoryV1', 'hostingV1GitDeployWebsiteGitRepositoryRequest', hostingV1GitDeployWebsiteGitRepositoryRequest);
|
|
14879
|
+
const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/git/repositories/deploy`
|
|
14880
|
+
.replace(`{${"username"}}`, encodeURIComponent(String(username)))
|
|
14881
|
+
.replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
|
|
14882
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
14883
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
14884
|
+
let baseOptions;
|
|
14885
|
+
if (configuration) {
|
|
14886
|
+
baseOptions = configuration.baseOptions;
|
|
14887
|
+
}
|
|
14888
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
14889
|
+
const localVarHeaderParameter = {};
|
|
14890
|
+
const localVarQueryParameter = {};
|
|
14891
|
+
// authentication apiToken required
|
|
14892
|
+
// http bearer authentication required
|
|
14893
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
14894
|
+
localVarHeaderParameter['Content-Type'] = 'application/json';
|
|
14895
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
14896
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
14897
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
14898
|
+
localVarRequestOptions.data = serializeDataIfNeeded(hostingV1GitDeployWebsiteGitRepositoryRequest, localVarRequestOptions, configuration);
|
|
14899
|
+
return {
|
|
14900
|
+
url: toPathString(localVarUrlObj),
|
|
14901
|
+
options: localVarRequestOptions,
|
|
14902
|
+
};
|
|
14903
|
+
}),
|
|
14904
|
+
/**
|
|
14905
|
+
* Creates the SSH key pair of the hosting account and returns the public key. When the account already has a key, returns that key unchanged. One key serves every website of the account; add the public key to a private repository as a deploy key before deploying it.
|
|
14906
|
+
* @summary Generate Git SSH key
|
|
14907
|
+
* @param {string} username
|
|
14908
|
+
* @param {*} [options] Override http request option.
|
|
14909
|
+
* @throws {RequiredError}
|
|
14910
|
+
*/
|
|
14911
|
+
generateGitSSHKeyV1: (username_1, ...args_1) => __awaiter(this, [username_1, ...args_1], void 0, function* (username, options = {}) {
|
|
14912
|
+
// verify required parameter 'username' is not null or undefined
|
|
14913
|
+
assertParamExists('generateGitSSHKeyV1', 'username', username);
|
|
14914
|
+
const localVarPath = `/api/hosting/v1/accounts/{username}/git/ssh-key`
|
|
14915
|
+
.replace(`{${"username"}}`, encodeURIComponent(String(username)));
|
|
14916
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
14917
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
14918
|
+
let baseOptions;
|
|
14919
|
+
if (configuration) {
|
|
14920
|
+
baseOptions = configuration.baseOptions;
|
|
14921
|
+
}
|
|
14922
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'POST' }, baseOptions), options);
|
|
14923
|
+
const localVarHeaderParameter = {};
|
|
14924
|
+
const localVarQueryParameter = {};
|
|
14925
|
+
// authentication apiToken required
|
|
14926
|
+
// http bearer authentication required
|
|
14927
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
14928
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
14929
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
14930
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
14931
|
+
return {
|
|
14932
|
+
url: toPathString(localVarUrlObj),
|
|
14933
|
+
options: localVarRequestOptions,
|
|
14934
|
+
};
|
|
14935
|
+
}),
|
|
14859
14936
|
/**
|
|
14860
14937
|
* Returns the Git auto-deployment settings of the website: which repository and branch deploy into which directory, and whether pushes trigger a deployment. `is_enabled` false keeps the repository link but ignores pushes. When the website has no auto-deployment configured every field is null. Save settings with `Update Git auto-deployment settings`.
|
|
14861
14938
|
* @summary Get Git auto-deployment settings
|
|
@@ -14892,6 +14969,38 @@ export const HostingGitApiAxiosParamCreator = function (configuration) {
|
|
|
14892
14969
|
options: localVarRequestOptions,
|
|
14893
14970
|
};
|
|
14894
14971
|
}),
|
|
14972
|
+
/**
|
|
14973
|
+
* Returns the public SSH key of the hosting account. `Deploy website Git repository` uses this key to clone and pull over SSH, so a private repository works once the key is added to it as a deploy key on the Git host. `public_key` is null when the account has no key yet.
|
|
14974
|
+
* @summary Get Git SSH public key
|
|
14975
|
+
* @param {string} username
|
|
14976
|
+
* @param {*} [options] Override http request option.
|
|
14977
|
+
* @throws {RequiredError}
|
|
14978
|
+
*/
|
|
14979
|
+
getGitSSHPublicKeyV1: (username_1, ...args_1) => __awaiter(this, [username_1, ...args_1], void 0, function* (username, options = {}) {
|
|
14980
|
+
// verify required parameter 'username' is not null or undefined
|
|
14981
|
+
assertParamExists('getGitSSHPublicKeyV1', 'username', username);
|
|
14982
|
+
const localVarPath = `/api/hosting/v1/accounts/{username}/git/ssh-key`
|
|
14983
|
+
.replace(`{${"username"}}`, encodeURIComponent(String(username)));
|
|
14984
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
14985
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
14986
|
+
let baseOptions;
|
|
14987
|
+
if (configuration) {
|
|
14988
|
+
baseOptions = configuration.baseOptions;
|
|
14989
|
+
}
|
|
14990
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
14991
|
+
const localVarHeaderParameter = {};
|
|
14992
|
+
const localVarQueryParameter = {};
|
|
14993
|
+
// authentication apiToken required
|
|
14994
|
+
// http bearer authentication required
|
|
14995
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
14996
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
14997
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
14998
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
14999
|
+
return {
|
|
15000
|
+
url: toPathString(localVarUrlObj),
|
|
15001
|
+
options: localVarRequestOptions,
|
|
15002
|
+
};
|
|
15003
|
+
}),
|
|
14895
15004
|
/**
|
|
14896
15005
|
* Lists the repositories the Git installation can access, read live from the provider. Works for github and gitlab installations. Use an active installation: a suspended or pending one is still queried and the call fails with whatever the provider answers. The list is cut at the first 500 repositories in the order the provider returns them; when the account has more, name the repository directly instead of searching this list. `owner`, `name` and a branch (`default_branch` or another one) go into `source_options` of `Start Node.js build` or into `Update Git auto-deployment settings`. Returns 404 when the installation does not belong to the customer. Limited to 10 calls per minute per API client (429 above that).
|
|
14897
15006
|
* @summary List Git installation repositories
|
|
@@ -14960,6 +15069,42 @@ export const HostingGitApiAxiosParamCreator = function (configuration) {
|
|
|
14960
15069
|
options: localVarRequestOptions,
|
|
14961
15070
|
};
|
|
14962
15071
|
}),
|
|
15072
|
+
/**
|
|
15073
|
+
* Lists the Git repositories linked to directories of the website, with `Deploy website Git repository` or in the Git section of hPanel: clone URL, branch and directory of each one. A repository whose clone failed stays listed; deploying it again retries the clone. GitHub and GitLab auto-deployments are not listed here; see `Get Git auto-deployment settings`.
|
|
15074
|
+
* @summary List website Git repositories
|
|
15075
|
+
* @param {string} username
|
|
15076
|
+
* @param {string} domain Domain name
|
|
15077
|
+
* @param {*} [options] Override http request option.
|
|
15078
|
+
* @throws {RequiredError}
|
|
15079
|
+
*/
|
|
15080
|
+
listWebsiteGitRepositoriesV1: (username_1, domain_1, ...args_1) => __awaiter(this, [username_1, domain_1, ...args_1], void 0, function* (username, domain, options = {}) {
|
|
15081
|
+
// verify required parameter 'username' is not null or undefined
|
|
15082
|
+
assertParamExists('listWebsiteGitRepositoriesV1', 'username', username);
|
|
15083
|
+
// verify required parameter 'domain' is not null or undefined
|
|
15084
|
+
assertParamExists('listWebsiteGitRepositoriesV1', 'domain', domain);
|
|
15085
|
+
const localVarPath = `/api/hosting/v1/accounts/{username}/websites/{domain}/git/repositories`
|
|
15086
|
+
.replace(`{${"username"}}`, encodeURIComponent(String(username)))
|
|
15087
|
+
.replace(`{${"domain"}}`, encodeURIComponent(String(domain)));
|
|
15088
|
+
// use dummy base URL string because the URL constructor only accepts absolute URLs.
|
|
15089
|
+
const localVarUrlObj = new URL(localVarPath, DUMMY_BASE_URL);
|
|
15090
|
+
let baseOptions;
|
|
15091
|
+
if (configuration) {
|
|
15092
|
+
baseOptions = configuration.baseOptions;
|
|
15093
|
+
}
|
|
15094
|
+
const localVarRequestOptions = Object.assign(Object.assign({ method: 'GET' }, baseOptions), options);
|
|
15095
|
+
const localVarHeaderParameter = {};
|
|
15096
|
+
const localVarQueryParameter = {};
|
|
15097
|
+
// authentication apiToken required
|
|
15098
|
+
// http bearer authentication required
|
|
15099
|
+
yield setBearerAuthToObject(localVarHeaderParameter, configuration);
|
|
15100
|
+
setSearchParams(localVarUrlObj, localVarQueryParameter);
|
|
15101
|
+
let headersFromBaseOptions = baseOptions && baseOptions.headers ? baseOptions.headers : {};
|
|
15102
|
+
localVarRequestOptions.headers = Object.assign(Object.assign(Object.assign({}, localVarHeaderParameter), headersFromBaseOptions), options.headers);
|
|
15103
|
+
return {
|
|
15104
|
+
url: toPathString(localVarUrlObj),
|
|
15105
|
+
options: localVarRequestOptions,
|
|
15106
|
+
};
|
|
15107
|
+
}),
|
|
14963
15108
|
/**
|
|
14964
15109
|
* Creates or replaces the Git auto-deployment settings of the website: repository, branch, the directory under the document root to deploy into, and `is_enabled`. Send the full set; `is_enabled` defaults to true and `directory` to the document root. `installation_uuid` must be an installation from `List Git installations` that belongs to the same customer as the website. For PHP and static websites, saving with `is_enabled` true deploys the branch right away and every later push to that branch deploys again. For Node.js and Website Builder websites saving does not clone anything. On a Node.js website start the first deploy with `Start Node.js build` using `source_type` `git`; pushes then trigger new builds with the build settings stored for the website.
|
|
14965
15110
|
* @summary Update Git auto-deployment settings
|
|
@@ -15026,6 +15171,38 @@ export const HostingGitApiFp = function (configuration) {
|
|
|
15026
15171
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
15027
15172
|
});
|
|
15028
15173
|
},
|
|
15174
|
+
/**
|
|
15175
|
+
* Clones a Git repository into a directory of the website, or pulls it again. An empty or missing directory gets a clone of the branch. A directory that already holds this repository and branch is reset to its last commit and pulled: changes made on the server to files the repository tracks are discarded, files it does not track stay. A directory that holds other files, including another repository or another branch of this one, is rejected. `composer install` runs after the clone or pull when the repository has a `composer.json`. The call waits for the deployment and returns its log. `is_success` false means Git or composer failed and the log says why. A second call for the same directory is rejected while the first is still waiting for the server. If the request times out, the deployment may still finish on the server; calling again later with the same repository and branch pulls. Private repositories need an SSH URL and the account\'s Git SSH key from `Generate Git SSH key`, added to the repository as a deploy key.
|
|
15176
|
+
* @summary Deploy website Git repository
|
|
15177
|
+
* @param {string} username
|
|
15178
|
+
* @param {string} domain Domain name
|
|
15179
|
+
* @param {HostingV1GitDeployWebsiteGitRepositoryRequest} hostingV1GitDeployWebsiteGitRepositoryRequest
|
|
15180
|
+
* @param {*} [options] Override http request option.
|
|
15181
|
+
* @throws {RequiredError}
|
|
15182
|
+
*/
|
|
15183
|
+
deployWebsiteGitRepositoryV1(username, domain, hostingV1GitDeployWebsiteGitRepositoryRequest, options) {
|
|
15184
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15185
|
+
var _a, _b;
|
|
15186
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.deployWebsiteGitRepositoryV1(username, domain, hostingV1GitDeployWebsiteGitRepositoryRequest, options);
|
|
15187
|
+
const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingGitApi.deployWebsiteGitRepositoryV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
|
|
15188
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
15189
|
+
});
|
|
15190
|
+
},
|
|
15191
|
+
/**
|
|
15192
|
+
* Creates the SSH key pair of the hosting account and returns the public key. When the account already has a key, returns that key unchanged. One key serves every website of the account; add the public key to a private repository as a deploy key before deploying it.
|
|
15193
|
+
* @summary Generate Git SSH key
|
|
15194
|
+
* @param {string} username
|
|
15195
|
+
* @param {*} [options] Override http request option.
|
|
15196
|
+
* @throws {RequiredError}
|
|
15197
|
+
*/
|
|
15198
|
+
generateGitSSHKeyV1(username, options) {
|
|
15199
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15200
|
+
var _a, _b;
|
|
15201
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.generateGitSSHKeyV1(username, options);
|
|
15202
|
+
const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingGitApi.generateGitSSHKeyV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
|
|
15203
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
15204
|
+
});
|
|
15205
|
+
},
|
|
15029
15206
|
/**
|
|
15030
15207
|
* Returns the Git auto-deployment settings of the website: which repository and branch deploy into which directory, and whether pushes trigger a deployment. `is_enabled` false keeps the repository link but ignores pushes. When the website has no auto-deployment configured every field is null. Save settings with `Update Git auto-deployment settings`.
|
|
15031
15208
|
* @summary Get Git auto-deployment settings
|
|
@@ -15042,6 +15219,21 @@ export const HostingGitApiFp = function (configuration) {
|
|
|
15042
15219
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
15043
15220
|
});
|
|
15044
15221
|
},
|
|
15222
|
+
/**
|
|
15223
|
+
* Returns the public SSH key of the hosting account. `Deploy website Git repository` uses this key to clone and pull over SSH, so a private repository works once the key is added to it as a deploy key on the Git host. `public_key` is null when the account has no key yet.
|
|
15224
|
+
* @summary Get Git SSH public key
|
|
15225
|
+
* @param {string} username
|
|
15226
|
+
* @param {*} [options] Override http request option.
|
|
15227
|
+
* @throws {RequiredError}
|
|
15228
|
+
*/
|
|
15229
|
+
getGitSSHPublicKeyV1(username, options) {
|
|
15230
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15231
|
+
var _a, _b;
|
|
15232
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.getGitSSHPublicKeyV1(username, options);
|
|
15233
|
+
const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingGitApi.getGitSSHPublicKeyV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
|
|
15234
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
15235
|
+
});
|
|
15236
|
+
},
|
|
15045
15237
|
/**
|
|
15046
15238
|
* Lists the repositories the Git installation can access, read live from the provider. Works for github and gitlab installations. Use an active installation: a suspended or pending one is still queried and the call fails with whatever the provider answers. The list is cut at the first 500 repositories in the order the provider returns them; when the account has more, name the repository directly instead of searching this list. `owner`, `name` and a branch (`default_branch` or another one) go into `source_options` of `Start Node.js build` or into `Update Git auto-deployment settings`. Returns 404 when the installation does not belong to the customer. Limited to 10 calls per minute per API client (429 above that).
|
|
15047
15239
|
* @summary List Git installation repositories
|
|
@@ -15073,6 +15265,22 @@ export const HostingGitApiFp = function (configuration) {
|
|
|
15073
15265
|
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
15074
15266
|
});
|
|
15075
15267
|
},
|
|
15268
|
+
/**
|
|
15269
|
+
* Lists the Git repositories linked to directories of the website, with `Deploy website Git repository` or in the Git section of hPanel: clone URL, branch and directory of each one. A repository whose clone failed stays listed; deploying it again retries the clone. GitHub and GitLab auto-deployments are not listed here; see `Get Git auto-deployment settings`.
|
|
15270
|
+
* @summary List website Git repositories
|
|
15271
|
+
* @param {string} username
|
|
15272
|
+
* @param {string} domain Domain name
|
|
15273
|
+
* @param {*} [options] Override http request option.
|
|
15274
|
+
* @throws {RequiredError}
|
|
15275
|
+
*/
|
|
15276
|
+
listWebsiteGitRepositoriesV1(username, domain, options) {
|
|
15277
|
+
return __awaiter(this, void 0, void 0, function* () {
|
|
15278
|
+
var _a, _b;
|
|
15279
|
+
const localVarAxiosArgs = yield localVarAxiosParamCreator.listWebsiteGitRepositoriesV1(username, domain, options);
|
|
15280
|
+
const localVarOperationServerBasePath = (_b = (_a = operationServerMap['HostingGitApi.listWebsiteGitRepositoriesV1']) === null || _a === void 0 ? void 0 : _a[0]) === null || _b === void 0 ? void 0 : _b.url;
|
|
15281
|
+
return (axios, basePath) => createRequestFunction(localVarAxiosArgs, globalAxios, BASE_PATH, configuration)(axios, localVarOperationServerBasePath || basePath);
|
|
15282
|
+
});
|
|
15283
|
+
},
|
|
15076
15284
|
/**
|
|
15077
15285
|
* Creates or replaces the Git auto-deployment settings of the website: repository, branch, the directory under the document root to deploy into, and `is_enabled`. Send the full set; `is_enabled` defaults to true and `directory` to the document root. `installation_uuid` must be an installation from `List Git installations` that belongs to the same customer as the website. For PHP and static websites, saving with `is_enabled` true deploys the branch right away and every later push to that branch deploys again. For Node.js and Website Builder websites saving does not clone anything. On a Node.js website start the first deploy with `Start Node.js build` using `source_type` `git`; pushes then trigger new builds with the build settings stored for the website.
|
|
15078
15286
|
* @summary Update Git auto-deployment settings
|
|
@@ -15110,6 +15318,28 @@ export const HostingGitApiFactory = function (configuration, basePath, axios) {
|
|
|
15110
15318
|
deleteGitAutoDeploymentSettingsV1(username, domain, options) {
|
|
15111
15319
|
return localVarFp.deleteGitAutoDeploymentSettingsV1(username, domain, options).then((request) => request(axios, basePath));
|
|
15112
15320
|
},
|
|
15321
|
+
/**
|
|
15322
|
+
* Clones a Git repository into a directory of the website, or pulls it again. An empty or missing directory gets a clone of the branch. A directory that already holds this repository and branch is reset to its last commit and pulled: changes made on the server to files the repository tracks are discarded, files it does not track stay. A directory that holds other files, including another repository or another branch of this one, is rejected. `composer install` runs after the clone or pull when the repository has a `composer.json`. The call waits for the deployment and returns its log. `is_success` false means Git or composer failed and the log says why. A second call for the same directory is rejected while the first is still waiting for the server. If the request times out, the deployment may still finish on the server; calling again later with the same repository and branch pulls. Private repositories need an SSH URL and the account\'s Git SSH key from `Generate Git SSH key`, added to the repository as a deploy key.
|
|
15323
|
+
* @summary Deploy website Git repository
|
|
15324
|
+
* @param {string} username
|
|
15325
|
+
* @param {string} domain Domain name
|
|
15326
|
+
* @param {HostingV1GitDeployWebsiteGitRepositoryRequest} hostingV1GitDeployWebsiteGitRepositoryRequest
|
|
15327
|
+
* @param {*} [options] Override http request option.
|
|
15328
|
+
* @throws {RequiredError}
|
|
15329
|
+
*/
|
|
15330
|
+
deployWebsiteGitRepositoryV1(username, domain, hostingV1GitDeployWebsiteGitRepositoryRequest, options) {
|
|
15331
|
+
return localVarFp.deployWebsiteGitRepositoryV1(username, domain, hostingV1GitDeployWebsiteGitRepositoryRequest, options).then((request) => request(axios, basePath));
|
|
15332
|
+
},
|
|
15333
|
+
/**
|
|
15334
|
+
* Creates the SSH key pair of the hosting account and returns the public key. When the account already has a key, returns that key unchanged. One key serves every website of the account; add the public key to a private repository as a deploy key before deploying it.
|
|
15335
|
+
* @summary Generate Git SSH key
|
|
15336
|
+
* @param {string} username
|
|
15337
|
+
* @param {*} [options] Override http request option.
|
|
15338
|
+
* @throws {RequiredError}
|
|
15339
|
+
*/
|
|
15340
|
+
generateGitSSHKeyV1(username, options) {
|
|
15341
|
+
return localVarFp.generateGitSSHKeyV1(username, options).then((request) => request(axios, basePath));
|
|
15342
|
+
},
|
|
15113
15343
|
/**
|
|
15114
15344
|
* Returns the Git auto-deployment settings of the website: which repository and branch deploy into which directory, and whether pushes trigger a deployment. `is_enabled` false keeps the repository link but ignores pushes. When the website has no auto-deployment configured every field is null. Save settings with `Update Git auto-deployment settings`.
|
|
15115
15345
|
* @summary Get Git auto-deployment settings
|
|
@@ -15121,6 +15351,16 @@ export const HostingGitApiFactory = function (configuration, basePath, axios) {
|
|
|
15121
15351
|
getGitAutoDeploymentSettingsV1(username, domain, options) {
|
|
15122
15352
|
return localVarFp.getGitAutoDeploymentSettingsV1(username, domain, options).then((request) => request(axios, basePath));
|
|
15123
15353
|
},
|
|
15354
|
+
/**
|
|
15355
|
+
* Returns the public SSH key of the hosting account. `Deploy website Git repository` uses this key to clone and pull over SSH, so a private repository works once the key is added to it as a deploy key on the Git host. `public_key` is null when the account has no key yet.
|
|
15356
|
+
* @summary Get Git SSH public key
|
|
15357
|
+
* @param {string} username
|
|
15358
|
+
* @param {*} [options] Override http request option.
|
|
15359
|
+
* @throws {RequiredError}
|
|
15360
|
+
*/
|
|
15361
|
+
getGitSSHPublicKeyV1(username, options) {
|
|
15362
|
+
return localVarFp.getGitSSHPublicKeyV1(username, options).then((request) => request(axios, basePath));
|
|
15363
|
+
},
|
|
15124
15364
|
/**
|
|
15125
15365
|
* Lists the repositories the Git installation can access, read live from the provider. Works for github and gitlab installations. Use an active installation: a suspended or pending one is still queried and the call fails with whatever the provider answers. The list is cut at the first 500 repositories in the order the provider returns them; when the account has more, name the repository directly instead of searching this list. `owner`, `name` and a branch (`default_branch` or another one) go into `source_options` of `Start Node.js build` or into `Update Git auto-deployment settings`. Returns 404 when the installation does not belong to the customer. Limited to 10 calls per minute per API client (429 above that).
|
|
15126
15366
|
* @summary List Git installation repositories
|
|
@@ -15142,6 +15382,17 @@ export const HostingGitApiFactory = function (configuration, basePath, axios) {
|
|
|
15142
15382
|
listGitInstallationsV1(provider, status, options) {
|
|
15143
15383
|
return localVarFp.listGitInstallationsV1(provider, status, options).then((request) => request(axios, basePath));
|
|
15144
15384
|
},
|
|
15385
|
+
/**
|
|
15386
|
+
* Lists the Git repositories linked to directories of the website, with `Deploy website Git repository` or in the Git section of hPanel: clone URL, branch and directory of each one. A repository whose clone failed stays listed; deploying it again retries the clone. GitHub and GitLab auto-deployments are not listed here; see `Get Git auto-deployment settings`.
|
|
15387
|
+
* @summary List website Git repositories
|
|
15388
|
+
* @param {string} username
|
|
15389
|
+
* @param {string} domain Domain name
|
|
15390
|
+
* @param {*} [options] Override http request option.
|
|
15391
|
+
* @throws {RequiredError}
|
|
15392
|
+
*/
|
|
15393
|
+
listWebsiteGitRepositoriesV1(username, domain, options) {
|
|
15394
|
+
return localVarFp.listWebsiteGitRepositoriesV1(username, domain, options).then((request) => request(axios, basePath));
|
|
15395
|
+
},
|
|
15145
15396
|
/**
|
|
15146
15397
|
* Creates or replaces the Git auto-deployment settings of the website: repository, branch, the directory under the document root to deploy into, and `is_enabled`. Send the full set; `is_enabled` defaults to true and `directory` to the document root. `installation_uuid` must be an installation from `List Git installations` that belongs to the same customer as the website. For PHP and static websites, saving with `is_enabled` true deploys the branch right away and every later push to that branch deploys again. For Node.js and Website Builder websites saving does not clone anything. On a Node.js website start the first deploy with `Start Node.js build` using `source_type` `git`; pushes then trigger new builds with the build settings stored for the website.
|
|
15147
15398
|
* @summary Update Git auto-deployment settings
|
|
@@ -15175,6 +15426,30 @@ export class HostingGitApi extends BaseAPI {
|
|
|
15175
15426
|
deleteGitAutoDeploymentSettingsV1(username, domain, options) {
|
|
15176
15427
|
return HostingGitApiFp(this.configuration).deleteGitAutoDeploymentSettingsV1(username, domain, options).then((request) => request(this.axios, this.basePath));
|
|
15177
15428
|
}
|
|
15429
|
+
/**
|
|
15430
|
+
* Clones a Git repository into a directory of the website, or pulls it again. An empty or missing directory gets a clone of the branch. A directory that already holds this repository and branch is reset to its last commit and pulled: changes made on the server to files the repository tracks are discarded, files it does not track stay. A directory that holds other files, including another repository or another branch of this one, is rejected. `composer install` runs after the clone or pull when the repository has a `composer.json`. The call waits for the deployment and returns its log. `is_success` false means Git or composer failed and the log says why. A second call for the same directory is rejected while the first is still waiting for the server. If the request times out, the deployment may still finish on the server; calling again later with the same repository and branch pulls. Private repositories need an SSH URL and the account\'s Git SSH key from `Generate Git SSH key`, added to the repository as a deploy key.
|
|
15431
|
+
* @summary Deploy website Git repository
|
|
15432
|
+
* @param {string} username
|
|
15433
|
+
* @param {string} domain Domain name
|
|
15434
|
+
* @param {HostingV1GitDeployWebsiteGitRepositoryRequest} hostingV1GitDeployWebsiteGitRepositoryRequest
|
|
15435
|
+
* @param {*} [options] Override http request option.
|
|
15436
|
+
* @throws {RequiredError}
|
|
15437
|
+
* @memberof HostingGitApi
|
|
15438
|
+
*/
|
|
15439
|
+
deployWebsiteGitRepositoryV1(username, domain, hostingV1GitDeployWebsiteGitRepositoryRequest, options) {
|
|
15440
|
+
return HostingGitApiFp(this.configuration).deployWebsiteGitRepositoryV1(username, domain, hostingV1GitDeployWebsiteGitRepositoryRequest, options).then((request) => request(this.axios, this.basePath));
|
|
15441
|
+
}
|
|
15442
|
+
/**
|
|
15443
|
+
* Creates the SSH key pair of the hosting account and returns the public key. When the account already has a key, returns that key unchanged. One key serves every website of the account; add the public key to a private repository as a deploy key before deploying it.
|
|
15444
|
+
* @summary Generate Git SSH key
|
|
15445
|
+
* @param {string} username
|
|
15446
|
+
* @param {*} [options] Override http request option.
|
|
15447
|
+
* @throws {RequiredError}
|
|
15448
|
+
* @memberof HostingGitApi
|
|
15449
|
+
*/
|
|
15450
|
+
generateGitSSHKeyV1(username, options) {
|
|
15451
|
+
return HostingGitApiFp(this.configuration).generateGitSSHKeyV1(username, options).then((request) => request(this.axios, this.basePath));
|
|
15452
|
+
}
|
|
15178
15453
|
/**
|
|
15179
15454
|
* Returns the Git auto-deployment settings of the website: which repository and branch deploy into which directory, and whether pushes trigger a deployment. `is_enabled` false keeps the repository link but ignores pushes. When the website has no auto-deployment configured every field is null. Save settings with `Update Git auto-deployment settings`.
|
|
15180
15455
|
* @summary Get Git auto-deployment settings
|
|
@@ -15187,6 +15462,17 @@ export class HostingGitApi extends BaseAPI {
|
|
|
15187
15462
|
getGitAutoDeploymentSettingsV1(username, domain, options) {
|
|
15188
15463
|
return HostingGitApiFp(this.configuration).getGitAutoDeploymentSettingsV1(username, domain, options).then((request) => request(this.axios, this.basePath));
|
|
15189
15464
|
}
|
|
15465
|
+
/**
|
|
15466
|
+
* Returns the public SSH key of the hosting account. `Deploy website Git repository` uses this key to clone and pull over SSH, so a private repository works once the key is added to it as a deploy key on the Git host. `public_key` is null when the account has no key yet.
|
|
15467
|
+
* @summary Get Git SSH public key
|
|
15468
|
+
* @param {string} username
|
|
15469
|
+
* @param {*} [options] Override http request option.
|
|
15470
|
+
* @throws {RequiredError}
|
|
15471
|
+
* @memberof HostingGitApi
|
|
15472
|
+
*/
|
|
15473
|
+
getGitSSHPublicKeyV1(username, options) {
|
|
15474
|
+
return HostingGitApiFp(this.configuration).getGitSSHPublicKeyV1(username, options).then((request) => request(this.axios, this.basePath));
|
|
15475
|
+
}
|
|
15190
15476
|
/**
|
|
15191
15477
|
* Lists the repositories the Git installation can access, read live from the provider. Works for github and gitlab installations. Use an active installation: a suspended or pending one is still queried and the call fails with whatever the provider answers. The list is cut at the first 500 repositories in the order the provider returns them; when the account has more, name the repository directly instead of searching this list. `owner`, `name` and a branch (`default_branch` or another one) go into `source_options` of `Start Node.js build` or into `Update Git auto-deployment settings`. Returns 404 when the installation does not belong to the customer. Limited to 10 calls per minute per API client (429 above that).
|
|
15192
15478
|
* @summary List Git installation repositories
|
|
@@ -15210,6 +15496,18 @@ export class HostingGitApi extends BaseAPI {
|
|
|
15210
15496
|
listGitInstallationsV1(provider, status, options) {
|
|
15211
15497
|
return HostingGitApiFp(this.configuration).listGitInstallationsV1(provider, status, options).then((request) => request(this.axios, this.basePath));
|
|
15212
15498
|
}
|
|
15499
|
+
/**
|
|
15500
|
+
* Lists the Git repositories linked to directories of the website, with `Deploy website Git repository` or in the Git section of hPanel: clone URL, branch and directory of each one. A repository whose clone failed stays listed; deploying it again retries the clone. GitHub and GitLab auto-deployments are not listed here; see `Get Git auto-deployment settings`.
|
|
15501
|
+
* @summary List website Git repositories
|
|
15502
|
+
* @param {string} username
|
|
15503
|
+
* @param {string} domain Domain name
|
|
15504
|
+
* @param {*} [options] Override http request option.
|
|
15505
|
+
* @throws {RequiredError}
|
|
15506
|
+
* @memberof HostingGitApi
|
|
15507
|
+
*/
|
|
15508
|
+
listWebsiteGitRepositoriesV1(username, domain, options) {
|
|
15509
|
+
return HostingGitApiFp(this.configuration).listWebsiteGitRepositoriesV1(username, domain, options).then((request) => request(this.axios, this.basePath));
|
|
15510
|
+
}
|
|
15213
15511
|
/**
|
|
15214
15512
|
* Creates or replaces the Git auto-deployment settings of the website: repository, branch, the directory under the document root to deploy into, and `is_enabled`. Send the full set; `is_enabled` defaults to true and `directory` to the document root. `installation_uuid` must be an installation from `List Git installations` that belongs to the same customer as the website. For PHP and static websites, saving with `is_enabled` true deploys the branch right away and every later push to that branch deploys again. For Node.js and Website Builder websites saving does not clone anything. On a Node.js website start the first deploy with `Start Node.js build` using `source_type` `git`; pushes then trigger new builds with the build settings stored for the website.
|
|
15215
15513
|
* @summary Update Git auto-deployment settings
|
package/dist/esm/base.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Hostinger API
|
|
3
3
|
*
|
|
4
|
-
* API Version: 1.
|
|
4
|
+
* API Version: 1.58.1
|
|
5
5
|
*
|
|
6
6
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
7
7
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
package/dist/esm/base.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.
|
|
6
|
+
* API Version: 1.58.1
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
9
9
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
package/dist/esm/common.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Hostinger API
|
|
3
3
|
*
|
|
4
|
-
* API Version: 1.
|
|
4
|
+
* API Version: 1.58.1
|
|
5
5
|
*
|
|
6
6
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
7
7
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
package/dist/esm/common.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.
|
|
6
|
+
* API Version: 1.58.1
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
9
9
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Hostinger API
|
|
3
3
|
*
|
|
4
|
-
* API Version: 1.
|
|
4
|
+
* API Version: 1.58.1
|
|
5
5
|
*
|
|
6
6
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
7
7
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.
|
|
6
|
+
* API Version: 1.58.1
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
9
9
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
|
@@ -13,7 +13,7 @@ export class Configuration {
|
|
|
13
13
|
var _a;
|
|
14
14
|
this.accessToken = param.accessToken;
|
|
15
15
|
this.basePath = param.basePath;
|
|
16
|
-
this.baseOptions = Object.assign(Object.assign({}, param.baseOptions), { headers: Object.assign({ 'User-Agent': "hostinger-typescript-sdk/1.
|
|
16
|
+
this.baseOptions = Object.assign(Object.assign({}, param.baseOptions), { headers: Object.assign({ 'User-Agent': "hostinger-typescript-sdk/1.58.1" }, (_a = param.baseOptions) === null || _a === void 0 ? void 0 : _a.headers) });
|
|
17
17
|
this.formDataCtor = param.formDataCtor;
|
|
18
18
|
}
|
|
19
19
|
/**
|
package/dist/esm/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Hostinger API
|
|
3
3
|
*
|
|
4
|
-
* API Version: 1.
|
|
4
|
+
* API Version: 1.58.1
|
|
5
5
|
*
|
|
6
6
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
7
7
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
package/dist/esm/index.js
CHANGED
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
/**
|
|
4
4
|
* Hostinger API
|
|
5
5
|
*
|
|
6
|
-
* API Version: 1.
|
|
6
|
+
* API Version: 1.58.1
|
|
7
7
|
*
|
|
8
8
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
9
9
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
package/dist/index.d.ts
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* Hostinger API
|
|
3
3
|
*
|
|
4
|
-
* API Version: 1.
|
|
4
|
+
* API Version: 1.58.1
|
|
5
5
|
*
|
|
6
6
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
7
7
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|
package/dist/index.js
CHANGED
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
/**
|
|
5
5
|
* Hostinger API
|
|
6
6
|
*
|
|
7
|
-
* API Version: 1.
|
|
7
|
+
* API Version: 1.58.1
|
|
8
8
|
*
|
|
9
9
|
* NOTE: This file is auto-generated, DO NOT EDIT THIS FILE MANUALLY!
|
|
10
10
|
* If you want to contribute or request a new feature, please create an issue or pull request on https://github.com/hostinger/api
|