hostinger-api-mcp 1.56.0 → 1.57.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/CHANGELOG.md +25 -0
- package/README.md +83 -2
- 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/all.js +317 -0
- package/src/core/tools/all.ts +317 -0
- package/src/core/tools/hosting.js +317 -0
- package/src/core/tools/hosting.ts +317 -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 +198 -0
package/types.d.ts
CHANGED
|
@@ -3727,6 +3727,85 @@ the `Get Node.js Build Logs` endpoint.
|
|
|
3727
3727
|
response: any; // Response structure will depend on the API
|
|
3728
3728
|
};
|
|
3729
3729
|
|
|
3730
|
+
/**
|
|
3731
|
+
* Returns the build settings stored for the website: framework (`app_type`), Node.js version,
|
|
3732
|
+
root and output directory, build script, entry file and package manager. Stored settings
|
|
3733
|
+
drive Git auto-deployment builds. A build started through the API uses the values sent in
|
|
3734
|
+
that request and saves them here only when no settings exist yet.
|
|
3735
|
+
|
|
3736
|
+
Returns 404 until the first build or the first settings update stores them. Use this after
|
|
3737
|
+
a failed build to check whether the framework or the entry file were detected wrong, then
|
|
3738
|
+
fix them with the `Update Node.js build settings` endpoint.
|
|
3739
|
+
*/
|
|
3740
|
+
"hosting_getNode_jsBuildSettingsV1": {
|
|
3741
|
+
params: {
|
|
3742
|
+
/**
|
|
3743
|
+
* username parameter
|
|
3744
|
+
*/
|
|
3745
|
+
username: string;
|
|
3746
|
+
/**
|
|
3747
|
+
* Domain name
|
|
3748
|
+
*/
|
|
3749
|
+
domain: string;
|
|
3750
|
+
};
|
|
3751
|
+
response: any; // Response structure will depend on the API
|
|
3752
|
+
};
|
|
3753
|
+
|
|
3754
|
+
/**
|
|
3755
|
+
* Replaces the build settings stored for the website. Send the full set: `node_version` is
|
|
3756
|
+
required and every nullable field you omit is stored as null. Creates the settings when
|
|
3757
|
+
none exist yet.
|
|
3758
|
+
|
|
3759
|
+
This does not start a build. Stored settings drive Git auto-deployment builds; a build
|
|
3760
|
+
started through the API uses the values sent in that request, so to rebuild with corrected
|
|
3761
|
+
settings call `Start Node.js build` with the same values. Typical fixes: a wrong `app_type`
|
|
3762
|
+
after auto-detection, or a missing `entry_file` for express, fastify, nest, nuxt and hono
|
|
3763
|
+
apps.
|
|
3764
|
+
*/
|
|
3765
|
+
"hosting_updateNode_jsBuildSettingsV1": {
|
|
3766
|
+
params: {
|
|
3767
|
+
/**
|
|
3768
|
+
* username parameter
|
|
3769
|
+
*/
|
|
3770
|
+
username: string;
|
|
3771
|
+
/**
|
|
3772
|
+
* Domain name
|
|
3773
|
+
*/
|
|
3774
|
+
domain: string;
|
|
3775
|
+
/**
|
|
3776
|
+
* Node.js major version
|
|
3777
|
+
*/
|
|
3778
|
+
node_version: number;
|
|
3779
|
+
/**
|
|
3780
|
+
* Node.js application framework. Set it explicitly when auto-detection picked the wrong one.
|
|
3781
|
+
*/
|
|
3782
|
+
app_type?: string;
|
|
3783
|
+
/**
|
|
3784
|
+
* Application root directory (where package.json is located) relative to public_html.
|
|
3785
|
+
Omit it, or send ".", for public_html itself.
|
|
3786
|
+
*/
|
|
3787
|
+
root_directory?: string;
|
|
3788
|
+
/**
|
|
3789
|
+
* Build output directory relative to the root directory
|
|
3790
|
+
*/
|
|
3791
|
+
output_directory?: string;
|
|
3792
|
+
/**
|
|
3793
|
+
* The package.json script that builds the application
|
|
3794
|
+
*/
|
|
3795
|
+
build_script?: string;
|
|
3796
|
+
/**
|
|
3797
|
+
* The main entry point file for the application
|
|
3798
|
+
(required for express, fastify, nest, nuxt and hono app types)
|
|
3799
|
+
*/
|
|
3800
|
+
entry_file?: string;
|
|
3801
|
+
/**
|
|
3802
|
+
* Package manager used to install dependencies
|
|
3803
|
+
*/
|
|
3804
|
+
package_manager?: string;
|
|
3805
|
+
};
|
|
3806
|
+
response: any; // Response structure will depend on the API
|
|
3807
|
+
};
|
|
3808
|
+
|
|
3730
3809
|
/**
|
|
3731
3810
|
* Auto-detect Node.js build settings from a package.json inside an archive already on the server.
|
|
3732
3811
|
|
|
@@ -3814,6 +3893,57 @@ this list is deleted, and an empty array deletes every variable.
|
|
|
3814
3893
|
response: any; // Response structure will depend on the API
|
|
3815
3894
|
};
|
|
3816
3895
|
|
|
3896
|
+
/**
|
|
3897
|
+
* Returns an AI analysis of why a build failed and how to fix it, based on the build logs,
|
|
3898
|
+
the project file list and package.json. Only builds in the `failed` state can be analysed;
|
|
3899
|
+
any other state returns 422. When no analysis could be produced both `analysis` and
|
|
3900
|
+
`solution` are null, in which case read `Get NodeJS build logs` instead.
|
|
3901
|
+
|
|
3902
|
+
Each call runs the analysis again, so call it once per failed build and keep the result.
|
|
3903
|
+
Limited to 5 calls per minute per API client (429 above that).
|
|
3904
|
+
*/
|
|
3905
|
+
"hosting_analyseFailedNode_jsBuildV1": {
|
|
3906
|
+
params: {
|
|
3907
|
+
/**
|
|
3908
|
+
* username parameter
|
|
3909
|
+
*/
|
|
3910
|
+
username: string;
|
|
3911
|
+
/**
|
|
3912
|
+
* Domain name
|
|
3913
|
+
*/
|
|
3914
|
+
domain: string;
|
|
3915
|
+
/**
|
|
3916
|
+
* Build UUID
|
|
3917
|
+
*/
|
|
3918
|
+
uuid: string;
|
|
3919
|
+
};
|
|
3920
|
+
response: any; // Response structure will depend on the API
|
|
3921
|
+
};
|
|
3922
|
+
|
|
3923
|
+
/**
|
|
3924
|
+
* Returns one build by UUID: its state (`pending`, `running`, `completed`, `failed`), the
|
|
3925
|
+
options it ran with and timestamps. Poll this while a build is pending or running. When it
|
|
3926
|
+
is failed, read `Get NodeJS build logs` and `Analyse failed Node.js build` for the cause.
|
|
3927
|
+
Returns 404 when the UUID does not belong to a build of this website.
|
|
3928
|
+
*/
|
|
3929
|
+
"hosting_getNode_jsBuildDetailsV1": {
|
|
3930
|
+
params: {
|
|
3931
|
+
/**
|
|
3932
|
+
* username parameter
|
|
3933
|
+
*/
|
|
3934
|
+
username: string;
|
|
3935
|
+
/**
|
|
3936
|
+
* Domain name
|
|
3937
|
+
*/
|
|
3938
|
+
domain: string;
|
|
3939
|
+
/**
|
|
3940
|
+
* Build UUID
|
|
3941
|
+
*/
|
|
3942
|
+
uuid: string;
|
|
3943
|
+
};
|
|
3944
|
+
response: any; // Response structure will depend on the API
|
|
3945
|
+
};
|
|
3946
|
+
|
|
3817
3947
|
/**
|
|
3818
3948
|
* Retrieve logs from a specific Node.js build process.
|
|
3819
3949
|
|
|
@@ -3844,6 +3974,74 @@ Log content may contain ANSI escape sequences (color codes).
|
|
|
3844
3974
|
response: any; // Response structure will depend on the API
|
|
3845
3975
|
};
|
|
3846
3976
|
|
|
3977
|
+
/**
|
|
3978
|
+
* Returns the Node.js application's runtime console log entries, oldest first, each with
|
|
3979
|
+
timestamp, level and message. On the first call send `period` (`1h`, `1d`, `1w` or `1m`)
|
|
3980
|
+
and optionally `levels` and `limit` (1-5000, default 1000); when more entries match than
|
|
3981
|
+
`limit`, the newest are kept.
|
|
3982
|
+
|
|
3983
|
+
To poll for new entries send `total_lines + 1` from the previous response as `from_line`
|
|
3984
|
+
and omit `period`; `period` and `from_line` cannot be combined. Lines that are not JSON
|
|
3985
|
+
with a timestamp, level and message are skipped, so `logs` may hold fewer than `limit`
|
|
3986
|
+
entries while `total_lines` counts every raw line. Entries with a timestamp before
|
|
3987
|
+
`last_deployed_at` belong to the previous deployment. Returns an empty `logs` list when
|
|
3988
|
+
the application has not written a log file yet.
|
|
3989
|
+
*/
|
|
3990
|
+
"hosting_getNode_jsRuntimeLogsV1": {
|
|
3991
|
+
params: {
|
|
3992
|
+
/**
|
|
3993
|
+
* username parameter
|
|
3994
|
+
*/
|
|
3995
|
+
username: string;
|
|
3996
|
+
/**
|
|
3997
|
+
* Domain name
|
|
3998
|
+
*/
|
|
3999
|
+
domain: string;
|
|
4000
|
+
/**
|
|
4001
|
+
* Time window for the first fetch. Required when `from_line` is not sent.
|
|
4002
|
+
*/
|
|
4003
|
+
period?: string;
|
|
4004
|
+
/**
|
|
4005
|
+
* 1-based line of the log file to start from. For polling send `total_lines + 1` from the
|
|
4006
|
+
previous response. Cannot be combined with `period`.
|
|
4007
|
+
*/
|
|
4008
|
+
from_line?: number;
|
|
4009
|
+
/**
|
|
4010
|
+
* Maximum number of log entries to return. When more entries match, the newest are kept.
|
|
4011
|
+
*/
|
|
4012
|
+
limit?: number;
|
|
4013
|
+
/**
|
|
4014
|
+
* Return only entries with these log levels, sent as a comma-separated list, e.g. ERROR,WARN.
|
|
4015
|
+
Matching runs on the raw log line, so entries written with numeric levels (for example by
|
|
4016
|
+
pino) are excluded while this filter is set.
|
|
4017
|
+
*/
|
|
4018
|
+
levels?: array;
|
|
4019
|
+
};
|
|
4020
|
+
response: any; // Response structure will depend on the API
|
|
4021
|
+
};
|
|
4022
|
+
|
|
4023
|
+
/**
|
|
4024
|
+
* Empties the Node.js application's runtime log file. This cannot be undone, so confirm with
|
|
4025
|
+
the user before calling it. Returns success even when no log file exists yet.
|
|
4026
|
+
|
|
4027
|
+
Use it before reproducing a problem so the next `Get Node.js runtime logs` call returns
|
|
4028
|
+
only fresh entries; start that call with `period` again instead of reusing a `from_line`
|
|
4029
|
+
from before the clear.
|
|
4030
|
+
*/
|
|
4031
|
+
"hosting_clearNode_jsRuntimeLogsV1": {
|
|
4032
|
+
params: {
|
|
4033
|
+
/**
|
|
4034
|
+
* username parameter
|
|
4035
|
+
*/
|
|
4036
|
+
username: string;
|
|
4037
|
+
/**
|
|
4038
|
+
* Domain name
|
|
4039
|
+
*/
|
|
4040
|
+
domain: string;
|
|
4041
|
+
};
|
|
4042
|
+
response: any; // Response structure will depend on the API
|
|
4043
|
+
};
|
|
4044
|
+
|
|
3847
4045
|
/**
|
|
3848
4046
|
* Restarts the Node.js server process for the website. Does not rebuild or redeploy the
|
|
3849
4047
|
application. Use it to apply environment or configuration changes, or to recover a hung
|