@theholocron/cloudflare-client 1.11.2 → 1.12.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/dist/index.d.mts CHANGED
@@ -126,6 +126,8 @@ declare function createCloudflareClient(opts: CloudflareClientOptions): {
126
126
  updateProject: (accountId: string, name: string, patch: Partial<Pick<CfPagesProject, "deployment_configs" | "production_branch">>) => Promise<CfPagesProject>;
127
127
  createDeployment: (accountId: string, projectName: string, branch: string) => Promise<CfPagesDeployment>;
128
128
  getDeployment: (accountId: string, projectName: string, deploymentId: string) => Promise<CfPagesDeployment>;
129
+ listDeployments: (accountId: string, projectName: string) => Promise<CfPagesDeployment[]>;
130
+ deleteDeployment: (accountId: string, projectName: string, deploymentId: string) => Promise<void>;
129
131
  listDomains: (accountId: string, projectName: string) => Promise<CfPagesDomain[]>;
130
132
  addDomain: (accountId: string, projectName: string, hostname: string) => Promise<CfPagesDomain>;
131
133
  };
package/dist/index.mjs CHANGED
@@ -53,6 +53,8 @@ function pages(rest) {
53
53
  updateProject: (accountId, name, patch) => cfRequest(rest, "PATCH", `/accounts/${accountId}/pages/projects/${name}`, patch),
54
54
  createDeployment: (accountId, projectName, branch) => cfRequest(rest, "POST", `/accounts/${accountId}/pages/projects/${projectName}/deployments`, { branch }),
55
55
  getDeployment: (accountId, projectName, deploymentId) => cfRequest(rest, "GET", `/accounts/${accountId}/pages/projects/${projectName}/deployments/${deploymentId}`),
56
+ listDeployments: (accountId, projectName) => cfRequest(rest, "GET", `/accounts/${accountId}/pages/projects/${projectName}/deployments`, void 0, { per_page: "25" }),
57
+ deleteDeployment: (accountId, projectName, deploymentId) => cfRequest(rest, "DELETE", `/accounts/${accountId}/pages/projects/${projectName}/deployments/${deploymentId}`, void 0, { force: "true" }),
56
58
  listDomains: (accountId, projectName) => cfRequest(rest, "GET", `/accounts/${accountId}/pages/projects/${projectName}/domains`),
57
59
  addDomain: (accountId, projectName, hostname) => cfRequest(rest, "POST", `/accounts/${accountId}/pages/projects/${projectName}/domains`, { name: hostname })
58
60
  };
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@theholocron/cloudflare-client",
3
- "version": "1.11.2",
3
+ "version": "1.12.0",
4
4
  "description": "A TypeScript client for the Cloudflare API",
5
5
  "keywords": [
6
6
  "cloudflare",
@@ -34,7 +34,7 @@
34
34
  "README.md"
35
35
  ],
36
36
  "dependencies": {
37
- "@theholocron/http-client": "^1.11.2"
37
+ "@theholocron/http-client": "^1.12.0"
38
38
  },
39
39
  "devDependencies": {
40
40
  "@theholocron/eslint-config": "^7.23.1",