hostinger-api-mcp 1.43.1 → 1.44.0
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 +181 -4
- package/gemini-extension.json +1 -1
- package/package.json +1 -1
- package/server.json +2 -2
- package/src/core/runtime.js +1 -1
- package/src/core/runtime.ts +1 -1
- package/src/core/tools/agency-hosting.js +24 -0
- package/src/core/tools/agency-hosting.ts +24 -0
- package/src/core/tools/all.js +356 -1
- package/src/core/tools/all.ts +356 -1
- package/src/core/tools/hosting.js +211 -1
- package/src/core/tools/hosting.ts +211 -1
- package/src/core/tools/wordpress.js +121 -0
- package/src/core/tools/wordpress.ts +121 -0
- package/src/servers/agency-hosting.js +1 -1
- package/src/servers/agency-hosting.ts +1 -1
- package/src/servers/all.js +1 -1
- package/src/servers/all.ts +1 -1
- package/src/servers/billing.js +1 -1
- package/src/servers/billing.ts +1 -1
- package/src/servers/dns.js +1 -1
- package/src/servers/dns.ts +1 -1
- package/src/servers/domains.js +1 -1
- package/src/servers/domains.ts +1 -1
- package/src/servers/ecommerce.js +1 -1
- package/src/servers/ecommerce.ts +1 -1
- package/src/servers/horizons.js +1 -1
- package/src/servers/horizons.ts +1 -1
- package/src/servers/hosting.js +1 -1
- package/src/servers/hosting.ts +1 -1
- package/src/servers/mail.js +1 -1
- package/src/servers/mail.ts +1 -1
- package/src/servers/reach.js +1 -1
- package/src/servers/reach.ts +1 -1
- package/src/servers/vps.js +1 -1
- package/src/servers/vps.ts +1 -1
- package/src/servers/wordpress.js +1 -1
- package/src/servers/wordpress.ts +1 -1
- package/types.d.ts +325 -0
package/README.md
CHANGED
|
@@ -69,18 +69,18 @@ pnpm update -g hostinger-api-mcp
|
|
|
69
69
|
|
|
70
70
|
This package installs the following MCP server commands:
|
|
71
71
|
|
|
72
|
-
- `hostinger-api-mcp` — unified server with every tool (
|
|
73
|
-
- `hostinger-agency-hosting-mcp` —
|
|
72
|
+
- `hostinger-api-mcp` — unified server with every tool (350 total)
|
|
73
|
+
- `hostinger-agency-hosting-mcp` — 37 tools for agency-hosting
|
|
74
74
|
- `hostinger-billing-mcp` — 9 tools for billing
|
|
75
75
|
- `hostinger-dns-mcp` — 8 tools for dns
|
|
76
76
|
- `hostinger-domains-mcp` — 40 tools for domains
|
|
77
77
|
- `hostinger-ecommerce-mcp` — 14 tools for ecommerce
|
|
78
78
|
- `hostinger-horizons-mcp` — 2 tools for horizons
|
|
79
|
-
- `hostinger-hosting-mcp` —
|
|
79
|
+
- `hostinger-hosting-mcp` — 57 tools for hosting
|
|
80
80
|
- `hostinger-mail-mcp` — 38 tools for mail
|
|
81
81
|
- `hostinger-reach-mcp` — 45 tools for reach
|
|
82
82
|
- `hostinger-vps-mcp` — 62 tools for vps
|
|
83
|
-
- `hostinger-wordpress-mcp` —
|
|
83
|
+
- `hostinger-wordpress-mcp` — 38 tools for wordpress
|
|
84
84
|
|
|
85
85
|
Pick the binary that matches your agent's scope. `hostinger-api-mcp` remains the backwards-compatible default.
|
|
86
86
|
|
|
@@ -289,6 +289,49 @@ If this is the only domain on the website, unlinking leaves the website without
|
|
|
289
289
|
- **Method**: `DELETE`
|
|
290
290
|
- **Path**: `/api/agency-hosting/v1/websites/{website_uid}/domains/{domain}`
|
|
291
291
|
|
|
292
|
+
#### agency-hosting_generateUploadURLV1
|
|
293
|
+
|
|
294
|
+
Generate a file browser upload URL with authentication credentials for uploading files
|
|
295
|
+
to an Agency Plan website's file storage.
|
|
296
|
+
|
|
297
|
+
Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the
|
|
298
|
+
website's file storage via the TUS resumable upload protocol (TUS 1.0.0). Send
|
|
299
|
+
`X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below.
|
|
300
|
+
|
|
301
|
+
1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers
|
|
302
|
+
`upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`.
|
|
303
|
+
2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or
|
|
304
|
+
`PATCH` requests with an `upload-offset` header tracking progress) until complete.
|
|
305
|
+
|
|
306
|
+
`relative_file_path` is the destination path inside the website's file storage, e.g.
|
|
307
|
+
`app.zip`.
|
|
308
|
+
|
|
309
|
+
Instead of a TUS client, plain `curl` also works:
|
|
310
|
+
```
|
|
311
|
+
FILE=app.zip
|
|
312
|
+
SIZE=$(stat -f%z "$FILE") # stat -c%s on Linux
|
|
313
|
+
|
|
314
|
+
curl -i -X POST "{url}/${FILE}?override=true" \
|
|
315
|
+
-H "X-Auth: {auth_key}" \
|
|
316
|
+
-H "X-Auth-Rest: {rest_auth_key}" \
|
|
317
|
+
-H "Tus-Resumable: 1.0.0" \
|
|
318
|
+
-H "Upload-Length: ${SIZE}" \
|
|
319
|
+
-H "Upload-Offset: 0"
|
|
320
|
+
# -> 201 Created
|
|
321
|
+
|
|
322
|
+
curl -i -X PATCH "{url}/${FILE}?override=true" \
|
|
323
|
+
-H "X-Auth: {auth_key}" \
|
|
324
|
+
-H "X-Auth-Rest: {rest_auth_key}" \
|
|
325
|
+
-H "Tus-Resumable: 1.0.0" \
|
|
326
|
+
-H "Content-Type: application/offset+octet-stream" \
|
|
327
|
+
-H "Upload-Offset: 0" \
|
|
328
|
+
--data-binary "@${FILE}"
|
|
329
|
+
# -> 204 No Content, Upload-Offset response header equals SIZE when done
|
|
330
|
+
```
|
|
331
|
+
|
|
332
|
+
- **Method**: `POST`
|
|
333
|
+
- **Path**: `/api/agency-hosting/v1/websites/{website_uid}/files/upload-urls`
|
|
334
|
+
|
|
292
335
|
#### agency-hosting_importWebsiteFromArchiveV1
|
|
293
336
|
|
|
294
337
|
Imports an Agency Plan website from an already-uploaded archive.
|
|
@@ -1684,6 +1727,49 @@ Skip this verification when using Hostinger's free subdomains (*.hostingersite.c
|
|
|
1684
1727
|
- **Method**: `POST`
|
|
1685
1728
|
- **Path**: `/api/hosting/v1/domains/verify-ownership`
|
|
1686
1729
|
|
|
1730
|
+
#### hosting_generateUploadURLV1
|
|
1731
|
+
|
|
1732
|
+
Generate a file browser upload URL with authentication credentials
|
|
1733
|
+
for uploading files directly to a website's file storage.
|
|
1734
|
+
|
|
1735
|
+
Returns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the
|
|
1736
|
+
website's `public_html` directory via the TUS resumable upload protocol (TUS 1.0.0).
|
|
1737
|
+
Send `X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request
|
|
1738
|
+
below.
|
|
1739
|
+
|
|
1740
|
+
1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers
|
|
1741
|
+
`upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`.
|
|
1742
|
+
2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or
|
|
1743
|
+
`PATCH` requests with an `upload-offset` header tracking progress) until complete.
|
|
1744
|
+
|
|
1745
|
+
`relative_file_path` is the destination path inside `public_html`, e.g. `app.zip`.
|
|
1746
|
+
|
|
1747
|
+
Instead of a TUS client, plain `curl` also works:
|
|
1748
|
+
```
|
|
1749
|
+
FILE=app.zip
|
|
1750
|
+
SIZE=$(stat -f%z "$FILE") # stat -c%s on Linux
|
|
1751
|
+
|
|
1752
|
+
curl -i -X POST "{url}/${FILE}?override=true" \
|
|
1753
|
+
-H "X-Auth: {auth_key}" \
|
|
1754
|
+
-H "X-Auth-Rest: {rest_auth_key}" \
|
|
1755
|
+
-H "Tus-Resumable: 1.0.0" \
|
|
1756
|
+
-H "Upload-Length: ${SIZE}" \
|
|
1757
|
+
-H "Upload-Offset: 0"
|
|
1758
|
+
# -> 201 Created
|
|
1759
|
+
|
|
1760
|
+
curl -i -X PATCH "{url}/${FILE}?override=true" \
|
|
1761
|
+
-H "X-Auth: {auth_key}" \
|
|
1762
|
+
-H "X-Auth-Rest: {rest_auth_key}" \
|
|
1763
|
+
-H "Tus-Resumable: 1.0.0" \
|
|
1764
|
+
-H "Content-Type: application/offset+octet-stream" \
|
|
1765
|
+
-H "Upload-Offset: 0" \
|
|
1766
|
+
--data-binary "@${FILE}"
|
|
1767
|
+
# -> 204 No Content, Upload-Offset response header equals SIZE when done
|
|
1768
|
+
```
|
|
1769
|
+
|
|
1770
|
+
- **Method**: `POST`
|
|
1771
|
+
- **Path**: `/api/hosting/v1/files/upload-urls`
|
|
1772
|
+
|
|
1687
1773
|
#### hosting_listWebsiteFilesAndDirectoriesV1
|
|
1688
1774
|
|
|
1689
1775
|
List files and directories under a website's document root.
|
|
@@ -1715,10 +1801,34 @@ Use the `uuid` from a build to poll its output via the `Get Node.js Build Logs`
|
|
|
1715
1801
|
- **Method**: `GET`
|
|
1716
1802
|
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds`
|
|
1717
1803
|
|
|
1804
|
+
#### hosting_startNode_jsBuildV1
|
|
1805
|
+
|
|
1806
|
+
Start a Node.js build process using files already present on the website's file storage.
|
|
1807
|
+
|
|
1808
|
+
WARNING: on success this overwrites the website's existing contents and cannot be
|
|
1809
|
+
undone — verify this is intended before calling this endpoint.
|
|
1810
|
+
|
|
1811
|
+
The `source_type` must be `archive` and `source_options.archive_path` must point to an
|
|
1812
|
+
existing archive file on the server (relative to the website document root).
|
|
1813
|
+
Use the `Generate Upload URL` endpoint to obtain credentials and upload the archive first.
|
|
1814
|
+
|
|
1815
|
+
To auto-detect build settings from an archive before starting, first call the
|
|
1816
|
+
`Get Node.js Build Settings from Archive` endpoint. To upload an archive and start
|
|
1817
|
+
a build in one step, use the `Create Node.js Build from Archive` endpoint instead.
|
|
1818
|
+
|
|
1819
|
+
The returned build `uuid` can be used to poll progress and retrieve logs via
|
|
1820
|
+
the `Get Node.js Build Logs` endpoint.
|
|
1821
|
+
|
|
1822
|
+
- **Method**: `POST`
|
|
1823
|
+
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds`
|
|
1824
|
+
|
|
1718
1825
|
#### hosting_createNodeJSBuildFromArchiveV1
|
|
1719
1826
|
|
|
1720
1827
|
Upload a project archive, auto-detect build settings, and immediately start a Node.js build.
|
|
1721
1828
|
|
|
1829
|
+
WARNING: on success this overwrites the website's existing contents and cannot be
|
|
1830
|
+
undone — verify this is intended before calling this endpoint.
|
|
1831
|
+
|
|
1722
1832
|
This is the recommended single-step approach for deploying a Node.js application.
|
|
1723
1833
|
The archive is uploaded to the website's file storage, build settings are auto-detected
|
|
1724
1834
|
from the package.json inside the archive, and the build process starts automatically.
|
|
@@ -1741,6 +1851,22 @@ the `Get Node.js Build Logs` endpoint.
|
|
|
1741
1851
|
- **Method**: `POST`
|
|
1742
1852
|
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds/from-archive`
|
|
1743
1853
|
|
|
1854
|
+
#### hosting_getNode_jsBuildSettingsFromArchiveV1
|
|
1855
|
+
|
|
1856
|
+
Auto-detect Node.js build settings from a package.json inside an archive already on the server.
|
|
1857
|
+
|
|
1858
|
+
Use this before calling `Start Node.js Build` to preview what settings will be used,
|
|
1859
|
+
or to let the user review and override values (framework, node version, root directory,
|
|
1860
|
+
output directory, build script) before committing to a build.
|
|
1861
|
+
|
|
1862
|
+
The archive must already be present on the website's file storage. Use the
|
|
1863
|
+
`Generate Upload URL` endpoint to obtain credentials and upload the archive first.
|
|
1864
|
+
To upload an archive and start a build in one step without inspecting settings first,
|
|
1865
|
+
use the `Create Node.js Build from Archive` endpoint instead.
|
|
1866
|
+
|
|
1867
|
+
- **Method**: `GET`
|
|
1868
|
+
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/nodejs/builds/settings/from-archive`
|
|
1869
|
+
|
|
1744
1870
|
#### hosting_getNodeJSBuildLogsV1
|
|
1745
1871
|
|
|
1746
1872
|
Retrieve logs from a specific Node.js build process.
|
|
@@ -1941,6 +2067,24 @@ websites list endpoint to see when your new website becomes available.
|
|
|
1941
2067
|
- **Method**: `POST`
|
|
1942
2068
|
- **Path**: `/api/hosting/v1/websites`
|
|
1943
2069
|
|
|
2070
|
+
#### hosting_deployStaticSiteArchiveV1
|
|
2071
|
+
|
|
2072
|
+
Deploy a static application from an archive file.
|
|
2073
|
+
|
|
2074
|
+
WARNING: this overwrites the website's existing contents and cannot be undone —
|
|
2075
|
+
verify this is intended before calling this endpoint.
|
|
2076
|
+
|
|
2077
|
+
This endpoint allows you to deploy a static application from an archive
|
|
2078
|
+
file that has been uploaded to the website's directory.
|
|
2079
|
+
|
|
2080
|
+
This only works for static sites (pre-built HTML/CSS/JS with no build step). For
|
|
2081
|
+
Node.js applications, use `Create NodeJS build from archive` instead, or
|
|
2082
|
+
`Start Node.js build` if the archive is already uploaded. For WordPress sites,
|
|
2083
|
+
use `Import WordPress website`.
|
|
2084
|
+
|
|
2085
|
+
- **Method**: `POST`
|
|
2086
|
+
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/deploy`
|
|
2087
|
+
|
|
1944
2088
|
#### hosting_deleteWebsiteV1
|
|
1945
2089
|
|
|
1946
2090
|
This endpoint permanently removes a website and all of its data. This action
|
|
@@ -3579,6 +3723,19 @@ detected installations once the scan completes.
|
|
|
3579
3723
|
- **Method**: `POST`
|
|
3580
3724
|
- **Path**: `/api/hosting/v1/accounts/{username}/wordpress/installations/detect`
|
|
3581
3725
|
|
|
3726
|
+
#### hosting_importWordPressWebsiteV1
|
|
3727
|
+
|
|
3728
|
+
Import WordPress website to the specified domain.
|
|
3729
|
+
|
|
3730
|
+
WARNING: this overwrites the website's existing contents and cannot be undone —
|
|
3731
|
+
verify this is intended before calling this endpoint.
|
|
3732
|
+
|
|
3733
|
+
This endpoint allows you to import a WordPress website from archive and
|
|
3734
|
+
database files that have been uploaded to the website's directory.
|
|
3735
|
+
|
|
3736
|
+
- **Method**: `POST`
|
|
3737
|
+
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/wordpress/import`
|
|
3738
|
+
|
|
3582
3739
|
#### hosting_installWordPressV1
|
|
3583
3740
|
|
|
3584
3741
|
Install WordPress on an existing website.
|
|
@@ -3761,6 +3918,16 @@ deactivation job has been queued.
|
|
|
3761
3918
|
- **Method**: `POST`
|
|
3762
3919
|
- **Path**: `/api/hosting/v1/accounts/{username}/wordpress/{software}/plugins/deactivate`
|
|
3763
3920
|
|
|
3921
|
+
#### hosting_deployWordPressPluginV1
|
|
3922
|
+
|
|
3923
|
+
Deploy a WordPress plugin from an already uploaded directory.
|
|
3924
|
+
|
|
3925
|
+
This endpoint allows you to deploy a WordPress plugin that has been uploaded to the website's directory.
|
|
3926
|
+
The plugin will be activated and made available in the WordPress admin panel.
|
|
3927
|
+
|
|
3928
|
+
- **Method**: `POST`
|
|
3929
|
+
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/wordpress/plugins/deploy`
|
|
3930
|
+
|
|
3764
3931
|
#### hosting_installWordPressPluginsV1
|
|
3765
3932
|
|
|
3766
3933
|
Install one or more plugins on an existing WordPress installation.
|
|
@@ -3879,6 +4046,16 @@ job has been queued.
|
|
|
3879
4046
|
- **Method**: `POST`
|
|
3880
4047
|
- **Path**: `/api/hosting/v1/accounts/{username}/wordpress/{software}/themes/activate`
|
|
3881
4048
|
|
|
4049
|
+
#### hosting_deployWordPressThemeV1
|
|
4050
|
+
|
|
4051
|
+
Deploy a WordPress theme from an already uploaded directory.
|
|
4052
|
+
|
|
4053
|
+
This endpoint allows you to deploy a WordPress theme that has been uploaded to the website's directory.
|
|
4054
|
+
The theme can be optionally activated after deployment.
|
|
4055
|
+
|
|
4056
|
+
- **Method**: `POST`
|
|
4057
|
+
- **Path**: `/api/hosting/v1/accounts/{username}/websites/{domain}/wordpress/themes/deploy`
|
|
4058
|
+
|
|
3882
4059
|
#### hosting_installWordPressThemeV1
|
|
3883
4060
|
|
|
3884
4061
|
Install a theme on an existing WordPress installation.
|
package/gemini-extension.json
CHANGED
package/package.json
CHANGED
package/server.json
CHANGED
|
@@ -6,12 +6,12 @@
|
|
|
6
6
|
"url": "https://github.com/hostinger/api-mcp-server",
|
|
7
7
|
"source": "github"
|
|
8
8
|
},
|
|
9
|
-
"version": "1.
|
|
9
|
+
"version": "1.44.0",
|
|
10
10
|
"packages": [
|
|
11
11
|
{
|
|
12
12
|
"registryType": "npm",
|
|
13
13
|
"identifier": "hostinger-api-mcp",
|
|
14
|
-
"version": "1.
|
|
14
|
+
"version": "1.44.0",
|
|
15
15
|
"transport": {
|
|
16
16
|
"type": "stdio"
|
|
17
17
|
},
|
package/src/core/runtime.js
CHANGED
package/src/core/runtime.ts
CHANGED
|
@@ -218,6 +218,30 @@ export default [
|
|
|
218
218
|
],
|
|
219
219
|
"group": "agency-hosting"
|
|
220
220
|
},
|
|
221
|
+
{
|
|
222
|
+
"name": "agency-hosting_generateUploadURLV1",
|
|
223
|
+
"description": "Generate a file browser upload URL with authentication credentials for uploading files\nto an Agency Plan website's file storage.\n\nReturns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the\nwebsite's file storage via the TUS resumable upload protocol (TUS 1.0.0). Send\n`X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below.\n\n1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers\n `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`.\n2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or\n `PATCH` requests with an `upload-offset` header tracking progress) until complete.\n\n`relative_file_path` is the destination path inside the website's file storage, e.g.\n`app.zip`.\n\nInstead of a TUS client, plain `curl` also works:\n```\nFILE=app.zip\nSIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux\n\ncurl -i -X POST \"{url}/${FILE}?override=true\" \\\n -H \"X-Auth: {auth_key}\" \\\n -H \"X-Auth-Rest: {rest_auth_key}\" \\\n -H \"Tus-Resumable: 1.0.0\" \\\n -H \"Upload-Length: ${SIZE}\" \\\n -H \"Upload-Offset: 0\"\n# -> 201 Created\n\ncurl -i -X PATCH \"{url}/${FILE}?override=true\" \\\n -H \"X-Auth: {auth_key}\" \\\n -H \"X-Auth-Rest: {rest_auth_key}\" \\\n -H \"Tus-Resumable: 1.0.0\" \\\n -H \"Content-Type: application/offset+octet-stream\" \\\n -H \"Upload-Offset: 0\" \\\n --data-binary \"@${FILE}\"\n# -> 204 No Content, Upload-Offset response header equals SIZE when done\n```",
|
|
224
|
+
"method": "POST",
|
|
225
|
+
"path": "/api/agency-hosting/v1/websites/{website_uid}/files/upload-urls",
|
|
226
|
+
"inputSchema": {
|
|
227
|
+
"type": "object",
|
|
228
|
+
"properties": {
|
|
229
|
+
"website_uid": {
|
|
230
|
+
"type": "string",
|
|
231
|
+
"description": "Agency Plan website UID"
|
|
232
|
+
}
|
|
233
|
+
},
|
|
234
|
+
"required": [
|
|
235
|
+
"website_uid"
|
|
236
|
+
]
|
|
237
|
+
},
|
|
238
|
+
"security": [
|
|
239
|
+
{
|
|
240
|
+
"apiToken": []
|
|
241
|
+
}
|
|
242
|
+
],
|
|
243
|
+
"group": "agency-hosting"
|
|
244
|
+
},
|
|
221
245
|
{
|
|
222
246
|
"name": "agency-hosting_importWebsiteFromArchiveV1",
|
|
223
247
|
"description": "Imports an Agency Plan website from an already-uploaded archive.\n\nUpload the archive to the website's root directory via file browser first, then provide its\nfilename in this request. Website contents are overwritten by the archive contents. Supported\narchive types: .zip, .tar, .tar.gz, .tgz.",
|
|
@@ -232,6 +232,30 @@ const tools: OpenApiTool[] = [
|
|
|
232
232
|
],
|
|
233
233
|
"group": "agency-hosting"
|
|
234
234
|
},
|
|
235
|
+
{
|
|
236
|
+
"name": "agency-hosting_generateUploadURLV1",
|
|
237
|
+
"description": "Generate a file browser upload URL with authentication credentials for uploading files\nto an Agency Plan website's file storage.\n\nReturns `url`, `auth_key` and `rest_auth_key`. Use these to upload a file to the\nwebsite's file storage via the TUS resumable upload protocol (TUS 1.0.0). Send\n`X-Auth: {auth_key}` and `X-Auth-Rest: {rest_auth_key}` headers on every request below.\n\n1. Create the upload: `POST` to `{url}/{relative_file_path}?override=true` with headers\n `upload-length: {file size in bytes}` and `upload-offset: 0`. Expect `201 Created`.\n2. Upload the file: send the file bytes to the same location (any TUS 1.0.0 client, or\n `PATCH` requests with an `upload-offset` header tracking progress) until complete.\n\n`relative_file_path` is the destination path inside the website's file storage, e.g.\n`app.zip`.\n\nInstead of a TUS client, plain `curl` also works:\n```\nFILE=app.zip\nSIZE=$(stat -f%z \"$FILE\") # stat -c%s on Linux\n\ncurl -i -X POST \"{url}/${FILE}?override=true\" \\\n -H \"X-Auth: {auth_key}\" \\\n -H \"X-Auth-Rest: {rest_auth_key}\" \\\n -H \"Tus-Resumable: 1.0.0\" \\\n -H \"Upload-Length: ${SIZE}\" \\\n -H \"Upload-Offset: 0\"\n# -> 201 Created\n\ncurl -i -X PATCH \"{url}/${FILE}?override=true\" \\\n -H \"X-Auth: {auth_key}\" \\\n -H \"X-Auth-Rest: {rest_auth_key}\" \\\n -H \"Tus-Resumable: 1.0.0\" \\\n -H \"Content-Type: application/offset+octet-stream\" \\\n -H \"Upload-Offset: 0\" \\\n --data-binary \"@${FILE}\"\n# -> 204 No Content, Upload-Offset response header equals SIZE when done\n```",
|
|
238
|
+
"method": "POST",
|
|
239
|
+
"path": "/api/agency-hosting/v1/websites/{website_uid}/files/upload-urls",
|
|
240
|
+
"inputSchema": {
|
|
241
|
+
"type": "object",
|
|
242
|
+
"properties": {
|
|
243
|
+
"website_uid": {
|
|
244
|
+
"type": "string",
|
|
245
|
+
"description": "Agency Plan website UID"
|
|
246
|
+
}
|
|
247
|
+
},
|
|
248
|
+
"required": [
|
|
249
|
+
"website_uid"
|
|
250
|
+
]
|
|
251
|
+
},
|
|
252
|
+
"security": [
|
|
253
|
+
{
|
|
254
|
+
"apiToken": []
|
|
255
|
+
}
|
|
256
|
+
],
|
|
257
|
+
"group": "agency-hosting"
|
|
258
|
+
},
|
|
235
259
|
{
|
|
236
260
|
"name": "agency-hosting_importWebsiteFromArchiveV1",
|
|
237
261
|
"description": "Imports an Agency Plan website from an already-uploaded archive.\n\nUpload the archive to the website's root directory via file browser first, then provide its\nfilename in this request. Website contents are overwritten by the archive contents. Supported\narchive types: .zip, .tar, .tar.gz, .tgz.",
|