@epilot/journey-client 0.8.0 → 0.9.0-alpha.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.
Files changed (2) hide show
  1. package/dist/openapi.d.ts +53 -4
  2. package/package.json +12 -11
package/dist/openapi.d.ts CHANGED
@@ -25,6 +25,39 @@ declare namespace Components {
25
25
  */
26
26
  label?: string;
27
27
  }
28
+ /**
29
+ * One link a customer clicks. `label` and `description` are each either a
30
+ * plain string or one string per language, deciding that independently.
31
+ * Mirrors environments-api's `LinkFields`.
32
+ *
33
+ */
34
+ export interface EnvironmentLink {
35
+ url: string;
36
+ label: string | {
37
+ [name: string]: string;
38
+ };
39
+ description?: string | {
40
+ [name: string]: string;
41
+ };
42
+ }
43
+ /**
44
+ * A list of links, served under this service's own `List<Link>` type
45
+ * token. environments-api types the variable `List` and declares the
46
+ * element type inside the value; journey-api composes the two so a
47
+ * consumer needs only one discriminant.
48
+ *
49
+ */
50
+ export interface EnvironmentLinkList {
51
+ itemType: "Link";
52
+ fallbackLanguage?: string;
53
+ items: /**
54
+ * One link a customer clicks. `label` and `description` are each either a
55
+ * plain string or one string per language, deciding that independently.
56
+ * Mirrors environments-api's `LinkFields`.
57
+ *
58
+ */
59
+ EnvironmentLink[];
60
+ }
28
61
  export interface EnvironmentMap {
29
62
  fallbackLanguage?: string;
30
63
  options: EnvironmentMapEntry[];
@@ -993,8 +1026,15 @@ declare namespace Components {
993
1026
  export interface JourneyEnvironmentResponse {
994
1027
  items: {
995
1028
  datasourceId: string;
996
- type: "Text" | "Number" | "Boolean" | "Map";
997
- value: string | number | boolean | EnvironmentMap;
1029
+ type: "Text" | "Number" | "Boolean" | "Map" | "List<Link>";
1030
+ value: string | number | boolean | EnvironmentMap | /**
1031
+ * A list of links, served under this service's own `List<Link>` type
1032
+ * token. environments-api types the variable `List` and declares the
1033
+ * element type inside the value; journey-api composes the two so a
1034
+ * consumer needs only one discriminant.
1035
+ *
1036
+ */
1037
+ EnvironmentLinkList;
998
1038
  }[];
999
1039
  errors: {
1000
1040
  datasourceId: string;
@@ -1004,8 +1044,15 @@ declare namespace Components {
1004
1044
  export interface JourneyEnvironmentVariablesResponse {
1005
1045
  items: {
1006
1046
  key: string;
1007
- type: "Map";
1008
- value: EnvironmentMap;
1047
+ type: "Map" | "List<Link>";
1048
+ value: EnvironmentMap | /**
1049
+ * A list of links, served under this service's own `List<Link>` type
1050
+ * token. environments-api types the variable `List` and declares the
1051
+ * element type inside the value; journey-api composes the two so a
1052
+ * consumer needs only one discriminant.
1053
+ *
1054
+ */
1055
+ EnvironmentLinkList;
1009
1056
  description?: string;
1010
1057
  }[];
1011
1058
  }
@@ -3780,6 +3827,8 @@ export type Client = OpenAPIClient<OperationMethods, PathsDictionary>
3780
3827
 
3781
3828
 
3782
3829
  export type ButtonOption = Components.Schemas.ButtonOption;
3830
+ export type EnvironmentLink = Components.Schemas.EnvironmentLink;
3831
+ export type EnvironmentLinkList = Components.Schemas.EnvironmentLinkList;
3783
3832
  export type EnvironmentMap = Components.Schemas.EnvironmentMap;
3784
3833
  export type EnvironmentMapEntry = Components.Schemas.EnvironmentMapEntry;
3785
3834
  export type GenerateDocumentRequest = Components.Schemas.GenerateDocumentRequest;
package/package.json CHANGED
@@ -1,9 +1,19 @@
1
1
  {
2
2
  "name": "@epilot/journey-client",
3
- "version": "0.8.0",
3
+ "version": "0.9.0-alpha.0",
4
4
  "description": "API Client for epilot Journey API",
5
5
  "main": "dist/index.js",
6
6
  "types": "dist/index.d.ts",
7
+ "scripts": {
8
+ "test": "vitest",
9
+ "typescript": "tsc",
10
+ "bundle-definition": "webpack",
11
+ "openapi": "node ../../scripts/update-openapi.js https://docs.api.epilot.io/journey-config.yaml",
12
+ "typegen": "openapi typegen src/openapi.json --client > src/openapi.d.ts",
13
+ "build": "npm run openapi && npm run typegen && npm run typescript && npm run bundle-definition",
14
+ "eslint": "../node_modules/.bin/eslint -c ../.eslintrc.yml",
15
+ "prepublishOnly": "npm run build"
16
+ },
7
17
  "files": [
8
18
  "*.js",
9
19
  "*.d.ts",
@@ -47,14 +57,5 @@
47
57
  "vitest": "^1.6.0",
48
58
  "webpack": "^5.91.0",
49
59
  "webpack-cli": "^5.1.4"
50
- },
51
- "scripts": {
52
- "test": "vitest",
53
- "typescript": "tsc",
54
- "bundle-definition": "webpack",
55
- "openapi": "node ../../scripts/update-openapi.js https://docs.api.epilot.io/journey-config.yaml",
56
- "typegen": "openapi typegen src/openapi.json --client > src/openapi.d.ts",
57
- "build": "npm run openapi && npm run typegen && npm run typescript && npm run bundle-definition",
58
- "eslint": "../node_modules/.bin/eslint -c ../.eslintrc.yml"
59
60
  }
60
- }
61
+ }