@pontive/server 1.27.0 → 1.28.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/{client-DdtDcUK9.cjs → client-BkRsOrbo.cjs} +2 -2
- package/dist/{client-DdtDcUK9.cjs.map → client-BkRsOrbo.cjs.map} +1 -1
- package/dist/{client-B3NStbMW.js → client-DhAfqKrD.js} +4 -3
- package/dist/{client-B3NStbMW.js.map → client-DhAfqKrD.js.map} +1 -1
- package/dist/index.cjs +4 -4
- package/dist/index.cjs.map +1 -1
- package/dist/index.d.cts +1 -0
- package/dist/index.d.ts +1 -0
- package/dist/index.js +1371 -439
- package/dist/index.js.map +1 -1
- package/dist/management.cjs +1 -1
- package/dist/management.js +1 -1
- package/dist/platform/client.d.cts +49 -0
- package/dist/platform/client.d.ts +49 -0
- package/dist/platform/core.d.cts +1 -0
- package/dist/platform/core.d.ts +1 -0
- package/dist/platform/generated/namespaces.d.cts +767 -0
- package/dist/platform/generated/namespaces.d.ts +767 -0
- package/dist/platform/generated/types.d.cts +2075 -0
- package/dist/platform/generated/types.d.ts +2075 -0
- package/dist/platform/index.d.cts +6 -0
- package/dist/platform/index.d.ts +6 -0
- package/package.json +1 -1
package/dist/management.cjs
CHANGED
|
@@ -1,2 +1,2 @@
|
|
|
1
|
-
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./client-
|
|
1
|
+
"use strict";Object.defineProperty(exports,Symbol.toStringTag,{value:"Module"});const r=require("./client-BkRsOrbo.cjs");exports.APIPromise=r.APIPromise;exports.AuthenticationError=r.AuthenticationError;exports.BadRequestError=r.BadRequestError;exports.ConflictError=r.ConflictError;exports.InternalServerError=r.InternalServerError;exports.NotFoundError=r.NotFoundError;exports.Page=r.Page;exports.PagePromise=r.PagePromise;exports.PermissionDeniedError=r.PermissionDeniedError;exports.Pontive=r.Pontive;exports.PontiveAPIError=r.PontiveAPIError;exports.PontiveConnectionError=r.PontiveConnectionError;exports.PreconditionFailedError=r.PreconditionFailedError;exports.RateLimitError=r.RateLimitError;exports.UnprocessableEntityError=r.UnprocessableEntityError;exports.secretKeyRegion=r.secretKeyRegion;
|
|
2
2
|
//# sourceMappingURL=management.cjs.map
|
package/dist/management.js
CHANGED
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { A as e, a, B as s, C as i, I as n, N as t, P as E, b as P, c, d, e as m, f as g, g as l, R as v, U as A, s as I } from "./client-
|
|
1
|
+
import { A as e, a, B as s, C as i, I as n, N as t, P as E, b as P, c, d, e as m, f as g, g as l, R as v, U as A, s as I } from "./client-DhAfqKrD.js";
|
|
2
2
|
export {
|
|
3
3
|
e as APIPromise,
|
|
4
4
|
a as AuthenticationError,
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { Env } from '../env.cjs';
|
|
2
|
+
import { PontiveNamespaces } from './generated/namespaces.cjs';
|
|
3
|
+
/** The platform API's host, unless overridden. */
|
|
4
|
+
export declare const PLATFORM_URL = "https://api.pontive.com";
|
|
5
|
+
/**
|
|
6
|
+
* How a {@link PontivePlatform} client authenticates and where it sends its
|
|
7
|
+
* calls. Every field is optional: one left out falls back to its environment
|
|
8
|
+
* variable, so `new PontivePlatform()` works with `PONTIVE_WORKSPACE_KEY` or
|
|
9
|
+
* `PONTIVE_ACCESS_TOKEN` set.
|
|
10
|
+
*/
|
|
11
|
+
export interface PontivePlatformOptions {
|
|
12
|
+
/** A workspace secret key, `pontive_wsk_…`: CI, Terraform, provisioning. Default: `PONTIVE_WORKSPACE_KEY`. */
|
|
13
|
+
workspaceKey?: string;
|
|
14
|
+
/**
|
|
15
|
+
* A personal access token, `pontive_pat_…`, for your own scripts, or any
|
|
16
|
+
* bearer token (a function returning one) the caller manages. Default:
|
|
17
|
+
* `PONTIVE_ACCESS_TOKEN`.
|
|
18
|
+
*/
|
|
19
|
+
token?: string | (() => string | Promise<string>);
|
|
20
|
+
/** Overrides the platform API's base, `https://api.pontive.com`. Default: `PONTIVE_PLATFORM_URL`. */
|
|
21
|
+
platformUrl?: string;
|
|
22
|
+
/** How many times a failed call is retried: a 429, a 5xx or a network error, when it is safe to repeat. Default 2. */
|
|
23
|
+
maxRetries?: number;
|
|
24
|
+
/** Milliseconds each attempt may take. Default 60000. */
|
|
25
|
+
timeout?: number;
|
|
26
|
+
/** The `fetch` to send with. Default: the global one. */
|
|
27
|
+
fetch?: typeof fetch;
|
|
28
|
+
/** The environment to fall back to. Default: `process.env`. */
|
|
29
|
+
env?: Env;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* A client for Pontive's platform API, `api.pontive.com`: the workspace, its
|
|
33
|
+
* projects, instances, members, domains and webhooks, and the instances'
|
|
34
|
+
* secret keys (pontive-spec 48). Namespaces follow the API:
|
|
35
|
+
* `platform.projects`, `platform.instances`, `platform.workspaces.webhooks`, …
|
|
36
|
+
*
|
|
37
|
+
* ```ts
|
|
38
|
+
* const platform = new PontivePlatform({ workspaceKey: process.env.PONTIVE_WORKSPACE_KEY });
|
|
39
|
+
* const instance = await platform.instances.create({ project_id: "proj_…", name: "preview-42" });
|
|
40
|
+
* const key = await platform.instances.createSecretKey(instance.id, { name: "ci", role: "developer" });
|
|
41
|
+
* ```
|
|
42
|
+
*
|
|
43
|
+
* A workspace key or personal access token reaches one workspace, with its
|
|
44
|
+
* role there. Server-side only: the constructor refuses a credential in a
|
|
45
|
+
* browser.
|
|
46
|
+
*/
|
|
47
|
+
export declare class PontivePlatform extends PontiveNamespaces {
|
|
48
|
+
constructor(options?: PontivePlatformOptions);
|
|
49
|
+
}
|
|
@@ -0,0 +1,49 @@
|
|
|
1
|
+
import { Env } from '../env.js';
|
|
2
|
+
import { PontiveNamespaces } from './generated/namespaces.js';
|
|
3
|
+
/** The platform API's host, unless overridden. */
|
|
4
|
+
export declare const PLATFORM_URL = "https://api.pontive.com";
|
|
5
|
+
/**
|
|
6
|
+
* How a {@link PontivePlatform} client authenticates and where it sends its
|
|
7
|
+
* calls. Every field is optional: one left out falls back to its environment
|
|
8
|
+
* variable, so `new PontivePlatform()` works with `PONTIVE_WORKSPACE_KEY` or
|
|
9
|
+
* `PONTIVE_ACCESS_TOKEN` set.
|
|
10
|
+
*/
|
|
11
|
+
export interface PontivePlatformOptions {
|
|
12
|
+
/** A workspace secret key, `pontive_wsk_…`: CI, Terraform, provisioning. Default: `PONTIVE_WORKSPACE_KEY`. */
|
|
13
|
+
workspaceKey?: string;
|
|
14
|
+
/**
|
|
15
|
+
* A personal access token, `pontive_pat_…`, for your own scripts, or any
|
|
16
|
+
* bearer token (a function returning one) the caller manages. Default:
|
|
17
|
+
* `PONTIVE_ACCESS_TOKEN`.
|
|
18
|
+
*/
|
|
19
|
+
token?: string | (() => string | Promise<string>);
|
|
20
|
+
/** Overrides the platform API's base, `https://api.pontive.com`. Default: `PONTIVE_PLATFORM_URL`. */
|
|
21
|
+
platformUrl?: string;
|
|
22
|
+
/** How many times a failed call is retried: a 429, a 5xx or a network error, when it is safe to repeat. Default 2. */
|
|
23
|
+
maxRetries?: number;
|
|
24
|
+
/** Milliseconds each attempt may take. Default 60000. */
|
|
25
|
+
timeout?: number;
|
|
26
|
+
/** The `fetch` to send with. Default: the global one. */
|
|
27
|
+
fetch?: typeof fetch;
|
|
28
|
+
/** The environment to fall back to. Default: `process.env`. */
|
|
29
|
+
env?: Env;
|
|
30
|
+
}
|
|
31
|
+
/**
|
|
32
|
+
* A client for Pontive's platform API, `api.pontive.com`: the workspace, its
|
|
33
|
+
* projects, instances, members, domains and webhooks, and the instances'
|
|
34
|
+
* secret keys (pontive-spec 48). Namespaces follow the API:
|
|
35
|
+
* `platform.projects`, `platform.instances`, `platform.workspaces.webhooks`, …
|
|
36
|
+
*
|
|
37
|
+
* ```ts
|
|
38
|
+
* const platform = new PontivePlatform({ workspaceKey: process.env.PONTIVE_WORKSPACE_KEY });
|
|
39
|
+
* const instance = await platform.instances.create({ project_id: "proj_…", name: "preview-42" });
|
|
40
|
+
* const key = await platform.instances.createSecretKey(instance.id, { name: "ci", role: "developer" });
|
|
41
|
+
* ```
|
|
42
|
+
*
|
|
43
|
+
* A workspace key or personal access token reaches one workspace, with its
|
|
44
|
+
* role there. Server-side only: the constructor refuses a credential in a
|
|
45
|
+
* browser.
|
|
46
|
+
*/
|
|
47
|
+
export declare class PontivePlatform extends PontiveNamespaces {
|
|
48
|
+
constructor(options?: PontivePlatformOptions);
|
|
49
|
+
}
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '../management/core.cjs';
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
export * from '../management/core.js';
|