@uluops/ops-sdk 6.3.1 → 6.4.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 +52 -0
- package/README.md +190 -1
- package/dist/client.d.ts +86 -3
- package/dist/client.d.ts.map +1 -1
- package/dist/client.js +71 -5
- package/dist/client.js.map +1 -1
- package/dist/config/constants.d.ts +1 -1
- package/dist/config/generated-version.d.ts +1 -1
- package/dist/config/generated-version.js +1 -1
- package/dist/config/validators.d.ts +25 -1
- package/dist/config/validators.d.ts.map +1 -1
- package/dist/config/validators.js +31 -1
- package/dist/config/validators.js.map +1 -1
- package/dist/errors/errors.d.ts +71 -0
- package/dist/errors/errors.d.ts.map +1 -1
- package/dist/errors/errors.js +99 -0
- package/dist/errors/errors.js.map +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.d.ts.map +1 -1
- package/dist/index.js.map +1 -1
- package/dist/operations/admin.d.ts +100 -0
- package/dist/operations/admin.d.ts.map +1 -0
- package/dist/operations/admin.js +130 -0
- package/dist/operations/admin.js.map +1 -0
- package/dist/operations/auth.d.ts +21 -1
- package/dist/operations/auth.d.ts.map +1 -1
- package/dist/operations/auth.js +49 -3
- package/dist/operations/auth.js.map +1 -1
- package/dist/operations/orgs.d.ts +27 -0
- package/dist/operations/orgs.d.ts.map +1 -0
- package/dist/operations/orgs.js +34 -0
- package/dist/operations/orgs.js.map +1 -0
- package/dist/operations/projects.d.ts +46 -0
- package/dist/operations/projects.d.ts.map +1 -1
- package/dist/operations/projects.js +54 -1
- package/dist/operations/projects.js.map +1 -1
- package/dist/types/auth.d.ts +10 -0
- package/dist/types/auth.d.ts.map +1 -1
- package/dist/types/index.d.ts +1 -0
- package/dist/types/index.d.ts.map +1 -1
- package/dist/types/index.js +1 -0
- package/dist/types/index.js.map +1 -1
- package/dist/types/rehome.d.ts +234 -0
- package/dist/types/rehome.d.ts.map +1 -0
- package/dist/types/rehome.js +171 -0
- package/dist/types/rehome.js.map +1 -0
- package/dist/types/response-schemas.d.ts +19 -0
- package/dist/types/response-schemas.d.ts.map +1 -1
- package/dist/types/response-schemas.js +19 -0
- package/dist/types/response-schemas.js.map +1 -1
- package/dist/types/schemas.d.ts +20 -0
- package/dist/types/schemas.d.ts.map +1 -1
- package/dist/types/schemas.js +22 -0
- package/dist/types/schemas.js.map +1 -1
- package/package.json +1 -1
|
@@ -0,0 +1,130 @@
|
|
|
1
|
+
import { RehomeResponseSchema, ProjectRehomeListResponseSchema, ProjectRehomeEventListResponseSchema, } from '../types/rehome.js';
|
|
2
|
+
import { z } from 'zod';
|
|
3
|
+
import { validateAdminRehomeProjectInput, validateUuid } from '../config/validators.js';
|
|
4
|
+
/**
|
|
5
|
+
* Platform-admin project re-home surface (project-org-routing-and-rehome spec
|
|
6
|
+
* §4.1 D8, §4.7, D20, D21). Every call here requires `users.role = 'admin'` —
|
|
7
|
+
* a PLATFORM role, not an org role — and the two writes additionally require
|
|
8
|
+
* a login-issued SESSION (D20): a `ulr_` key, even an admin's, gets
|
|
9
|
+
* `403 SESSION_REQUIRED` (`isSessionRequiredError`). Log in with
|
|
10
|
+
* `OpsClient.login` (completing MFA via `loginWithTotp` if challenged) and the
|
|
11
|
+
* session bearer is what these calls send. There is deliberately no MCP tool
|
|
12
|
+
* for any of this.
|
|
13
|
+
*
|
|
14
|
+
* `admin.` is a namespace, not an escalation: the same client, the same auth
|
|
15
|
+
* strategy. If the credential cannot do it the server says so.
|
|
16
|
+
*/
|
|
17
|
+
/**
|
|
18
|
+
* Move ANY project between ANY two orgs — `POST /admin/projects/:id/rehome`.
|
|
19
|
+
* No source-membership and no target-membership requirement (the platform role
|
|
20
|
+
* is the authority), so `reason` is REQUIRED: on this path the target org's
|
|
21
|
+
* only standing is the `rehome_in` audit row plus that text. Resolves the
|
|
22
|
+
* project by id UNSCOPED (the admin router has no org context) — the route
|
|
23
|
+
* takes a UUID and answers 400 to anything else, so unlike `projects.*` a
|
|
24
|
+
* NAME is refused here, client-side, before the request.
|
|
25
|
+
*
|
|
26
|
+
* Session-only (D20). Phase 4 of the spec runs this once per row of the OQ-4
|
|
27
|
+
* table, sequentially, with the row reference as `reason`. On THIS path a
|
|
28
|
+
* re-run over a finished row answers `same_org` (the lookup is by id, so the
|
|
29
|
+
* moved project is found wherever it is) — read it as "already done" via
|
|
30
|
+
* `rehomeRefusalReason`. That is not true of the member path, whose lookup is
|
|
31
|
+
* source-scoped (see `projects.rehome`).
|
|
32
|
+
*
|
|
33
|
+
* @param client - HTTP client instance carrying a SESSION
|
|
34
|
+
* @param projectId - Project UUID (a name is an `InputValidationError`)
|
|
35
|
+
* @param input - `{ targetOrg, reason }` — both required
|
|
36
|
+
* @returns The project after the move (`orgId` is the target) plus the `rehome` block
|
|
37
|
+
* @throws {InputValidationError} If `projectId` is not a UUID, `targetOrg` is not a slug, or `reason` is missing
|
|
38
|
+
* @example
|
|
39
|
+
* ```typescript
|
|
40
|
+
* await client.login(email, password); // or loginWithTotp after an MfaRequiredError
|
|
41
|
+
* const moved = await client.admin.rehomeProject(projectId, { targetOrg: 'ulu-labs', reason: 'OQ-4 row 7' });
|
|
42
|
+
* moved.rehome.to_org.slug; // 'ulu-labs'
|
|
43
|
+
* ```
|
|
44
|
+
*/
|
|
45
|
+
export async function rehomeProject(client, projectId, input) {
|
|
46
|
+
validateUuid(projectId, 'projectId');
|
|
47
|
+
const valid = validateAdminRehomeProjectInput(input);
|
|
48
|
+
return RehomeResponseSchema.parse(await client.post(`/admin/projects/${encodeURIComponent(projectId)}/rehome`, { target_org: valid.targetOrg, reason: valid.reason }));
|
|
49
|
+
}
|
|
50
|
+
/**
|
|
51
|
+
* The reservation table — `GET /admin/projects/rehomes`: every vacated
|
|
52
|
+
* `(org, name)` address and where it redirects. Key-readable. This is the
|
|
53
|
+
* CURRENT redirect state, not the history — a reversal annihilates its row and
|
|
54
|
+
* a release deletes it; for "what happened" read {@link listProjectRehomeEvents}.
|
|
55
|
+
*
|
|
56
|
+
* `org` takes a UUID or a slug; `total` is the matching count, `returned` the page.
|
|
57
|
+
*
|
|
58
|
+
* @param client - HTTP client instance (a platform-admin key suffices)
|
|
59
|
+
* @param query - `{ projectId?, org?, since?, limit? }`
|
|
60
|
+
* @returns `{ data, total, returned }` — reservation rows, camelCase
|
|
61
|
+
*/
|
|
62
|
+
export async function listProjectRehomes(client, query = {}) {
|
|
63
|
+
return ProjectRehomeListResponseSchema.parse(await client.request('GET', '/admin/projects/rehomes', rehomeListParams(query), { rawEnvelope: true }));
|
|
64
|
+
}
|
|
65
|
+
/**
|
|
66
|
+
* The append-only ledger (D21) — `GET /admin/projects/rehome-events`: every
|
|
67
|
+
* move, re-point, annihilation, degenerate drop, release and hard-delete
|
|
68
|
+
* release, written in the same transaction as the change; nothing the API
|
|
69
|
+
* offers removes a row. Key-readable. Pages by `seq` (insertion order) —
|
|
70
|
+
* `nextCursor` is the `seq` to continue strictly below; pass it back verbatim.
|
|
71
|
+
* This, not the reservation listing and not a script's own log, is what a
|
|
72
|
+
* migration reconciles against (spec §4.7 item 4).
|
|
73
|
+
*
|
|
74
|
+
* @param client - HTTP client instance (a platform-admin key suffices)
|
|
75
|
+
* @param query - `{ projectId?, org?, event?, since?, cursor?, limit? }`
|
|
76
|
+
* @returns `{ data, total, returned, hasMore, nextCursor }` — ledger rows, camelCase, newest `seq` first
|
|
77
|
+
* @example
|
|
78
|
+
* ```typescript
|
|
79
|
+
* let cursor: string | undefined;
|
|
80
|
+
* do {
|
|
81
|
+
* const page = await client.admin.listProjectRehomeEvents({ org: 'ulu-labs', event: 'moved', cursor });
|
|
82
|
+
* for (const ev of page.data) console.log(ev.seq, ev.projectName, ev.fromOrgId, '→', ev.toOrgId);
|
|
83
|
+
* cursor = page.nextCursor ?? undefined;
|
|
84
|
+
* } while (cursor);
|
|
85
|
+
* ```
|
|
86
|
+
*/
|
|
87
|
+
export async function listProjectRehomeEvents(client, query = {}) {
|
|
88
|
+
const params = rehomeListParams(query);
|
|
89
|
+
if (query.event !== undefined)
|
|
90
|
+
params['event'] = query.event;
|
|
91
|
+
if (query.cursor !== undefined)
|
|
92
|
+
params['cursor'] = query.cursor;
|
|
93
|
+
return ProjectRehomeEventListResponseSchema.parse(await client.request('GET', '/admin/projects/rehome-events', params, { rawEnvelope: true }));
|
|
94
|
+
}
|
|
95
|
+
/**
|
|
96
|
+
* Release a vacated address — `DELETE /admin/projects/rehomes/:id`. After
|
|
97
|
+
* this the old `(org, name)` is creatable again: a by-name writer there gets a
|
|
98
|
+
* NEW project instead of `410 PROJECT_REHOMED`. Deliberate, audited (`released`
|
|
99
|
+
* ledger row), never done by time. Session-only (D20): release is the step that
|
|
100
|
+
* empties the queryable record.
|
|
101
|
+
*
|
|
102
|
+
* @param client - HTTP client instance carrying a SESSION
|
|
103
|
+
* @param rehomeId - The reservation row id (from {@link listProjectRehomes}); a non-UUID is refused client-side
|
|
104
|
+
* @returns `{ released: true }`
|
|
105
|
+
* @throws {InputValidationError} If `rehomeId` is not a UUID
|
|
106
|
+
* @throws {ZodError} If the 200 body does not say `released: true` — the same signal every other
|
|
107
|
+
* shape mismatch in this SDK gives. Note the server sends 200 AFTER the row is gone, so a
|
|
108
|
+
* shape failure here means the release most likely HAPPENED; re-read `listProjectRehomes`
|
|
109
|
+
* before retrying (a retry answers 404).
|
|
110
|
+
*/
|
|
111
|
+
export async function releaseProjectRehome(client, rehomeId) {
|
|
112
|
+
validateUuid(rehomeId, 'rehomeId');
|
|
113
|
+
return ReleaseResponseSchema.parse(await client.delete(`/admin/projects/rehomes/${encodeURIComponent(rehomeId)}`));
|
|
114
|
+
}
|
|
115
|
+
/** `DELETE /admin/projects/rehomes/:id` answers `{ data: { released: true } }`; anything else is a contract break. */
|
|
116
|
+
const ReleaseResponseSchema = z.object({ released: z.literal(true) });
|
|
117
|
+
/** Shared filter serialisation for the two listings — snake_case on the wire (`project_id`), strings throughout. */
|
|
118
|
+
function rehomeListParams(query) {
|
|
119
|
+
const params = {};
|
|
120
|
+
if (query.projectId !== undefined)
|
|
121
|
+
params['project_id'] = query.projectId;
|
|
122
|
+
if (query.org !== undefined)
|
|
123
|
+
params['org'] = query.org;
|
|
124
|
+
if (query.since !== undefined)
|
|
125
|
+
params['since'] = query.since;
|
|
126
|
+
if (query.limit !== undefined)
|
|
127
|
+
params['limit'] = String(query.limit);
|
|
128
|
+
return params;
|
|
129
|
+
}
|
|
130
|
+
//# sourceMappingURL=admin.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"admin.js","sourceRoot":"","sources":["../../src/operations/admin.ts"],"names":[],"mappings":"AASA,OAAO,EACL,oBAAoB,EACpB,+BAA+B,EAC/B,oCAAoC,GACrC,MAAM,oBAAoB,CAAC;AAC5B,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,EAAE,+BAA+B,EAAE,YAAY,EAAE,MAAM,yBAAyB,CAAC;AAExF;;;;;;;;;;;;GAYG;AAEH;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AACH,MAAM,CAAC,KAAK,UAAU,aAAa,CACjC,MAAqB,EACrB,SAAiB,EACjB,KAA8B;IAE9B,YAAY,CAAC,SAAS,EAAE,WAAW,CAAC,CAAC;IACrC,MAAM,KAAK,GAAG,+BAA+B,CAAC,KAAK,CAAC,CAAC;IACrD,OAAO,oBAAoB,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,IAAI,CACjD,mBAAmB,kBAAkB,CAAC,SAAS,CAAC,SAAS,EACzD,EAAE,UAAU,EAAE,KAAK,CAAC,SAAS,EAAE,MAAM,EAAE,KAAK,CAAC,MAAM,EAAE,CACtD,CAAC,CAAC;AACL,CAAC;AAED;;;;;;;;;;;GAWG;AACH,MAAM,CAAC,KAAK,UAAU,kBAAkB,CACtC,MAAqB,EACrB,QAAgC,EAAE;IAElC,OAAO,+BAA+B,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,OAAO,CAC/D,KAAK,EACL,yBAAyB,EACzB,gBAAgB,CA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1E,IAAI,KAAK,CAAC,GAAG,KAAK,SAAS;QAAE,MAAM,CAAC,KAAK,CAAC,GAAG,KAAK,CAAC,GAAG,CAAC;IACvD,IAAI,KAAK,CAAC,KAAK,KAAK,SAAS;QAAE,MAAM,CAAC,OAAO,CAAC,GAAG,KAAK,CAAC,KAAK,CAAC;IAC7D,IAAI,KAAK,CAAC,KAAK,KAAK,SAAS;QAAE,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACrE,OAAO,MAAM,CAAC;AAChB,CAAC"}
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import type { OpsHttpClient } from '../http/http-client.js';
|
|
2
|
-
import type { RegisterInput, LoginInput, LoginResponse, RegisterResponse, UpdateProfileInput, ChangePasswordInput, ResetPasswordInput, CreateApiKeyInput, ApiKeyCreatedResponse, PublicApiKey, PublicSession, AuthUser, PublicUser } from '../types/auth.js';
|
|
2
|
+
import type { RegisterInput, LoginInput, LoginResponse, TotpLoginInput, RegisterResponse, UpdateProfileInput, ChangePasswordInput, ResetPasswordInput, CreateApiKeyInput, ApiKeyCreatedResponse, PublicApiKey, PublicSession, AuthUser, PublicUser } from '../types/auth.js';
|
|
3
3
|
import type { MessageResponse } from '../types/responses.js';
|
|
4
4
|
/**
|
|
5
5
|
* Register a new user account. Does not require authentication.
|
|
@@ -23,8 +23,28 @@ export declare function register(client: OpsHttpClient, input: RegisterInput): P
|
|
|
23
23
|
* @returns `{ user, sessionToken }` — token must be manually installed on the client
|
|
24
24
|
* @throws {InputValidationError} If email or password is missing
|
|
25
25
|
* @throws {UnauthorizedError} If credentials are invalid
|
|
26
|
+
* @throws {MfaRequiredError} If the account has TOTP or a passkey enrolled — the API answered a
|
|
27
|
+
* challenge, not a session; complete it with `totpLogin` / `OpsClient.loginWithTotp`
|
|
26
28
|
*/
|
|
27
29
|
export declare function login(client: OpsHttpClient, input: LoginInput): Promise<LoginResponse>;
|
|
30
|
+
/**
|
|
31
|
+
* Complete an MFA-challenged login with a TOTP code (`POST /auth/totp/login`).
|
|
32
|
+
* Returns the same `{ user, sessionToken, expiresAt }` a password login does.
|
|
33
|
+
* Like `login`, this only RETURNS the session — `OpsClient.loginWithTotp`
|
|
34
|
+
* installs it.
|
|
35
|
+
*
|
|
36
|
+
* **The challenge is single-use and is consumed BEFORE the code is checked**
|
|
37
|
+
* (`totp-service.verifyLogin`: consume, then verify). A wrong code therefore
|
|
38
|
+
* burns the token: retrying `totpLogin` with the same `mfaChallengeToken` is a
|
|
39
|
+
* 401 every time. Recovery is a fresh `login()` for a fresh challenge.
|
|
40
|
+
*
|
|
41
|
+
* @param client - HTTP client instance
|
|
42
|
+
* @param input - `{ mfaChallengeToken, code, rememberMe? }`
|
|
43
|
+
* @returns `{ user, sessionToken, expiresAt }` — token must be manually installed on the client
|
|
44
|
+
* @throws {InputValidationError} If the token is empty or the code is not six digits
|
|
45
|
+
* @throws {UnauthorizedError} If the code is wrong, or the challenge expired or was already consumed
|
|
46
|
+
*/
|
|
47
|
+
export declare function totpLogin(client: OpsHttpClient, input: TotpLoginInput): Promise<LoginResponse>;
|
|
28
48
|
/**
|
|
29
49
|
* Revoke all sessions for the current user (not just the current session).
|
|
30
50
|
*
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/operations/auth.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,KAAK,EACV,aAAa,EACb,UAAU,EACV,aAAa,EACb,gBAAgB,EAChB,kBAAkB,EAClB,mBAAmB,EACnB,kBAAkB,EAClB,iBAAiB,EACjB,qBAAqB,EACrB,YAAY,EACZ,aAAa,EACb,QAAQ,EACR,UAAU,EACX,MAAM,kBAAkB,CAAC;AAC1B,OAAO,KAAK,EAAE,eAAe,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"auth.d.ts","s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AAC,aAAa,EAAE,CAAC,CAE1B;AAED;;;;;GAKG;AACH,wBAAsB,aAAa,CACjC,MAAM,EAAE,aAAa,EACrB,SAAS,EAAE,MAAM,GAChB,OAAO,CAAC,IAAI,CAAC,CAEf"}
|
package/dist/operations/auth.js
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
|
-
import { AuthUserResponseSchema, PublicUserResponseSchema, LoginResponseSchema, RegisterResponseSchema, PublicApiKeyResponseSchema, ApiKeyCreatedResponseSchema, PublicSessionResponseSchema, MessageResponseSchema, } from '../types/response-schemas.js';
|
|
3
|
-
import { validateRegisterInput, validateLoginInput, validateUpdateProfileInput, validateChangePasswordInput, validateResetPasswordInput, validateSetPasswordInput, validateCreateApiKeyInput, } from '../config/validators.js';
|
|
2
|
+
import { AuthUserResponseSchema, PublicUserResponseSchema, LoginResponseSchema, MfaChallengeResponseSchema, RegisterResponseSchema, PublicApiKeyResponseSchema, ApiKeyCreatedResponseSchema, PublicSessionResponseSchema, MessageResponseSchema, } from '../types/response-schemas.js';
|
|
3
|
+
import { validateRegisterInput, validateLoginInput, validateTotpLoginInput, validateUpdateProfileInput, validateChangePasswordInput, validateResetPasswordInput, validateSetPasswordInput, validateCreateApiKeyInput, } from '../config/validators.js';
|
|
4
|
+
import { MfaRequiredError } from '../errors/errors.js';
|
|
4
5
|
const ProfileResponseSchema = z.object({ user: PublicUserResponseSchema });
|
|
5
6
|
/**
|
|
6
7
|
* Register a new user account. Does not require authentication.
|
|
@@ -27,10 +28,55 @@ export async function register(client, input) {
|
|
|
27
28
|
* @returns `{ user, sessionToken }` — token must be manually installed on the client
|
|
28
29
|
* @throws {InputValidationError} If email or password is missing
|
|
29
30
|
* @throws {UnauthorizedError} If credentials are invalid
|
|
31
|
+
* @throws {MfaRequiredError} If the account has TOTP or a passkey enrolled — the API answered a
|
|
32
|
+
* challenge, not a session; complete it with `totpLogin` / `OpsClient.loginWithTotp`
|
|
30
33
|
*/
|
|
31
34
|
export async function login(client, input) {
|
|
32
35
|
validateLoginInput(input);
|
|
33
|
-
|
|
36
|
+
const body = await client.post('/auth/login', input, { skipAuth: true });
|
|
37
|
+
return parseLoginOrChallenge(body);
|
|
38
|
+
}
|
|
39
|
+
/**
|
|
40
|
+
* Complete an MFA-challenged login with a TOTP code (`POST /auth/totp/login`).
|
|
41
|
+
* Returns the same `{ user, sessionToken, expiresAt }` a password login does.
|
|
42
|
+
* Like `login`, this only RETURNS the session — `OpsClient.loginWithTotp`
|
|
43
|
+
* installs it.
|
|
44
|
+
*
|
|
45
|
+
* **The challenge is single-use and is consumed BEFORE the code is checked**
|
|
46
|
+
* (`totp-service.verifyLogin`: consume, then verify). A wrong code therefore
|
|
47
|
+
* burns the token: retrying `totpLogin` with the same `mfaChallengeToken` is a
|
|
48
|
+
* 401 every time. Recovery is a fresh `login()` for a fresh challenge.
|
|
49
|
+
*
|
|
50
|
+
* @param client - HTTP client instance
|
|
51
|
+
* @param input - `{ mfaChallengeToken, code, rememberMe? }`
|
|
52
|
+
* @returns `{ user, sessionToken, expiresAt }` — token must be manually installed on the client
|
|
53
|
+
* @throws {InputValidationError} If the token is empty or the code is not six digits
|
|
54
|
+
* @throws {UnauthorizedError} If the code is wrong, or the challenge expired or was already consumed
|
|
55
|
+
*/
|
|
56
|
+
export async function totpLogin(client, input) {
|
|
57
|
+
const valid = validateTotpLoginInput(input);
|
|
58
|
+
return LoginResponseSchema.parse(await client.post('/auth/totp/login', {
|
|
59
|
+
mfa_challenge_token: valid.mfaChallengeToken,
|
|
60
|
+
code: valid.code,
|
|
61
|
+
...(valid.rememberMe !== undefined ? { rememberMe: valid.rememberMe } : {}),
|
|
62
|
+
}, { skipAuth: true }));
|
|
63
|
+
}
|
|
64
|
+
/**
|
|
65
|
+
* A 200 from `/auth/login` is one of two shapes; the challenge is tried FIRST
|
|
66
|
+
* because it is the narrower literal, and a session body can never carry
|
|
67
|
+
* `mfa_required: true`. Anything else falls through to the strict session
|
|
68
|
+
* parse, whose ZodError names what was actually missing.
|
|
69
|
+
*/
|
|
70
|
+
function parseLoginOrChallenge(body) {
|
|
71
|
+
const challenge = MfaChallengeResponseSchema.safeParse(body);
|
|
72
|
+
if (challenge.success) {
|
|
73
|
+
throw new MfaRequiredError({
|
|
74
|
+
mfaChallengeToken: challenge.data.mfa_challenge_token,
|
|
75
|
+
expiresAt: challenge.data.expires_at,
|
|
76
|
+
mfaMethods: challenge.data.mfa_methods,
|
|
77
|
+
});
|
|
78
|
+
}
|
|
79
|
+
return LoginResponseSchema.parse(body);
|
|
34
80
|
}
|
|
35
81
|
/**
|
|
36
82
|
* Revoke all sessions for the current user (not just the current session).
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth.js","sourceRoot":"","sources":["../../src/operations/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;
|
|
1
|
+
{"version":3,"file":"auth.js","sourceRoot":"","sources":["../../src/operations/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAmBxB,OAAO,EACL,sBAAsB,EACtB,wBAAwB,EACxB,mBAAmB,EACnB,0BAA0B,EAC1B,sBAAsB,EACtB,0BAA0B,EAC1B,2BAA2B,EAC3B,2BAA2B,EAC3B,qBAAqB,GACtB,MAAM,8BAA8B,CAAC;AACtC,OAAO,EACL,qBAAqB,EACrB,kBAAkB,EAClB,sBAAsB,EACtB,0BAA0B,EAC1B,2BAA2B,EAC3B,0BAA0B,EAC1B,wBAAwB,EACxB,yBAAyB,GAC1B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,gBAAgB,EAAE,MAAM,qBAAqB,CAAC;AAEvD,MAAM,qBAAqB,GAAG,CAAC,CAAC,MAAM,CAAC,EAAE,IAAI,EAAE,wBAAwB,EAAE,CAAC,CAAC;AAE3E;;;;;;;GAOG;AACH,MAAM,CAAC,KAAK,UAAU,QAAQ,CAC5B,M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AuditFeedQuery } from '../types/rehome.js';
|
|
3
|
+
/**
|
|
4
|
+
* The org-visible audit feed (project-org-routing-and-rehome spec D19) —
|
|
5
|
+
* `GET /orgs/:slug/audit-log/global`. Any MEMBER of the org may read it; the
|
|
6
|
+
* full audit log stays admin+ and is not wrapped here.
|
|
7
|
+
*
|
|
8
|
+
* What lands in it: rows whose writer marked `details.visibility = 'org'`.
|
|
9
|
+
* Today that is one class — a project leaving this org for someone's personal
|
|
10
|
+
* org (an org admin may do that, and the org's owner could not see it before
|
|
11
|
+
* D19). The re-home writer's `details` shape is `RehomeAuditDetails`; use
|
|
12
|
+
* `readRehomeAuditDetails(entry)` to narrow, and print anything else raw.
|
|
13
|
+
*
|
|
14
|
+
* Paging: keyset `(createdAt, id)` on `@uluops/platform` ≥ 1.28.4 — `nextCursor`
|
|
15
|
+
* is `<iso>|<uuid>`, opaque to callers; pass it back verbatim. `count` is the
|
|
16
|
+
* page size, not the total (the platform reader has no count).
|
|
17
|
+
*
|
|
18
|
+
* The slug in the PATH is the org; a client-level `orgSlug` header does not
|
|
19
|
+
* redirect this read (`orgContext` resolves `:slug` first).
|
|
20
|
+
*
|
|
21
|
+
* @param client - HTTP client instance
|
|
22
|
+
* @param slug - Org slug (the org whose feed to read — you must be a member)
|
|
23
|
+
* @param query - `{ cursor?, limit? }`; `limit` is 1–100 and the API answers 400 outside that range (it does not clamp)
|
|
24
|
+
* @returns `{ data: { entries }, count, hasMore, nextCursor }`
|
|
25
|
+
*/
|
|
26
|
+
export declare function getVisibleAuditLog(client: OpsHttpClient, slug: string, query?: OrgAuditFeedQuery): Promise<OrgAuditFeed>;
|
|
27
|
+
//# sourceMappingURL=orgs.d.ts.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orgs.d.ts","sourceRoot":"","sources":["../../src/operations/orgs.ts"],"names":[],"mappings":"AAAA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAC5D,OAAO,KAAK,EAAE,YAAY,EAAE,iBAAiB,EAAE,MAAM,oBAAoB,CAAC;AAG1E;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,wBAAsB,kBAAkB,CACtC,MAAM,EAAE,aAAa,EACrB,IAAI,EAAE,MAAM,EACZ,KAAK,GAAE,iBAAsB,GAC5B,OAAO,CAAC,YAAY,CAAC,CAWvB"}
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
import { OrgAuditFeedResponseSchema } from '../types/rehome.js';
|
|
2
|
+
/**
|
|
3
|
+
* The org-visible audit feed (project-org-routing-and-rehome spec D19) —
|
|
4
|
+
* `GET /orgs/:slug/audit-log/global`. Any MEMBER of the org may read it; the
|
|
5
|
+
* full audit log stays admin+ and is not wrapped here.
|
|
6
|
+
*
|
|
7
|
+
* What lands in it: rows whose writer marked `details.visibility = 'org'`.
|
|
8
|
+
* Today that is one class — a project leaving this org for someone's personal
|
|
9
|
+
* org (an org admin may do that, and the org's owner could not see it before
|
|
10
|
+
* D19). The re-home writer's `details` shape is `RehomeAuditDetails`; use
|
|
11
|
+
* `readRehomeAuditDetails(entry)` to narrow, and print anything else raw.
|
|
12
|
+
*
|
|
13
|
+
* Paging: keyset `(createdAt, id)` on `@uluops/platform` ≥ 1.28.4 — `nextCursor`
|
|
14
|
+
* is `<iso>|<uuid>`, opaque to callers; pass it back verbatim. `count` is the
|
|
15
|
+
* page size, not the total (the platform reader has no count).
|
|
16
|
+
*
|
|
17
|
+
* The slug in the PATH is the org; a client-level `orgSlug` header does not
|
|
18
|
+
* redirect this read (`orgContext` resolves `:slug` first).
|
|
19
|
+
*
|
|
20
|
+
* @param client - HTTP client instance
|
|
21
|
+
* @param slug - Org slug (the org whose feed to read — you must be a member)
|
|
22
|
+
* @param query - `{ cursor?, limit? }`; `limit` is 1–100 and the API answers 400 outside that range (it does not clamp)
|
|
23
|
+
* @returns `{ data: { entries }, count, hasMore, nextCursor }`
|
|
24
|
+
*/
|
|
25
|
+
export async function getVisibleAuditLog(client, slug, query = {}) {
|
|
26
|
+
const params = {};
|
|
27
|
+
if (query.cursor !== undefined)
|
|
28
|
+
params['cursor'] = query.cursor;
|
|
29
|
+
if (query.limit !== undefined)
|
|
30
|
+
params['limit'] = String(query.limit);
|
|
31
|
+
// On GET the third argument IS the query (sdk-core `buildRequestUrl`).
|
|
32
|
+
return OrgAuditFeedResponseSchema.parse(await client.request('GET', `/orgs/${encodeURIComponent(slug)}/audit-log/global`, params, { rawEnvelope: true }));
|
|
33
|
+
}
|
|
34
|
+
//# sourceMappingURL=orgs.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"file":"orgs.js","sourceRoot":"","sources":["../../src/operations/orgs.ts"],"names":[],"mappings":"AAEA,OAAO,EAAE,0BAA0B,EAAE,MAAM,oBAAoB,CAAC;AAEhE;;;;;;;;;;;;;;;;;;;;;;GAsBG;AACH,MAAM,CAAC,KAAK,UAAU,kBAAkB,CACtC,MAAqB,EACrB,IAAY,EACZ,QAA2B,EAAE;IAE7B,MAAM,MAAM,GAA2B,EAAE,CAAC;IAC1C,IAAI,KAAK,CAAC,MAAM,KAAK,SAAS;QAAE,MAAM,CAAC,QAAQ,CAAC,GAAG,KAAK,CAAC,MAAM,CAAC;IAChE,IAAI,KAAK,CAAC,KAAK,KAAK,SAAS;QAAE,MAAM,CAAC,OAAO,CAAC,GAAG,MAAM,CAAC,KAAK,CAAC,KAAK,CAAC,CAAC;IACrE,uEAAuE;IACvE,OAAO,0BAA0B,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,OAAO,CAC1D,KAAK,EACL,SAAS,kBAAkB,CAAC,IAAI,CAAC,mBAAmB,EACpD,MAAM,EACN,EAAE,WAAW,EAAE,IAAI,EAAE,CACtB,CAAC,CAAC;AACL,CAAC"}
|
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import type { OpsHttpClient } from '../http/http-client.js';
|
|
2
2
|
import type { Project, CreateProjectInput, UpdateProjectInput, DeleteProjectInput, RenameProjectInput, ProjectSummaryResponse, ProjectTrends, ProjectTrendsQuery, ListProjectIssuesQuery, BulkIssueStatusUpdate, BulkIssueStatusResult, MergeIssuesInput, MergeIssuesResult, MergeProjectsInput, MergeProjectsResult } from '../types/projects.js';
|
|
3
|
+
import type { RehomeProjectInput, RehomeResponse } from '../types/rehome.js';
|
|
3
4
|
import type { Issue } from '../types/issues.js';
|
|
4
5
|
import type { DeleteResult } from '../types/responses.js';
|
|
5
6
|
/**
|
|
@@ -142,4 +143,49 @@ export declare function mergeIssues(client: OpsHttpClient, idOrName: string, inp
|
|
|
142
143
|
* @returns Merge result (spec §5 shape — snake_case fields by contract)
|
|
143
144
|
*/
|
|
144
145
|
export declare function mergeProjects(client: OpsHttpClient, input: MergeProjectsInput): Promise<MergeProjectsResult>;
|
|
146
|
+
/**
|
|
147
|
+
* Move a project to another org — the MEMBER path (project-org-routing-and-
|
|
148
|
+
* rehome spec §4.1, D14). The SOURCE is the caller's org context: the per-call
|
|
149
|
+
* `org` option (or the client `orgSlug`), never inferred from the project. A
|
|
150
|
+
* caller moving a project out of a work org must scope this call to that org;
|
|
151
|
+
* an unscoped call looks for the project in the caller's PERSONAL org and 404s.
|
|
152
|
+
* Authority: `admin`/`owner` in both orgs (§4.2); a personal-org TARGET only
|
|
153
|
+
* when the caller is that person (C6).
|
|
154
|
+
*
|
|
155
|
+
* After the move the old `(org, name)` address is a tombstone: an org-less
|
|
156
|
+
* write naming the project there gets `410 PROJECT_REHOMED` naming the target
|
|
157
|
+
* (`isProjectRehomedError`), not a forked new project. The move is reversible
|
|
158
|
+
* by moving back (a reversal annihilates the tombstone).
|
|
159
|
+
*
|
|
160
|
+
* Refusals (`rehomeRefusalReason(err)` reads the enumerated ones): 400
|
|
161
|
+
* `same_org` | `project_has_no_org`; 403 INSUFFICIENT_ORG_ROLE (source) |
|
|
162
|
+
* ORG_ACCESS_DENIED (target membership or personal target, C6) | ORG_SUSPENDED
|
|
163
|
+
* (C3); 402 PROJECT_LIMIT (target cap, C2); 409 `name_collision` |
|
|
164
|
+
* `soft_deleted_conflict` | `rehomed_away_conflict` (C1/C7) | `export_in_progress`
|
|
165
|
+
* (C4) | `moved_during_request` | MERGE_LOCK_UNAVAILABLE (details.retry_after_seconds;
|
|
166
|
+
* the SDK does NOT auto-retry).
|
|
167
|
+
*
|
|
168
|
+
* **Re-runs and lost responses.** The lookup is SOURCE-scoped, so after the
|
|
169
|
+
* move the same call (same source, same name) does not answer `same_org` — it
|
|
170
|
+
* answers 404 (by name, the address is now a tombstone; by id, the project is
|
|
171
|
+
* no longer in that org). `same_org` is the idempotence signal of the ADMIN
|
|
172
|
+
* path, whose lookup is by id and unscoped. If a member-path call times out
|
|
173
|
+
* or the response is lost, do not retry blind: read the project with
|
|
174
|
+
* `{ org: targetOrg }` (or check `admin.listProjectRehomeEvents` if you can) —
|
|
175
|
+
* a hit there means the move landed.
|
|
176
|
+
*
|
|
177
|
+
* @param client - HTTP client instance (scope it to the source org)
|
|
178
|
+
* @param idOrName - Project UUID or name, resolved in the source org
|
|
179
|
+
* @param input - `{ targetOrg, reason? }`
|
|
180
|
+
* @returns The project after the move (`orgId` is the target) plus `rehome.{from_org,to_org,audit_ids}`
|
|
181
|
+
* @throws {InputValidationError} If `targetOrg` is not a slug or `reason` is empty / over 500 chars
|
|
182
|
+
* @example
|
|
183
|
+
* ```typescript
|
|
184
|
+
* // the project lives in org "acme" → name the source; the target is the input
|
|
185
|
+
* const moved = await client.projects.rehome('billing', { targetOrg: 'ulu-labs', reason: 'team took it over' }, { org: 'acme' });
|
|
186
|
+
* moved.rehome.from_org.slug; // 'acme'
|
|
187
|
+
* moved.rehome.to_org.slug; // 'ulu-labs'
|
|
188
|
+
* ```
|
|
189
|
+
*/
|
|
190
|
+
export declare function rehome(client: OpsHttpClient, idOrName: string, input: RehomeProjectInput): Promise<RehomeResponse>;
|
|
145
191
|
//# sourceMappingURL=projects.d.ts.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"projects.d.ts","sourceRoot":"","sources":["../../src/operations/projects.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAE5D,OAAO,KAAK,EACV,OAAO,EACP,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,sBAAsB,EACtB,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACpB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;
|
|
1
|
+
{"version":3,"file":"projects.d.ts","sourceRoot":"","sources":["../../src/operations/projects.ts"],"names":[],"mappings":"AACA,OAAO,KAAK,EAAE,aAAa,EAAE,MAAM,wBAAwB,CAAC;AAE5D,OAAO,KAAK,EACV,OAAO,EACP,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,kBAAkB,EAClB,sBAAsB,EACtB,aAAa,EACb,kBAAkB,EAClB,sBAAsB,EACtB,qBAAqB,EACrB,qBAAqB,EACrB,gBAAgB,EAChB,iBAAiB,EACjB,kBAAkB,EAClB,mBAAmB,EACpB,MAAM,sBAAsB,CAAC;AAC9B,OAAO,KAAK,EAAE,kBAAkB,EAAE,cAAc,EAAE,MAAM,oBAAoB,CAAC;AAE7E,OAAO,KAAK,EAAE,KAAK,EAAE,MAAM,oBAAoB,CAAC;AAChD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,uBAAuB,CAAC;AAqB1D;;;;;GAKG;AACH,wBAAsB,IAAI,CAAC,MAAM,EAAE,aAAa,GAAG,OAAO,CAAC;IAAE,IAAI,EAAE,OAAO,EAAE,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,CAO7F;AAED;;;;;;;GAOG;AACH,w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;AACH,wBAAsB,UAAU,CAC9B,MAAM,EAAE,aAAa,EACrB,QAAQ,EAAE,MAAM,EAChB,KAAK,CAAC,EAAE,sBAAsB,GAC7B,OAAO,CAAC;IAAE,IAAI,EAAE,KAAK,EAAE,CAAC;IAAC,KAAK,EAAE,MAAM,CAAA;CAAE,CAAC,CAe3C;AAGD;;;;;;;GAOG;AACH,wBAAsB,qBAAqB,CACzC,MAAM,EAAE,aAAa,EACrB,QAAQ,EAAE,MAAM,EAChB,OAAO,EAAE,qBAAqB,EAAE,GAC/B,OAAO,CAAC,qBAAqB,CAAC,CAKhC;AAED;;;;;;;GAOG;AACH,wBAAsB,WAAW,CAC/B,MAAM,EAAE,aAAa,EACrB,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,gBAAgB,GACtB,OAAO,CAAC,iBAAiB,CAAC,CAS5B;AAED;;;;;;;;;;;;;;;GAeG;AAGH,wBAAsB,aAAa,CACjC,MAAM,EAAE,aAAa,EACrB,KAAK,EAAE,kBAAkB,GACxB,OAAO,CAAC,mBAAmB,CAAC,CAY9B;AAED;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2CG;AACH,wBAAsB,MAAM,CAC1B,MAAM,EAAE,aAAa,EACrB,QAAQ,EAAE,MAAM,EAChB,KAAK,EAAE,kBAAkB,GACxB,OAAO,CAAC,cAAc,CAAC,CASzB"}
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { z } from 'zod';
|
|
2
2
|
import { toApiQuery } from '../http/http-client.js';
|
|
3
|
+
import { RehomeResponseSchema } from '../types/rehome.js';
|
|
3
4
|
import { ProjectResponseSchema, ProjectSummaryResponseSchema, ProjectTrendsResponseSchema, IssueResponseSchema, BulkStatusUpdateResultResponseSchema, MergeIssuesResultResponseSchema, MergeProjectsResultResponseSchema, DeleteResultResponseSchema, } from '../types/response-schemas.js';
|
|
4
|
-
import { validateCreateProjectInput, validateUpdateProjectInput, validateDeleteProjectInput, validateRenameProjectInput, validateMergeProjectsInput, } from '../config/validators.js';
|
|
5
|
+
import { validateCreateProjectInput, validateUpdateProjectInput, validateDeleteProjectInput, validateRenameProjectInput, validateMergeProjectsInput, validateRehomeProjectInput, } from '../config/validators.js';
|
|
5
6
|
import { buildIssueListParams } from './query-utils.js';
|
|
6
7
|
/**
|
|
7
8
|
* List all projects accessible to the current user.
|
|
@@ -214,4 +215,56 @@ export async function mergeProjects(client, input) {
|
|
|
214
215
|
confirmCrossOrg: input.confirmCrossOrg,
|
|
215
216
|
}));
|
|
216
217
|
}
|
|
218
|
+
/**
|
|
219
|
+
* Move a project to another org — the MEMBER path (project-org-routing-and-
|
|
220
|
+
* rehome spec §4.1, D14). The SOURCE is the caller's org context: the per-call
|
|
221
|
+
* `org` option (or the client `orgSlug`), never inferred from the project. A
|
|
222
|
+
* caller moving a project out of a work org must scope this call to that org;
|
|
223
|
+
* an unscoped call looks for the project in the caller's PERSONAL org and 404s.
|
|
224
|
+
* Authority: `admin`/`owner` in both orgs (§4.2); a personal-org TARGET only
|
|
225
|
+
* when the caller is that person (C6).
|
|
226
|
+
*
|
|
227
|
+
* After the move the old `(org, name)` address is a tombstone: an org-less
|
|
228
|
+
* write naming the project there gets `410 PROJECT_REHOMED` naming the target
|
|
229
|
+
* (`isProjectRehomedError`), not a forked new project. The move is reversible
|
|
230
|
+
* by moving back (a reversal annihilates the tombstone).
|
|
231
|
+
*
|
|
232
|
+
* Refusals (`rehomeRefusalReason(err)` reads the enumerated ones): 400
|
|
233
|
+
* `same_org` | `project_has_no_org`; 403 INSUFFICIENT_ORG_ROLE (source) |
|
|
234
|
+
* ORG_ACCESS_DENIED (target membership or personal target, C6) | ORG_SUSPENDED
|
|
235
|
+
* (C3); 402 PROJECT_LIMIT (target cap, C2); 409 `name_collision` |
|
|
236
|
+
* `soft_deleted_conflict` | `rehomed_away_conflict` (C1/C7) | `export_in_progress`
|
|
237
|
+
* (C4) | `moved_during_request` | MERGE_LOCK_UNAVAILABLE (details.retry_after_seconds;
|
|
238
|
+
* the SDK does NOT auto-retry).
|
|
239
|
+
*
|
|
240
|
+
* **Re-runs and lost responses.** The lookup is SOURCE-scoped, so after the
|
|
241
|
+
* move the same call (same source, same name) does not answer `same_org` — it
|
|
242
|
+
* answers 404 (by name, the address is now a tombstone; by id, the project is
|
|
243
|
+
* no longer in that org). `same_org` is the idempotence signal of the ADMIN
|
|
244
|
+
* path, whose lookup is by id and unscoped. If a member-path call times out
|
|
245
|
+
* or the response is lost, do not retry blind: read the project with
|
|
246
|
+
* `{ org: targetOrg }` (or check `admin.listProjectRehomeEvents` if you can) —
|
|
247
|
+
* a hit there means the move landed.
|
|
248
|
+
*
|
|
249
|
+
* @param client - HTTP client instance (scope it to the source org)
|
|
250
|
+
* @param idOrName - Project UUID or name, resolved in the source org
|
|
251
|
+
* @param input - `{ targetOrg, reason? }`
|
|
252
|
+
* @returns The project after the move (`orgId` is the target) plus `rehome.{from_org,to_org,audit_ids}`
|
|
253
|
+
* @throws {InputValidationError} If `targetOrg` is not a slug or `reason` is empty / over 500 chars
|
|
254
|
+
* @example
|
|
255
|
+
* ```typescript
|
|
256
|
+
* // the project lives in org "acme" → name the source; the target is the input
|
|
257
|
+
* const moved = await client.projects.rehome('billing', { targetOrg: 'ulu-labs', reason: 'team took it over' }, { org: 'acme' });
|
|
258
|
+
* moved.rehome.from_org.slug; // 'acme'
|
|
259
|
+
* moved.rehome.to_org.slug; // 'ulu-labs'
|
|
260
|
+
* ```
|
|
261
|
+
*/
|
|
262
|
+
export async function rehome(client, idOrName, input) {
|
|
263
|
+
const valid = validateRehomeProjectInput(input);
|
|
264
|
+
return RehomeResponseSchema.parse(await client.post(`/projects/${encodeURIComponent(idOrName)}/rehome`,
|
|
265
|
+
// The API body is `.strict()` (a typo'd key is a 400, not a stripped one),
|
|
266
|
+
// so only the two contract fields go on the wire, and `reason` is omitted
|
|
267
|
+
// rather than sent as undefined/null.
|
|
268
|
+
{ target_org: valid.targetOrg, ...(valid.reason !== undefined ? { reason: valid.reason } : {}) }));
|
|
269
|
+
}
|
|
217
270
|
//# sourceMappingURL=projects.js.map
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"projects.js","sourceRoot":"","sources":["../../src/operations/projects.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;
|
|
1
|
+
{"version":3,"file":"projects.js","sourceRoot":"","sources":["../../src/operations/projects.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AAExB,OAAO,EAAE,UAAU,EAAE,MAAM,wBAAwB,CAAC;AAmBpD,OAAO,EAAE,oBAAoB,EAAE,MAAM,oBAAoB,CAAC;AAG1D,OAAO,EACL,qBAAqB,EACrB,4BAA4B,EAC5B,2BAA2B,EAC3B,mBAAmB,EACnB,oCAAoC,EACpC,+BAA+B,EAC/B,iCAAiC,EACjC,0BAA0B,GAC3B,MAAM,8BAA8B,CAAC;AACtC,OAAO,EACL,0BAA0B,EAC1B,0BAA0B,EAC1B,0BAA0B,EAC1B,0BAA0B,EAC1B,0BAA0B,EAC1B,0BAA0B,GAC3B,MAAM,yBAAyB,CAAC;AACjC,OAAO,EAAE,oBAAoB,EAAE,MAAM,kBAAkB,CAAC;AAExD;;;;;GAKG;AACH,MAAM,CAAC,KAAK,UAAU,IAAI,CAAC,MAAqB;IAC9C,qEAAqE;IACrE,uEAAuE;IACvE,OAAO,CAAC,CAAC,MAAM,CAAC;QACd,IAAI,EAAE,CAAC,CAAC,KAAK,CAAC,qBAAqB,CAAC;QACpC,KAAK,EAAE,CAAC,CAAC,MAAM,EAAE,CAAC,GAAG,EAAE,CAAC,WAAW,EAAE;KACtC,CAAC,CAAC,KAAK,CAAC,MAAM,MAAM,CAAC,OAAO,CAAU,KAAK,EAAE,WAAW,EAAE,SAAS,EAAE,EAAE,WAAW,EAAE,IAAI,EAAE,CAAC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/types/auth.d.ts
CHANGED
|
@@ -48,6 +48,16 @@ export interface LoginInput {
|
|
|
48
48
|
email: string;
|
|
49
49
|
password: string;
|
|
50
50
|
}
|
|
51
|
+
/**
|
|
52
|
+
* TOTP completion of an MFA-challenged login (`POST /auth/totp/login`).
|
|
53
|
+
* `mfaChallengeToken` comes from the {@link MfaRequiredError} the first login threw.
|
|
54
|
+
*/
|
|
55
|
+
export interface TotpLoginInput {
|
|
56
|
+
mfaChallengeToken: string;
|
|
57
|
+
/** Six digits. */
|
|
58
|
+
code: string;
|
|
59
|
+
rememberMe?: boolean;
|
|
60
|
+
}
|
|
51
61
|
/**
|
|
52
62
|
* Profile update input
|
|
53
63
|
*/
|
package/dist/types/auth.d.ts.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"auth.d.ts","sourceRoot":"","sources":["../../src/types/auth.ts"],"names":[],"mappings":"AAAA,OAAO,EAAE,CAAC,EAAE,MAAM,KAAK,CAAC;AACxB,OAAO,KAAK,EAAE,QAAQ,EAAE,gBAAgB,EAAE,cAAc,EAAE,MAAM,YAAY,CAAC;AAC7E,OAAO,EACL,sBAAsB,EACtB,wBAAwB,EACxB,mBAAmB,EACnB,sBAAsB,EACtB,0BAA0B,EAC1B,2BAA2B,EAC3B,2BAA2B,EAC5B,MAAM,uBAAuB,CAAC;AAM/B,8CAA8C;AAC9C,MAAM,MAAM,QAAQ,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAE9D,+CAA+C;AAC/C,MAAM,MAAM,UAAU,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,wBAAwB,CAAC,CAAC;AAElE,qBAAqB;AACrB,MAAM,MAAM,aAAa,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,mBAAmB,CAAC,CAAC;AAEhE,wBAAwB;AACxB,MAAM,MAAM,gBAAgB,GAAG,CAAC,CAAC,KAAK,CAAC,OAAO,sBAAsB,CAAC,CAAC;AAEtE,8C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C;CACrB;AAED;;GAEG;AACH,MAAM,WAAW,mBAAmB;IAClC,KAAK,EAAE,MAAM,CAAC;CACf;AAED;;GAEG;AACH,MAAM,WAAW,kBAAkB;IACjC,KAAK,EAAE,MAAM,CAAC;IACd,QAAQ,EAAE,MAAM,CAAC;CAClB;AAED;;GAEG;AACH,MAAM,WAAW,iBAAiB;IAChC,IAAI,CAAC,EAAE,MAAM,CAAC;IACd,SAAS,CAAC,EAAE,MAAM,CAAC;IACnB,gGAAgG;IAChG,KAAK,CAAC,EAAE,MAAM,GAAG,OAAO,CAAC;CAC1B;AAED;;GAEG;AACH,MAAM,WAAW,MAAM;IACrB,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,OAAO,EAAE,MAAM,CAAC;IAChB,IAAI,EAAE,MAAM,GAAG,IAAI,CAAC;IACpB,UAAU,EAAE,MAAM,GAAG,IAAI,CAAC;IAC1B,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,EAAE,MAAM,CAAC;CACnB;AAED;;GAEG;AACH,MAAM,WAAW,OAAO;IACtB,EAAE,EAAE,MAAM,CAAC;IACX,MAAM,EAAE,MAAM,CAAC;IACf,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,SAAS,EAAE,MAAM,CAAC;IAClB,YAAY,EAAE,MAAM,CAAC;IACrB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;IACzB,SAAS,EAAE,MAAM,GAAG,IAAI,CAAC;CAC1B"}
|
package/dist/types/index.d.ts
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AACA,cAAc,YAAY,CAAC;AAG3B,cAAc,WAAW,CAAC;AAG1B,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAG/B,cAAc,gBAAgB,CAAC;AAG/B,cAAc,cAAc,CAAC"}
|
|
1
|
+
{"version":3,"file":"index.d.ts","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AACA,cAAc,YAAY,CAAC;AAG3B,cAAc,WAAW,CAAC;AAG1B,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAG/B,cAAc,gBAAgB,CAAC;AAG/B,cAAc,cAAc,CAAC"}
|
package/dist/types/index.js
CHANGED
package/dist/types/index.js.map
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,QAAQ;AACR,cAAc,YAAY,CAAC;AAE3B,aAAa;AACb,cAAc,WAAW,CAAC;AAE1B,eAAe;AACf,cAAc,UAAU,CAAC;AACzB,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAE/B,iBAAiB;AACjB,cAAc,gBAAgB,CAAC;AAE/B,iCAAiC;AACjC,cAAc,cAAc,CAAC;AAE7B,qGAAqG"}
|
|
1
|
+
{"version":3,"file":"index.js","sourceRoot":"","sources":["../../src/types/index.ts"],"names":[],"mappings":"AAAA,QAAQ;AACR,cAAc,YAAY,CAAC;AAE3B,aAAa;AACb,cAAc,WAAW,CAAC;AAE1B,eAAe;AACf,cAAc,UAAU,CAAC;AACzB,cAAc,aAAa,CAAC;AAC5B,cAAc,eAAe,CAAC;AAC9B,cAAc,WAAW,CAAC;AAC1B,cAAc,aAAa,CAAC;AAC5B,cAAc,gBAAgB,CAAC;AAE/B,iBAAiB;AACjB,cAAc,gBAAgB,CAAC;AAE/B,iCAAiC;AACjC,cAAc,cAAc,CAAC;AAE7B,qGAAqG"}
|