@epilot/cli 0.1.154 → 0.1.155
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/README.md +1 -1
- package/definitions/access-token.json +208 -3
- package/dist/bin/epilot.js +6 -6
- package/dist/{chunk-V3XTUOKN.js → chunk-PZQM3BWY.js} +4 -2
- package/dist/{completion-ZKB2LRUW.js → completion-6CAE47TY.js} +1 -1
- package/dist/{upgrade-66YVWUZD.js → upgrade-DF6ERFIY.js} +1 -1
- package/package.json +1 -1
package/README.md
CHANGED
|
@@ -86,6 +86,21 @@
|
|
|
86
86
|
"739224:e5c1f9b1-e41d-421d-83c4-c5626e464430"
|
|
87
87
|
]
|
|
88
88
|
}
|
|
89
|
+
},
|
|
90
|
+
"contact_identification": {
|
|
91
|
+
"value": {
|
|
92
|
+
"name": "Contact Identification Token",
|
|
93
|
+
"token_type": "contact_identification",
|
|
94
|
+
"portal_id": "portal_abc123",
|
|
95
|
+
"contact_id": "5da0a718-c822-403d-9f5d-20d4584e0528",
|
|
96
|
+
"surface_id": "website-journeys",
|
|
97
|
+
"origin": "END_CUSTOMER_PORTAL",
|
|
98
|
+
"allowed_operations": [
|
|
99
|
+
"getContact",
|
|
100
|
+
"getContracts"
|
|
101
|
+
],
|
|
102
|
+
"expires_in": 300
|
|
103
|
+
}
|
|
89
104
|
}
|
|
90
105
|
}
|
|
91
106
|
}
|
|
@@ -495,6 +510,98 @@
|
|
|
495
510
|
}
|
|
496
511
|
}
|
|
497
512
|
}
|
|
513
|
+
},
|
|
514
|
+
"/v1/access-tokens/contact-identification/.well-known/jwks.json": {
|
|
515
|
+
"get": {
|
|
516
|
+
"operationId": "getContactIdentificationTokenJwks",
|
|
517
|
+
"summary": "getContactIdentificationTokenJwks",
|
|
518
|
+
"description": "Get jwks public key set to verify contact identification tokens generated by this API",
|
|
519
|
+
"tags": [
|
|
520
|
+
"Public"
|
|
521
|
+
],
|
|
522
|
+
"security": [],
|
|
523
|
+
"responses": {
|
|
524
|
+
"200": {
|
|
525
|
+
"description": "Set of jwks",
|
|
526
|
+
"content": {
|
|
527
|
+
"application/json": {
|
|
528
|
+
"schema": {
|
|
529
|
+
"type": "object",
|
|
530
|
+
"properties": {
|
|
531
|
+
"keys": {
|
|
532
|
+
"type": "array",
|
|
533
|
+
"items": {
|
|
534
|
+
"type": "object",
|
|
535
|
+
"properties": {
|
|
536
|
+
"alg": {
|
|
537
|
+
"type": "string",
|
|
538
|
+
"example": "RS256"
|
|
539
|
+
},
|
|
540
|
+
"e": {
|
|
541
|
+
"type": "string",
|
|
542
|
+
"example": "AQAB"
|
|
543
|
+
},
|
|
544
|
+
"kid": {
|
|
545
|
+
"type": "string",
|
|
546
|
+
"example": "tXWU5mPMbRPczpbQwi6vbhLF4GgF3wlMDSyqo7pfeiw="
|
|
547
|
+
},
|
|
548
|
+
"kty": {
|
|
549
|
+
"type": "string",
|
|
550
|
+
"example": "RSA"
|
|
551
|
+
},
|
|
552
|
+
"n": {
|
|
553
|
+
"type": "string",
|
|
554
|
+
"example": "h_QDoCjZ8W_trtYXaP7_S22wf5r5Wd9XBLED78oT44bJjQXn8ddcFV8Hik65_4IYXVX_hTTU4zpxe3H8vx2j7-Zz3O59mYMp5S0MzODNEdf5Y_2o19eis0brmAJniixsNlQ9LlYkdrVamrgaxHu3ZpP_99zkfFybYeuYoQNzb3PyrT8xVnz_USs_nlFMHpGUxvvz7gfKPqxcLvgLJr4cwI9yzaSY9CD4qW181QVcnL_WzpQ8xx6AuhhHZQ1l_3GG4InTk8ahE7U2ZHVu8RrX6d01pMgc3piEcet9RgFLnhbTg3YIiKGoAbN42wJn_x3lgIAC42T9mbmTsHyUdS6nUQ"
|
|
555
|
+
},
|
|
556
|
+
"use": {
|
|
557
|
+
"type": "string",
|
|
558
|
+
"example": "sig"
|
|
559
|
+
}
|
|
560
|
+
}
|
|
561
|
+
}
|
|
562
|
+
}
|
|
563
|
+
}
|
|
564
|
+
}
|
|
565
|
+
}
|
|
566
|
+
}
|
|
567
|
+
}
|
|
568
|
+
}
|
|
569
|
+
}
|
|
570
|
+
},
|
|
571
|
+
"/v1/access-tokens/contact-identification/.well-known/openid-configuration": {
|
|
572
|
+
"get": {
|
|
573
|
+
"operationId": "getContactIdentificationTokenOIDC",
|
|
574
|
+
"summary": "getContactIdentificationTokenOIDC",
|
|
575
|
+
"description": "OpenID Connect configuration for Access Token API as a contact identification identity provider\n\nNote: This API is not a fully compliant OAuth2.0 / OIDC identity provider, but this endpoint is useful to\nautomate the process of verifying JWT tokens.\n",
|
|
576
|
+
"tags": [
|
|
577
|
+
"Public"
|
|
578
|
+
],
|
|
579
|
+
"security": [],
|
|
580
|
+
"responses": {
|
|
581
|
+
"200": {
|
|
582
|
+
"description": "OpenID Configuration",
|
|
583
|
+
"content": {
|
|
584
|
+
"application/json": {
|
|
585
|
+
"schema": {
|
|
586
|
+
"type": "object",
|
|
587
|
+
"properties": {
|
|
588
|
+
"issuer": {
|
|
589
|
+
"type": "string",
|
|
590
|
+
"format": "uri",
|
|
591
|
+
"example": "https://access-token.sls.epilot.io/v1/access-tokens/contact-identification"
|
|
592
|
+
},
|
|
593
|
+
"jwks_uri": {
|
|
594
|
+
"type": "string",
|
|
595
|
+
"format": "uri",
|
|
596
|
+
"example": "https://access-token.sls.epilot.io/v1/access-tokens/contact-identification/.well-known/jwks.json"
|
|
597
|
+
}
|
|
598
|
+
}
|
|
599
|
+
}
|
|
600
|
+
}
|
|
601
|
+
}
|
|
602
|
+
}
|
|
603
|
+
}
|
|
604
|
+
}
|
|
498
605
|
}
|
|
499
606
|
},
|
|
500
607
|
"components": {
|
|
@@ -535,7 +642,8 @@
|
|
|
535
642
|
"portal",
|
|
536
643
|
"assume",
|
|
537
644
|
"app",
|
|
538
|
-
"portal_preview"
|
|
645
|
+
"portal_preview",
|
|
646
|
+
"contact_identification"
|
|
539
647
|
],
|
|
540
648
|
"description": "Access token type",
|
|
541
649
|
"example": "api"
|
|
@@ -552,6 +660,30 @@
|
|
|
552
660
|
"type": "string",
|
|
553
661
|
"description": "Portal User ID for access token type \"portal_preview\""
|
|
554
662
|
},
|
|
663
|
+
"ContactId": {
|
|
664
|
+
"type": "string",
|
|
665
|
+
"description": "Contact entity ID for access token type \"contact_identification\"",
|
|
666
|
+
"example": "5da0a718-c822-403d-9f5d-20d4584e0528"
|
|
667
|
+
},
|
|
668
|
+
"PortalOrigin": {
|
|
669
|
+
"type": "string",
|
|
670
|
+
"enum": [
|
|
671
|
+
"END_CUSTOMER_PORTAL",
|
|
672
|
+
"INSTALLER_PORTAL"
|
|
673
|
+
],
|
|
674
|
+
"description": "Portal origin the token assumes, so the bearer is permission-masked the same way the corresponding portal role is."
|
|
675
|
+
},
|
|
676
|
+
"AllowedOperations": {
|
|
677
|
+
"type": "array",
|
|
678
|
+
"description": "openapi operationIds the token may call. Enforced by the API that consumes the token, which must additionally deny any operation not on this list. Baked into the token at issue time so widening the consumer's own allowlist later cannot retroactively widen a token that is already in circulation.",
|
|
679
|
+
"items": {
|
|
680
|
+
"type": "string"
|
|
681
|
+
},
|
|
682
|
+
"example": [
|
|
683
|
+
"getContact",
|
|
684
|
+
"getContracts"
|
|
685
|
+
]
|
|
686
|
+
},
|
|
555
687
|
"TokenParameters": {
|
|
556
688
|
"anyOf": [
|
|
557
689
|
{
|
|
@@ -571,6 +703,9 @@
|
|
|
571
703
|
},
|
|
572
704
|
{
|
|
573
705
|
"$ref": "#/components/schemas/PortalPreviewTokenParameters"
|
|
706
|
+
},
|
|
707
|
+
{
|
|
708
|
+
"$ref": "#/components/schemas/ContactIdentificationTokenParameters"
|
|
574
709
|
}
|
|
575
710
|
]
|
|
576
711
|
},
|
|
@@ -579,10 +714,10 @@
|
|
|
579
714
|
{
|
|
580
715
|
"type": "integer",
|
|
581
716
|
"format": "int32",
|
|
582
|
-
"description": "Expiration time in seconds",
|
|
717
|
+
"description": "Expiration time in seconds. api tokens may live up to 365 days (31536000); all other token types are capped at 7 days (604800) server-side.",
|
|
583
718
|
"example": 3600,
|
|
584
719
|
"minimum": 30,
|
|
585
|
-
"maximum":
|
|
720
|
+
"maximum": 31536000
|
|
586
721
|
},
|
|
587
722
|
{
|
|
588
723
|
"type": "string",
|
|
@@ -766,6 +901,61 @@
|
|
|
766
901
|
"portal_user_id"
|
|
767
902
|
]
|
|
768
903
|
},
|
|
904
|
+
"ContactIdentificationTokenParameters": {
|
|
905
|
+
"type": "object",
|
|
906
|
+
"additionalProperties": false,
|
|
907
|
+
"description": "A token that acts as one contact, issued after that contact was identified by a portal's registration identifiers rather than by logging in. Distinct from portal_preview, which impersonates an existing portal user for a 360 operator: this kind belongs to no user, is minted for an unauthenticated caller, and is therefore always short-lived and restricted to an explicit operation allowlist. Never stored, so it cannot be listed or revoked - keep expires_in short.",
|
|
908
|
+
"properties": {
|
|
909
|
+
"name": {
|
|
910
|
+
"$ref": "#/components/schemas/AccessTokenName"
|
|
911
|
+
},
|
|
912
|
+
"token_type": {
|
|
913
|
+
"type": "string",
|
|
914
|
+
"enum": [
|
|
915
|
+
"contact_identification"
|
|
916
|
+
]
|
|
917
|
+
},
|
|
918
|
+
"portal_id": {
|
|
919
|
+
"$ref": "#/components/schemas/PortalId"
|
|
920
|
+
},
|
|
921
|
+
"contact_id": {
|
|
922
|
+
"$ref": "#/components/schemas/ContactId"
|
|
923
|
+
},
|
|
924
|
+
"surface_id": {
|
|
925
|
+
"type": "string",
|
|
926
|
+
"minLength": 1,
|
|
927
|
+
"maxLength": 64,
|
|
928
|
+
"description": "Portal surface the token is issued for (see `surfaces` on the portal config in customer-portal-api). Carried as the `custom:surface_id` claim; the consuming API resolves the surface's data access from the portal config on every request.",
|
|
929
|
+
"example": "website-journeys"
|
|
930
|
+
},
|
|
931
|
+
"origin": {
|
|
932
|
+
"$ref": "#/components/schemas/PortalOrigin"
|
|
933
|
+
},
|
|
934
|
+
"allowed_operations": {
|
|
935
|
+
"$ref": "#/components/schemas/AllowedOperations"
|
|
936
|
+
},
|
|
937
|
+
"expires_in": {
|
|
938
|
+
"type": "integer",
|
|
939
|
+
"format": "int32",
|
|
940
|
+
"minimum": 60,
|
|
941
|
+
"maximum": 900,
|
|
942
|
+
"description": "Lifetime in seconds. Integer only for this token type (no \"5m\" strings), and capped server-side by CONTACT_IDENTIFICATION_TOKEN_MAX_EXPIRATION_SECONDS - the value originates from portal configuration, so it is not trusted as-is.",
|
|
943
|
+
"example": 300
|
|
944
|
+
},
|
|
945
|
+
"email": {
|
|
946
|
+
"type": "string",
|
|
947
|
+
"description": "Optional. Carried as the `email` claim when the consumer needs it (e.g. to attribute an activity). Omit to keep the contact's email out of the token."
|
|
948
|
+
}
|
|
949
|
+
},
|
|
950
|
+
"required": [
|
|
951
|
+
"name",
|
|
952
|
+
"portal_id",
|
|
953
|
+
"contact_id",
|
|
954
|
+
"surface_id",
|
|
955
|
+
"allowed_operations",
|
|
956
|
+
"expires_in"
|
|
957
|
+
]
|
|
958
|
+
},
|
|
769
959
|
"AccessTokenItem": {
|
|
770
960
|
"type": "object",
|
|
771
961
|
"properties": {
|
|
@@ -791,6 +981,15 @@
|
|
|
791
981
|
"portal_user_id": {
|
|
792
982
|
"$ref": "#/components/schemas/PortalUserId"
|
|
793
983
|
},
|
|
984
|
+
"contact_id": {
|
|
985
|
+
"$ref": "#/components/schemas/ContactId"
|
|
986
|
+
},
|
|
987
|
+
"origin": {
|
|
988
|
+
"$ref": "#/components/schemas/PortalOrigin"
|
|
989
|
+
},
|
|
990
|
+
"allowed_operations": {
|
|
991
|
+
"$ref": "#/components/schemas/AllowedOperations"
|
|
992
|
+
},
|
|
794
993
|
"assignments": {
|
|
795
994
|
"$ref": "#/components/schemas/Assignments"
|
|
796
995
|
},
|
|
@@ -805,6 +1004,12 @@
|
|
|
805
1004
|
"format": "date",
|
|
806
1005
|
"description": "Last date the token was used (YYYY-MM-DD format, 1 day accuracy)",
|
|
807
1006
|
"example": "2026-02-24"
|
|
1007
|
+
},
|
|
1008
|
+
"expires_at": {
|
|
1009
|
+
"type": "string",
|
|
1010
|
+
"format": "date-time",
|
|
1011
|
+
"description": "Timestamp when the token expires and stops being accepted (only set for tokens created with expires_in)",
|
|
1012
|
+
"example": "2026-03-01T12:00:00.000Z"
|
|
808
1013
|
}
|
|
809
1014
|
},
|
|
810
1015
|
"required": [
|
package/dist/bin/epilot.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
2
|
import {
|
|
3
3
|
API_LIST
|
|
4
|
-
} from "../chunk-
|
|
4
|
+
} from "../chunk-PZQM3BWY.js";
|
|
5
5
|
|
|
6
6
|
// bin/epilot.ts
|
|
7
7
|
import { runMain } from "citty";
|
|
@@ -11,7 +11,7 @@ import { defineCommand } from "citty";
|
|
|
11
11
|
var main = defineCommand({
|
|
12
12
|
meta: {
|
|
13
13
|
name: "epilot",
|
|
14
|
-
version: "0.1.
|
|
14
|
+
version: "0.1.155",
|
|
15
15
|
description: "CLI for epilot APIs"
|
|
16
16
|
},
|
|
17
17
|
args: {
|
|
@@ -30,8 +30,8 @@ var main = defineCommand({
|
|
|
30
30
|
auth: () => import("../auth-WMXFMPWE.js").then((m) => m.default),
|
|
31
31
|
profile: () => import("../profile-OZJL5ZPT.js").then((m) => m.default),
|
|
32
32
|
config: () => import("../config-DGZIMLZK.js").then((m) => m.default),
|
|
33
|
-
completion: () => import("../completion-
|
|
34
|
-
upgrade: () => import("../upgrade-
|
|
33
|
+
completion: () => import("../completion-6CAE47TY.js").then((m) => m.default),
|
|
34
|
+
upgrade: () => import("../upgrade-DF6ERFIY.js").then((m) => m.default),
|
|
35
35
|
"access-token": () => import("../access-token-WWE6BDJH.js").then((m) => m.default),
|
|
36
36
|
address: () => import("../address-EH3C4CVB.js").then((m) => m.default),
|
|
37
37
|
"address-suggestions": () => import("../address-suggestions-RRSLOBFW.js").then((m) => m.default),
|
|
@@ -134,13 +134,13 @@ process.stderr.on("error", (err) => {
|
|
|
134
134
|
if (err.code === "EPIPE") process.exit(0);
|
|
135
135
|
throw err;
|
|
136
136
|
});
|
|
137
|
-
var VERSION = true ? "0.1.
|
|
137
|
+
var VERSION = true ? "0.1.155" : (await null).default.version;
|
|
138
138
|
var reorderedArgv = hoistFlagsAfterSubcommand(process.argv.slice(2));
|
|
139
139
|
process.argv = [process.argv[0], process.argv[1], ...reorderedArgv];
|
|
140
140
|
var args = process.argv.slice(2);
|
|
141
141
|
var completionsIdx = args.indexOf("--_completions");
|
|
142
142
|
if (completionsIdx >= 0) {
|
|
143
|
-
const { handleCompletions } = await import("../completion-
|
|
143
|
+
const { handleCompletions } = await import("../completion-6CAE47TY.js");
|
|
144
144
|
handleCompletions(args[completionsIdx + 1], args[completionsIdx + 2]);
|
|
145
145
|
process.exit(0);
|
|
146
146
|
}
|
|
@@ -7,7 +7,7 @@ var API_LIST = [
|
|
|
7
7
|
kebabName: "access-token",
|
|
8
8
|
title: "Access Token API",
|
|
9
9
|
serverUrl: "https://access-token.sls.epilot.io",
|
|
10
|
-
operationCount:
|
|
10
|
+
operationCount: 11,
|
|
11
11
|
operationIds: [
|
|
12
12
|
"listAccessTokens",
|
|
13
13
|
"createAccessToken",
|
|
@@ -17,7 +17,9 @@ var API_LIST = [
|
|
|
17
17
|
"getPublicTokenJwks",
|
|
18
18
|
"getPortalPreviewTokenJwks",
|
|
19
19
|
"getPublicTokenOIDC",
|
|
20
|
-
"getPortalPreviewTokenOIDC"
|
|
20
|
+
"getPortalPreviewTokenOIDC",
|
|
21
|
+
"getContactIdentificationTokenJwks",
|
|
22
|
+
"getContactIdentificationTokenOIDC"
|
|
21
23
|
]
|
|
22
24
|
},
|
|
23
25
|
{
|
|
@@ -72,7 +72,7 @@ ${GREEN}${BOLD}Upgraded to @epilot/cli@${latest}${RESET}
|
|
|
72
72
|
}
|
|
73
73
|
});
|
|
74
74
|
var getCurrentVersion = () => {
|
|
75
|
-
if (true) return "0.1.
|
|
75
|
+
if (true) return "0.1.155";
|
|
76
76
|
try {
|
|
77
77
|
const output = execSync("npm ls -g @epilot/cli --depth=0 --json 2>/dev/null", {
|
|
78
78
|
encoding: "utf-8",
|