@toa.io/extensions.exposition 1.0.0-alpha.282 → 1.0.0-alpha.283
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 +27 -0
- package/components/exposition.octets/manifest.toa.yaml +11 -0
- package/components/exposition.octets/types/index.d.ts +3 -0
- package/components/exposition.octets/types/toa.d.ts +41 -0
- package/components/identity.bans/types/index.d.ts +3 -0
- package/components/identity.bans/types/toa.d.ts +34 -0
- package/components/identity.basic/manifest.toa.yaml +13 -2
- package/components/identity.basic/operations/add.d.ts +3 -3
- package/components/identity.basic/operations/authenticate.d.ts +2 -2
- package/components/identity.basic/operations/check.d.ts +1 -1
- package/components/identity.basic/operations/delete.d.ts +2 -2
- package/components/identity.basic/operations/incept.d.ts +2 -2
- package/components/identity.basic/operations/info.d.ts +1 -1
- package/components/identity.basic/operations/transit.d.ts +4 -3
- package/components/identity.basic/operations/transit.js +2 -1
- package/components/identity.basic/operations/transit.js.map +1 -1
- package/components/identity.basic/source/add.ts +3 -3
- package/components/identity.basic/source/authenticate.ts +2 -2
- package/components/identity.basic/source/check.ts +1 -1
- package/components/identity.basic/source/delete.ts +2 -2
- package/components/identity.basic/source/incept.ts +2 -2
- package/components/identity.basic/source/info.ts +1 -1
- package/components/identity.basic/source/transit.ts +6 -4
- package/components/identity.basic/tsconfig.tsbuildinfo +1 -1
- package/components/identity.basic/types/index.d.ts +21 -0
- package/components/identity.basic/types/toa.d.ts +121 -0
- package/components/identity.clients/manifest.toa.yaml +243 -0
- package/components/identity.clients/operations/describe.d.ts +27 -0
- package/components/identity.clients/operations/describe.js +44 -0
- package/components/identity.clients/operations/describe.js.map +1 -0
- package/components/identity.clients/operations/lib/Context.d.ts +29 -0
- package/components/identity.clients/operations/lib/Context.js +2 -0
- package/components/identity.clients/operations/lib/Context.js.map +1 -0
- package/components/identity.clients/operations/lib/Entity.d.ts +29 -0
- package/components/identity.clients/operations/lib/Entity.js +2 -0
- package/components/identity.clients/operations/lib/Entity.js.map +1 -0
- package/components/identity.clients/operations/lib/canonical.d.ts +11 -0
- package/components/identity.clients/operations/lib/canonical.js +24 -0
- package/components/identity.clients/operations/lib/canonical.js.map +1 -0
- package/components/identity.clients/operations/lib/cimd.d.ts +8 -0
- package/components/identity.clients/operations/lib/cimd.js +86 -0
- package/components/identity.clients/operations/lib/cimd.js.map +1 -0
- package/components/identity.clients/operations/lib/errors.d.ts +7 -0
- package/components/identity.clients/operations/lib/errors.js +5 -0
- package/components/identity.clients/operations/lib/errors.js.map +1 -0
- package/components/identity.clients/operations/lib/index.d.ts +6 -0
- package/components/identity.clients/operations/lib/index.js +7 -0
- package/components/identity.clients/operations/lib/index.js.map +1 -0
- package/components/identity.clients/operations/lib/redirect.d.ts +10 -0
- package/components/identity.clients/operations/lib/redirect.js +32 -0
- package/components/identity.clients/operations/lib/redirect.js.map +1 -0
- package/components/identity.clients/operations/register.d.ts +37 -0
- package/components/identity.clients/operations/register.js +84 -0
- package/components/identity.clients/operations/register.js.map +1 -0
- package/components/identity.clients/source/describe.ts +65 -0
- package/components/identity.clients/source/lib/Context.ts +38 -0
- package/components/identity.clients/source/lib/Entity.ts +31 -0
- package/components/identity.clients/source/lib/canonical.test.ts +43 -0
- package/components/identity.clients/source/lib/canonical.ts +27 -0
- package/components/identity.clients/source/lib/cimd.test.ts +120 -0
- package/components/identity.clients/source/lib/cimd.ts +107 -0
- package/components/identity.clients/source/lib/errors.ts +4 -0
- package/components/identity.clients/source/lib/index.ts +6 -0
- package/components/identity.clients/source/lib/redirect.test.ts +41 -0
- package/components/identity.clients/source/lib/redirect.ts +35 -0
- package/components/identity.clients/source/register.ts +125 -0
- package/components/identity.clients/tsconfig.json +10 -0
- package/components/identity.clients/tsconfig.tsbuildinfo +1 -0
- package/components/identity.clients/types/index.d.ts +3 -0
- package/components/identity.clients/types/toa.d.ts +109 -0
- package/components/identity.credentials/operations/list.d.ts +2 -1
- package/components/identity.credentials/operations/list.js.map +1 -1
- package/components/identity.credentials/source/list.ts +2 -1
- package/components/identity.credentials/tsconfig.tsbuildinfo +1 -1
- package/components/identity.credentials/types/index.d.ts +3 -0
- package/components/identity.credentials/types/toa.d.ts +30 -0
- package/components/identity.federation/manifest.toa.yaml +37 -1
- package/components/identity.federation/operations/authenticate.d.ts +1 -1
- package/components/identity.federation/operations/lib/Ctx.d.ts +2 -2
- package/components/identity.federation/operations/lib/decode.js +22 -8
- package/components/identity.federation/operations/lib/decode.js.map +1 -1
- package/components/identity.federation/operations/lib/errors.d.ts +7 -0
- package/components/identity.federation/operations/lib/errors.js +4 -0
- package/components/identity.federation/operations/lib/errors.js.map +1 -1
- package/components/identity.federation/operations/lib/exchange.js +11 -6
- package/components/identity.federation/operations/lib/exchange.js.map +1 -1
- package/components/identity.federation/operations/types/configuration.d.ts +1 -1
- package/components/identity.federation/operations/types/context.d.ts +3 -2
- package/components/identity.federation/source/authenticate.ts +1 -1
- package/components/identity.federation/source/lib/Ctx.ts +2 -2
- package/components/identity.federation/source/lib/decode.ts +25 -9
- package/components/identity.federation/source/lib/errors.ts +5 -0
- package/components/identity.federation/source/lib/exchange.ts +11 -7
- package/components/identity.federation/source/types/configuration.ts +1 -1
- package/components/identity.federation/source/types/context.ts +3 -2
- package/components/identity.federation/tsconfig.tsbuildinfo +1 -1
- package/components/identity.federation/types/index.d.ts +3 -0
- package/components/identity.federation/types/toa.d.ts +127 -0
- package/components/identity.grants/manifest.toa.yaml +245 -0
- package/components/identity.grants/operations/authorize.d.ts +35 -0
- package/components/identity.grants/operations/authorize.js +54 -0
- package/components/identity.grants/operations/authorize.js.map +1 -0
- package/components/identity.grants/operations/exchange.d.ts +37 -0
- package/components/identity.grants/operations/exchange.js +89 -0
- package/components/identity.grants/operations/exchange.js.map +1 -0
- package/components/identity.grants/operations/lib/code.d.ts +15 -0
- package/components/identity.grants/operations/lib/code.js +30 -0
- package/components/identity.grants/operations/lib/code.js.map +1 -0
- package/components/identity.grants/operations/lib/identify.d.ts +6 -0
- package/components/identity.grants/operations/lib/identify.js +15 -0
- package/components/identity.grants/operations/lib/identify.js.map +1 -0
- package/components/identity.grants/operations/lib/index.d.ts +3 -0
- package/components/identity.grants/operations/lib/index.js +3 -0
- package/components/identity.grants/operations/lib/index.js.map +1 -0
- package/components/identity.grants/operations/list.d.ts +13 -0
- package/components/identity.grants/operations/list.js +18 -0
- package/components/identity.grants/operations/list.js.map +1 -0
- package/components/identity.grants/operations/revoke.d.ts +18 -0
- package/components/identity.grants/operations/revoke.js +25 -0
- package/components/identity.grants/operations/revoke.js.map +1 -0
- package/components/identity.grants/source/authorize.ts +90 -0
- package/components/identity.grants/source/exchange.ts +130 -0
- package/components/identity.grants/source/lib/code.ts +39 -0
- package/components/identity.grants/source/lib/identify.ts +16 -0
- package/components/identity.grants/source/lib/index.ts +3 -0
- package/components/identity.grants/source/list.ts +28 -0
- package/components/identity.grants/source/revoke.ts +38 -0
- package/components/identity.grants/tsconfig.json +10 -0
- package/components/identity.grants/tsconfig.tsbuildinfo +1 -0
- package/components/identity.grants/types/index.d.ts +60 -0
- package/components/identity.grants/types/toa.d.ts +108 -0
- package/components/identity.keys/manifest.toa.yaml +1 -0
- package/components/identity.keys/operations/create.d.ts +1 -1
- package/components/identity.keys/operations/revoke.d.ts +1 -1
- package/components/identity.keys/source/create.ts +1 -1
- package/components/identity.keys/source/revoke.ts +1 -1
- package/components/identity.keys/tsconfig.tsbuildinfo +1 -1
- package/components/identity.keys/types/index.d.ts +3 -0
- package/components/identity.keys/types/toa.d.ts +47 -0
- package/components/identity.otp/operations/lib/Context.d.ts +4 -2
- package/components/identity.otp/source/lib/Context.ts +4 -2
- package/components/identity.otp/tsconfig.tsbuildinfo +1 -1
- package/components/identity.otp/types/index.d.ts +3 -0
- package/components/identity.otp/types/toa.d.ts +56 -0
- package/components/identity.passkeys/manifest.toa.yaml +3 -0
- package/components/identity.passkeys/operations/authenticate.d.ts +1 -1
- package/components/identity.passkeys/operations/challenge.d.ts +1 -1
- package/components/identity.passkeys/operations/create.d.ts +1 -1
- package/components/identity.passkeys/operations/types/Context.d.ts +2 -1
- package/components/identity.passkeys/operations/use.d.ts +1 -1
- package/components/identity.passkeys/source/authenticate.ts +1 -1
- package/components/identity.passkeys/source/challenge.ts +1 -1
- package/components/identity.passkeys/source/create.ts +1 -1
- package/components/identity.passkeys/source/types/Context.ts +2 -1
- package/components/identity.passkeys/source/use.ts +1 -1
- package/components/identity.passkeys/tsconfig.tsbuildinfo +1 -1
- package/components/identity.passkeys/types/index.d.ts +3 -0
- package/components/identity.passkeys/types/toa.d.ts +120 -0
- package/components/identity.roles/operations/principal.d.ts +1 -1
- package/components/identity.roles/source/principal.ts +1 -1
- package/components/identity.roles/tsconfig.tsbuildinfo +1 -1
- package/components/identity.roles/types/index.d.ts +3 -0
- package/components/identity.roles/types/toa.d.ts +43 -0
- package/components/identity.tokens/manifest.toa.yaml +34 -3
- package/components/identity.tokens/operations/authenticate.d.ts +2 -1
- package/components/identity.tokens/operations/authenticate.js +8 -0
- package/components/identity.tokens/operations/authenticate.js.map +1 -1
- package/components/identity.tokens/operations/decrypt.d.ts +2 -1
- package/components/identity.tokens/operations/decrypt.js +2 -2
- package/components/identity.tokens/operations/decrypt.js.map +1 -1
- package/components/identity.tokens/operations/encrypt.d.ts +2 -1
- package/components/identity.tokens/operations/encrypt.js.map +1 -1
- package/components/identity.tokens/operations/issue.d.ts +2 -1
- package/components/identity.tokens/operations/issue.js +2 -1
- package/components/identity.tokens/operations/issue.js.map +1 -1
- package/components/identity.tokens/operations/lib/form.d.ts +8 -0
- package/components/identity.tokens/operations/lib/form.js +24 -0
- package/components/identity.tokens/operations/lib/form.js.map +1 -0
- package/components/identity.tokens/operations/lib/index.d.ts +2 -1
- package/components/identity.tokens/operations/lib/index.js +1 -1
- package/components/identity.tokens/operations/lib/index.js.map +1 -1
- package/components/identity.tokens/source/authenticate.test.ts +8 -5
- package/components/identity.tokens/source/authenticate.ts +12 -1
- package/components/identity.tokens/source/decrypt.test.ts +1 -1
- package/components/identity.tokens/source/decrypt.ts +4 -3
- package/components/identity.tokens/source/encrypt.test.ts +1 -1
- package/components/identity.tokens/source/encrypt.ts +2 -1
- package/components/identity.tokens/source/issue.test.ts +71 -0
- package/components/identity.tokens/source/issue.ts +4 -2
- package/components/identity.tokens/source/lib/form.test.ts +25 -0
- package/components/identity.tokens/source/lib/form.ts +31 -0
- package/components/identity.tokens/source/lib/index.ts +2 -1
- package/components/identity.tokens/tsconfig.tsbuildinfo +1 -1
- package/components/identity.tokens/types/index.d.ts +61 -0
- package/components/identity.tokens/types/toa.d.ts +113 -0
- package/documentation/cache.md +10 -1
- package/documentation/consent.md +101 -0
- package/documentation/identity.md +3 -1
- package/documentation/io.md +36 -2
- package/documentation/oauth.md +179 -0
- package/documentation/protocol.md +4 -0
- package/features/auth.bearer.feature +120 -0
- package/features/cache.feature +46 -0
- package/features/oauth.clients.feature +195 -0
- package/features/oauth.discovery.feature +165 -0
- package/features/oauth.grants.feature +286 -0
- package/features/steps/Gateway.ts +6 -1
- package/features/steps/Parameters.ts +4 -0
- package/features/steps/components/echo/manifest.toa.yaml +2 -0
- package/features/steps/components/octets.tester/manifest.toa.yaml +2 -0
- package/features/steps/components/octets.tester/operations/redirect.js +6 -1
- package/features/steps/components/users/manifest.toa.yaml +1 -0
- package/package.json +8 -6
- package/readme.md +3 -0
- package/schemas/annotation.cos.yaml +30 -0
- package/source/Annotation.ts +23 -0
- package/source/Factory.ts +1 -1
- package/source/HTTP/Server.ts +9 -5
- package/source/HTTP/formats/form.ts +21 -0
- package/source/HTTP/formats/index.ts +17 -2
- package/source/HTTP/messages.test.ts +25 -1
- package/source/HTTP/messages.ts +10 -3
- package/source/Interception.ts +8 -2
- package/source/deployment.ts +4 -1
- package/source/directives/auth/Authorization.ts +46 -19
- package/source/directives/auth/Incept.ts +14 -9
- package/source/directives/auth/schemes.test.ts +8 -4
- package/source/directives/auth/schemes.ts +22 -9
- package/source/directives/auth/types.ts +5 -2
- package/source/directives/cache/Cache.ts +13 -4
- package/source/directives/cache/Control.ts +0 -3
- package/source/directives/flow/Fetch.ts +1 -1
- package/source/directives/index.ts +2 -1
- package/source/directives/io/IO.ts +2 -0
- package/source/directives/io/Output.ts +4 -1
- package/source/directives/io/Status.test.ts +84 -0
- package/source/directives/io/Status.ts +46 -0
- package/source/directives/oauth/Discovery.ts +76 -0
- package/source/directives/oauth/documents.ts +113 -0
- package/source/directives/oauth/index.ts +3 -0
- package/source/directives/octets/Delete.ts +1 -1
- package/source/directives/octets/Get.ts +1 -1
- package/source/directives/octets/Workflow.ts +1 -1
- package/source/directives/octets/workflows/Execution.ts +1 -1
- package/source/index.ts +6 -0
- package/source/octets.d.ts +17 -0
- package/source/userland.ts +47 -0
- package/transpiled/Annotation.d.ts +17 -0
- package/transpiled/Factory.js +1 -1
- package/transpiled/Factory.js.map +1 -1
- package/transpiled/HTTP/Server.d.ts +4 -1
- package/transpiled/HTTP/Server.js +4 -3
- package/transpiled/HTTP/Server.js.map +1 -1
- package/transpiled/HTTP/formats/form.d.ts +9 -0
- package/transpiled/HTTP/formats/form.js +18 -0
- package/transpiled/HTTP/formats/form.js.map +1 -0
- package/transpiled/HTTP/formats/index.d.ts +10 -2
- package/transpiled/HTTP/formats/index.js +10 -0
- package/transpiled/HTTP/formats/index.js.map +1 -1
- package/transpiled/HTTP/messages.d.ts +6 -0
- package/transpiled/HTTP/messages.js +3 -3
- package/transpiled/HTTP/messages.js.map +1 -1
- package/transpiled/Interception.d.ts +4 -1
- package/transpiled/Interception.js +4 -2
- package/transpiled/Interception.js.map +1 -1
- package/transpiled/deployment.js +2 -0
- package/transpiled/deployment.js.map +1 -1
- package/transpiled/directives/auth/Authorization.d.ts +1 -1
- package/transpiled/directives/auth/Authorization.js +38 -18
- package/transpiled/directives/auth/Authorization.js.map +1 -1
- package/transpiled/directives/auth/Incept.d.ts +1 -1
- package/transpiled/directives/auth/Incept.js +11 -7
- package/transpiled/directives/auth/Incept.js.map +1 -1
- package/transpiled/directives/auth/schemes.d.ts +16 -4
- package/transpiled/directives/auth/schemes.js +20 -8
- package/transpiled/directives/auth/schemes.js.map +1 -1
- package/transpiled/directives/auth/types.d.ts +4 -2
- package/transpiled/directives/cache/Cache.js +9 -2
- package/transpiled/directives/cache/Cache.js.map +1 -1
- package/transpiled/directives/cache/Control.js +0 -2
- package/transpiled/directives/cache/Control.js.map +1 -1
- package/transpiled/directives/index.js +2 -1
- package/transpiled/directives/index.js.map +1 -1
- package/transpiled/directives/io/IO.js +2 -0
- package/transpiled/directives/io/IO.js.map +1 -1
- package/transpiled/directives/io/Output.js +4 -1
- package/transpiled/directives/io/Output.js.map +1 -1
- package/transpiled/directives/io/Status.d.ts +19 -0
- package/transpiled/directives/io/Status.js +34 -0
- package/transpiled/directives/io/Status.js.map +1 -0
- package/transpiled/directives/oauth/Discovery.d.ts +23 -0
- package/transpiled/directives/oauth/Discovery.js +58 -0
- package/transpiled/directives/oauth/Discovery.js.map +1 -0
- package/transpiled/directives/oauth/documents.d.ts +9 -0
- package/transpiled/directives/oauth/documents.js +82 -0
- package/transpiled/directives/oauth/documents.js.map +1 -0
- package/transpiled/directives/oauth/index.d.ts +2 -0
- package/transpiled/directives/oauth/index.js +3 -0
- package/transpiled/directives/oauth/index.js.map +1 -0
- package/transpiled/index.d.ts +2 -0
- package/transpiled/userland.d.ts +39 -0
- package/transpiled/userland.js +7 -0
- package/transpiled/userland.js.map +1 -0
- package/tsconfig.tsbuildinfo +1 -1
- package/components/identity.basic/operations/types.d.ts +0 -61
- package/components/identity.basic/operations/types.js +0 -2
- package/components/identity.basic/operations/types.js.map +0 -1
- package/components/identity.basic/source/types.ts +0 -69
- package/components/identity.tokens/operations/lib/types.d.ts +0 -88
- package/components/identity.tokens/operations/lib/types.js +0 -2
- package/components/identity.tokens/operations/lib/types.js.map +0 -1
- package/components/identity.tokens/source/lib/types.ts +0 -102
|
@@ -1,61 +0,0 @@
|
|
|
1
|
-
import { type Call, type Maybe, type Observation, type Query, type Secret, type Transition } from '@toa.io/types';
|
|
2
|
-
export interface Context {
|
|
3
|
-
local: {
|
|
4
|
-
observe: Observation<Maybe<Entity>>;
|
|
5
|
-
terminate: Transition<void, void, Entity>;
|
|
6
|
-
transit: Call<IdOutput, TransitInput>;
|
|
7
|
-
create: Call<IdOutput, TransitInput>;
|
|
8
|
-
};
|
|
9
|
-
remote: {
|
|
10
|
-
identity: {
|
|
11
|
-
tokens: {
|
|
12
|
-
revoke: Call<void, IdentityTokensRevokeInput>;
|
|
13
|
-
};
|
|
14
|
-
keys: {
|
|
15
|
-
revoke: Call<void, IdentityKeysRevokeInput>;
|
|
16
|
-
};
|
|
17
|
-
};
|
|
18
|
-
};
|
|
19
|
-
configuration: {
|
|
20
|
-
readonly rounds: number;
|
|
21
|
-
readonly pepper?: Secret;
|
|
22
|
-
readonly principal?: Principal;
|
|
23
|
-
readonly username: string[];
|
|
24
|
-
readonly password: string[];
|
|
25
|
-
};
|
|
26
|
-
}
|
|
27
|
-
export interface Principal {
|
|
28
|
-
authority: string;
|
|
29
|
-
username: string;
|
|
30
|
-
}
|
|
31
|
-
export interface Entity {
|
|
32
|
-
id: string;
|
|
33
|
-
authority: string;
|
|
34
|
-
username: string;
|
|
35
|
-
password: string;
|
|
36
|
-
readonly _version: number;
|
|
37
|
-
/** Deletion timestamp; `null` or absent while the credentials are in effect. */
|
|
38
|
-
_deleted?: number | null;
|
|
39
|
-
}
|
|
40
|
-
export interface TransitInput {
|
|
41
|
-
authority: string;
|
|
42
|
-
username?: string;
|
|
43
|
-
password?: string;
|
|
44
|
-
inception?: boolean;
|
|
45
|
-
}
|
|
46
|
-
export interface AddInput {
|
|
47
|
-
id: string;
|
|
48
|
-
authority: string;
|
|
49
|
-
username: string;
|
|
50
|
-
password: string;
|
|
51
|
-
}
|
|
52
|
-
export interface IdOutput {
|
|
53
|
-
id: string;
|
|
54
|
-
}
|
|
55
|
-
interface IdentityTokensRevokeInput {
|
|
56
|
-
query: Query;
|
|
57
|
-
}
|
|
58
|
-
interface IdentityKeysRevokeInput {
|
|
59
|
-
identity: string;
|
|
60
|
-
}
|
|
61
|
-
export {};
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../source/types.ts"],"names":[],"mappings":""}
|
|
@@ -1,69 +0,0 @@
|
|
|
1
|
-
import { type Call, type Maybe, type Observation, type Query, type Secret, type Transition } from '@toa.io/types'
|
|
2
|
-
|
|
3
|
-
export interface Context {
|
|
4
|
-
local: {
|
|
5
|
-
observe: Observation<Maybe<Entity>>
|
|
6
|
-
terminate: Transition<void, void, Entity>
|
|
7
|
-
transit: Call<IdOutput, TransitInput>
|
|
8
|
-
create: Call<IdOutput, TransitInput>
|
|
9
|
-
}
|
|
10
|
-
remote: {
|
|
11
|
-
identity: {
|
|
12
|
-
tokens: {
|
|
13
|
-
revoke: Call<void, IdentityTokensRevokeInput>
|
|
14
|
-
}
|
|
15
|
-
keys: {
|
|
16
|
-
revoke: Call<void, IdentityKeysRevokeInput>
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
configuration: {
|
|
21
|
-
readonly rounds: number
|
|
22
|
-
readonly pepper?: Secret
|
|
23
|
-
readonly principal?: Principal
|
|
24
|
-
readonly username: string[]
|
|
25
|
-
readonly password: string[]
|
|
26
|
-
}
|
|
27
|
-
}
|
|
28
|
-
|
|
29
|
-
export interface Principal {
|
|
30
|
-
authority: string
|
|
31
|
-
username: string
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
export interface Entity {
|
|
35
|
-
id: string
|
|
36
|
-
authority: string
|
|
37
|
-
username: string
|
|
38
|
-
password: string
|
|
39
|
-
readonly _version: number
|
|
40
|
-
|
|
41
|
-
/** Deletion timestamp; `null` or absent while the credentials are in effect. */
|
|
42
|
-
_deleted?: number | null
|
|
43
|
-
}
|
|
44
|
-
|
|
45
|
-
export interface TransitInput {
|
|
46
|
-
authority: string
|
|
47
|
-
username?: string
|
|
48
|
-
password?: string
|
|
49
|
-
inception?: boolean
|
|
50
|
-
}
|
|
51
|
-
|
|
52
|
-
export interface AddInput {
|
|
53
|
-
id: string
|
|
54
|
-
authority: string
|
|
55
|
-
username: string
|
|
56
|
-
password: string
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
export interface IdOutput {
|
|
60
|
-
id: string
|
|
61
|
-
}
|
|
62
|
-
|
|
63
|
-
interface IdentityTokensRevokeInput {
|
|
64
|
-
query: Query
|
|
65
|
-
}
|
|
66
|
-
|
|
67
|
-
interface IdentityKeysRevokeInput {
|
|
68
|
-
identity: string
|
|
69
|
-
}
|
|
@@ -1,88 +0,0 @@
|
|
|
1
|
-
import type { Call, Maybe, Observation, Secret, telemetry } from '@toa.io/types';
|
|
2
|
-
export interface Context {
|
|
3
|
-
local: {
|
|
4
|
-
observe: Observation<Entity>;
|
|
5
|
-
encrypt: Call<Maybe<string>, EncryptInput>;
|
|
6
|
-
decrypt: Call<Maybe<DecryptOutput>, string>;
|
|
7
|
-
};
|
|
8
|
-
remote: {
|
|
9
|
-
identity: {
|
|
10
|
-
keys: {
|
|
11
|
-
observe: Observation<CustomKey>;
|
|
12
|
-
create: Call<Key>;
|
|
13
|
-
};
|
|
14
|
-
roles: {
|
|
15
|
-
list: Call<string[]>;
|
|
16
|
-
};
|
|
17
|
-
};
|
|
18
|
-
};
|
|
19
|
-
configuration: Configuration;
|
|
20
|
-
logs: telemetry.Logs;
|
|
21
|
-
}
|
|
22
|
-
export interface Configuration {
|
|
23
|
-
readonly keys: ConfiguredKey[];
|
|
24
|
-
readonly lifetime: number;
|
|
25
|
-
readonly refresh: number;
|
|
26
|
-
readonly cache: {
|
|
27
|
-
max: number;
|
|
28
|
-
ttl: number;
|
|
29
|
-
};
|
|
30
|
-
}
|
|
31
|
-
export interface ConfiguredKey extends Pick<Key, 'id'> {
|
|
32
|
-
key: Secret;
|
|
33
|
-
format?: 'jwe' | 'paseto';
|
|
34
|
-
}
|
|
35
|
-
export interface Entity {
|
|
36
|
-
revokedAt?: number;
|
|
37
|
-
}
|
|
38
|
-
export interface Identity extends Record<string, any> {
|
|
39
|
-
id: string;
|
|
40
|
-
roles: string[];
|
|
41
|
-
permissions?: Record<string, string[]>;
|
|
42
|
-
}
|
|
43
|
-
export interface AuthenticateInput {
|
|
44
|
-
authority: string;
|
|
45
|
-
credentials: string;
|
|
46
|
-
}
|
|
47
|
-
export interface AuthenticateOutput {
|
|
48
|
-
identity: Identity;
|
|
49
|
-
refresh: boolean;
|
|
50
|
-
}
|
|
51
|
-
export interface EncryptInput {
|
|
52
|
-
authority: string;
|
|
53
|
-
identity: Identity;
|
|
54
|
-
lifetime?: number;
|
|
55
|
-
scopes?: string[];
|
|
56
|
-
permissions?: Record<string, string[]>;
|
|
57
|
-
key?: Key;
|
|
58
|
-
}
|
|
59
|
-
export interface DecryptOutput {
|
|
60
|
-
iss: string;
|
|
61
|
-
iat: string;
|
|
62
|
-
exp?: string;
|
|
63
|
-
identity: Identity;
|
|
64
|
-
refresh: boolean;
|
|
65
|
-
/** encrypted with a key of its own, see `issue` */
|
|
66
|
-
custom: boolean;
|
|
67
|
-
}
|
|
68
|
-
export interface Claims {
|
|
69
|
-
identity: Identity;
|
|
70
|
-
iss: string;
|
|
71
|
-
iat: string;
|
|
72
|
-
exp?: string;
|
|
73
|
-
}
|
|
74
|
-
export interface JWEClaims {
|
|
75
|
-
identity: Identity;
|
|
76
|
-
iss: string;
|
|
77
|
-
iat: number;
|
|
78
|
-
exp?: number;
|
|
79
|
-
}
|
|
80
|
-
export interface Key {
|
|
81
|
-
id: string;
|
|
82
|
-
key: string;
|
|
83
|
-
label: string;
|
|
84
|
-
}
|
|
85
|
-
export interface CustomKey extends Key {
|
|
86
|
-
identity: string;
|
|
87
|
-
revokedAt?: number;
|
|
88
|
-
}
|
|
@@ -1 +0,0 @@
|
|
|
1
|
-
{"version":3,"file":"types.js","sourceRoot":"","sources":["../../source/lib/types.ts"],"names":[],"mappings":""}
|
|
@@ -1,102 +0,0 @@
|
|
|
1
|
-
import type { Call, Maybe, Observation, Secret, telemetry } from '@toa.io/types'
|
|
2
|
-
|
|
3
|
-
export interface Context {
|
|
4
|
-
local: {
|
|
5
|
-
observe: Observation<Entity>
|
|
6
|
-
encrypt: Call<Maybe<string>, EncryptInput>
|
|
7
|
-
decrypt: Call<Maybe<DecryptOutput>, string>
|
|
8
|
-
}
|
|
9
|
-
remote: {
|
|
10
|
-
identity: {
|
|
11
|
-
keys: {
|
|
12
|
-
observe: Observation<CustomKey>
|
|
13
|
-
create: Call<Key>
|
|
14
|
-
}
|
|
15
|
-
roles: {
|
|
16
|
-
list: Call<string[]>
|
|
17
|
-
}
|
|
18
|
-
}
|
|
19
|
-
}
|
|
20
|
-
configuration: Configuration
|
|
21
|
-
logs: telemetry.Logs
|
|
22
|
-
}
|
|
23
|
-
|
|
24
|
-
export interface Configuration {
|
|
25
|
-
readonly keys: ConfiguredKey[]
|
|
26
|
-
readonly lifetime: number
|
|
27
|
-
readonly refresh: number
|
|
28
|
-
readonly cache: {
|
|
29
|
-
max: number
|
|
30
|
-
ttl: number
|
|
31
|
-
}
|
|
32
|
-
}
|
|
33
|
-
|
|
34
|
-
export interface ConfiguredKey extends Pick<Key, 'id'> {
|
|
35
|
-
key: Secret
|
|
36
|
-
format?: 'jwe' | 'paseto'
|
|
37
|
-
}
|
|
38
|
-
|
|
39
|
-
export interface Entity {
|
|
40
|
-
revokedAt?: number
|
|
41
|
-
}
|
|
42
|
-
|
|
43
|
-
export interface Identity extends Record<string, any> {
|
|
44
|
-
id: string
|
|
45
|
-
roles: string[]
|
|
46
|
-
permissions?: Record<string, string[]>
|
|
47
|
-
}
|
|
48
|
-
|
|
49
|
-
export interface AuthenticateInput {
|
|
50
|
-
authority: string
|
|
51
|
-
credentials: string
|
|
52
|
-
}
|
|
53
|
-
|
|
54
|
-
export interface AuthenticateOutput {
|
|
55
|
-
identity: Identity
|
|
56
|
-
refresh: boolean
|
|
57
|
-
}
|
|
58
|
-
|
|
59
|
-
export interface EncryptInput {
|
|
60
|
-
authority: string
|
|
61
|
-
identity: Identity
|
|
62
|
-
lifetime?: number
|
|
63
|
-
scopes?: string[]
|
|
64
|
-
permissions?: Record<string, string[]>
|
|
65
|
-
key?: Key
|
|
66
|
-
}
|
|
67
|
-
|
|
68
|
-
export interface DecryptOutput {
|
|
69
|
-
iss: string
|
|
70
|
-
iat: string
|
|
71
|
-
exp?: string
|
|
72
|
-
identity: Identity
|
|
73
|
-
refresh: boolean
|
|
74
|
-
|
|
75
|
-
/** encrypted with a key of its own, see `issue` */
|
|
76
|
-
custom: boolean
|
|
77
|
-
}
|
|
78
|
-
|
|
79
|
-
export interface Claims {
|
|
80
|
-
identity: Identity
|
|
81
|
-
iss: string
|
|
82
|
-
iat: string
|
|
83
|
-
exp?: string
|
|
84
|
-
}
|
|
85
|
-
|
|
86
|
-
export interface JWEClaims {
|
|
87
|
-
identity: Identity
|
|
88
|
-
iss: string
|
|
89
|
-
iat: number
|
|
90
|
-
exp?: number
|
|
91
|
-
}
|
|
92
|
-
|
|
93
|
-
export interface Key {
|
|
94
|
-
id: string
|
|
95
|
-
key: string
|
|
96
|
-
label: string
|
|
97
|
-
}
|
|
98
|
-
|
|
99
|
-
export interface CustomKey extends Key {
|
|
100
|
-
identity: string
|
|
101
|
-
revokedAt?: number
|
|
102
|
-
}
|