@droz-js/sdk 0.5.20 → 0.5.21

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/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "@droz-js/sdk",
3
3
  "description": "Droz SDK",
4
- "version": "0.5.20",
4
+ "version": "0.5.21",
5
5
  "private": false,
6
6
  "exports": {
7
7
  ".": "./src/index.js",
@@ -128,6 +128,10 @@ export type I18nText = {
128
128
  lang: Scalars['Locale']['output'];
129
129
  value: Scalars['String']['output'];
130
130
  };
131
+ export type I18nTextInput = {
132
+ lang: Scalars['Locale']['input'];
133
+ value: Scalars['String']['input'];
134
+ };
131
135
  export type Mutation = {
132
136
  applySolution?: Maybe<Scalars['Boolean']['output']>;
133
137
  createCasasBahiaInstance?: Maybe<CasasBahiaInstance>;
@@ -121,6 +121,10 @@ export type I18nText = {
121
121
  lang: Scalars['Locale']['output'];
122
122
  value: Scalars['String']['output'];
123
123
  };
124
+ export type I18nTextInput = {
125
+ lang: Scalars['Locale']['input'];
126
+ value: Scalars['String']['input'];
127
+ };
124
128
  export type Mutation = {
125
129
  createChatWidget?: Maybe<ChatWidget>;
126
130
  removeChatWidget?: Maybe<ChatWidget>;
@@ -143,6 +143,10 @@ export type I18nText = {
143
143
  lang: Scalars['Locale']['output'];
144
144
  value: Scalars['String']['output'];
145
145
  };
146
+ export type I18nTextInput = {
147
+ lang: Scalars['Locale']['input'];
148
+ value: Scalars['String']['input'];
149
+ };
146
150
  export type Mutation = {
147
151
  createDrozBotInstance: DrozBotInstance;
148
152
  createDrozBotTicket: DrozBotTicket;
@@ -170,6 +170,10 @@ export type I18nText = {
170
170
  lang: Scalars['Locale']['output'];
171
171
  value: Scalars['String']['output'];
172
172
  };
173
+ export type I18nTextInput = {
174
+ lang: Scalars['Locale']['input'];
175
+ value: Scalars['String']['input'];
176
+ };
173
177
  export type MarkTicketMessagesAsReadInput = {
174
178
  channelId: Scalars['ID']['input'];
175
179
  ticketId: Scalars['ID']['input'];
@@ -188,6 +188,10 @@ export type I18nText = {
188
188
  lang: Scalars['Locale']['output'];
189
189
  value: Scalars['String']['output'];
190
190
  };
191
+ export type I18nTextInput = {
192
+ lang: Scalars['Locale']['input'];
193
+ value: Scalars['String']['input'];
194
+ };
191
195
  export type Mutation = {
192
196
  batchDeploy: Array<Deployment>;
193
197
  createTenant: Tenant;
@@ -144,6 +144,10 @@ export type I18nText = {
144
144
  lang: Scalars['Locale']['output'];
145
145
  value: Scalars['String']['output'];
146
146
  };
147
+ export type I18nTextInput = {
148
+ lang: Scalars['Locale']['input'];
149
+ value: Scalars['String']['input'];
150
+ };
147
151
  export type Mutation = {
148
152
  createDrozNexoConnection: DrozNexoConnection;
149
153
  removeDrozNexoConnection: DrozNexoConnection;
@@ -301,6 +301,10 @@ export type I18nText = {
301
301
  lang: Scalars['Locale']['output'];
302
302
  value: Scalars['String']['output'];
303
303
  };
304
+ export type I18nTextInput = {
305
+ lang: Scalars['Locale']['input'];
306
+ value: Scalars['String']['input'];
307
+ };
304
308
  export type ICredentials = {
305
309
  createdAt: Scalars['DateTime']['output'];
306
310
  description: Scalars['String']['output'];
@@ -111,6 +111,10 @@ export type I18nText = {
111
111
  lang: Scalars['Locale']['output'];
112
112
  value: Scalars['String']['output'];
113
113
  };
114
+ export type I18nTextInput = {
115
+ lang: Scalars['Locale']['input'];
116
+ value: Scalars['String']['input'];
117
+ };
114
118
  export type Mutation = {
115
119
  createReclameAquiInstance?: Maybe<ReclameAquiInstance>;
116
120
  forceReSyncReclameAquiTicket?: Maybe<Scalars['Boolean']['output']>;
@@ -0,0 +1,230 @@
1
+ export type Maybe<T> = T;
2
+ export type InputMaybe<T> = T;
3
+ export type Exact<T extends {
4
+ [key: string]: unknown;
5
+ }> = {
6
+ [K in keyof T]: T[K];
7
+ };
8
+ export type MakeOptional<T, K extends keyof T> = Omit<T, K> & {
9
+ [SubKey in K]?: Maybe<T[SubKey]>;
10
+ };
11
+ export type MakeMaybe<T, K extends keyof T> = Omit<T, K> & {
12
+ [SubKey in K]: Maybe<T[SubKey]>;
13
+ };
14
+ export type MakeEmpty<T extends {
15
+ [key: string]: unknown;
16
+ }, K extends keyof T> = {
17
+ [_ in K]?: never;
18
+ };
19
+ export type Incremental<T> = T | {
20
+ [P in keyof T]?: P extends ' $fragmentName' | '__typename' ? T[P] : never;
21
+ };
22
+ /** All built-in and custom scalars, mapped to their actual values */
23
+ export type Scalars = {
24
+ ID: {
25
+ input: string;
26
+ output: string;
27
+ };
28
+ String: {
29
+ input: string;
30
+ output: string;
31
+ };
32
+ Boolean: {
33
+ input: boolean;
34
+ output: boolean;
35
+ };
36
+ Int: {
37
+ input: number;
38
+ output: number;
39
+ };
40
+ Float: {
41
+ input: number;
42
+ output: number;
43
+ };
44
+ Base64: {
45
+ input: object;
46
+ output: string;
47
+ };
48
+ DRN: {
49
+ input: string;
50
+ output: string;
51
+ };
52
+ Date: {
53
+ input: Date;
54
+ output: Date;
55
+ };
56
+ DateTime: {
57
+ input: Date;
58
+ output: Date;
59
+ };
60
+ EmailAddress: {
61
+ input: string;
62
+ output: string;
63
+ };
64
+ JSON: {
65
+ input: any;
66
+ output: any;
67
+ };
68
+ JSONObject: {
69
+ input: any;
70
+ output: any;
71
+ };
72
+ Locale: {
73
+ input: any;
74
+ output: any;
75
+ };
76
+ PhoneNumber: {
77
+ input: string;
78
+ output: string;
79
+ };
80
+ Set: {
81
+ input: any;
82
+ output: any[];
83
+ };
84
+ URL: {
85
+ input: string;
86
+ output: string;
87
+ };
88
+ Void: {
89
+ input: void;
90
+ output: void;
91
+ };
92
+ };
93
+ export declare enum AppInstanceStatus {
94
+ Active = "Active",
95
+ Failing = "Failing",
96
+ Inactive = "Inactive"
97
+ }
98
+ export type CreateEchoAppInput = {
99
+ messages: Array<I18nTextInput>;
100
+ name: Scalars['String']['input'];
101
+ };
102
+ export type EchoInstance = {
103
+ createdAt: Scalars['DateTime']['output'];
104
+ id: Scalars['ID']['output'];
105
+ messages: Array<I18nText>;
106
+ name: Scalars['String']['output'];
107
+ updatedAt: Scalars['DateTime']['output'];
108
+ };
109
+ export type I18nText = {
110
+ lang: Scalars['Locale']['output'];
111
+ value: Scalars['String']['output'];
112
+ };
113
+ export type I18nTextInput = {
114
+ lang: Scalars['Locale']['input'];
115
+ value: Scalars['String']['input'];
116
+ };
117
+ export type Mutation = {
118
+ createEchoInstance?: Maybe<EchoInstance>;
119
+ removeEchoInstance?: Maybe<EchoInstance>;
120
+ updateEchoInstance?: Maybe<EchoInstance>;
121
+ version?: Maybe<Scalars['String']['output']>;
122
+ };
123
+ export type MutationCreateEchoInstanceArgs = {
124
+ input: CreateEchoAppInput;
125
+ };
126
+ export type MutationRemoveEchoInstanceArgs = {
127
+ id: Scalars['ID']['input'];
128
+ };
129
+ export type MutationUpdateEchoInstanceArgs = {
130
+ input: UpdateEchoAppInput;
131
+ };
132
+ export type NumberFilterInput = {
133
+ btw?: InputMaybe<Array<Scalars['Float']['input']>>;
134
+ eq?: InputMaybe<Scalars['Float']['input']>;
135
+ gt?: InputMaybe<Scalars['Float']['input']>;
136
+ gte?: InputMaybe<Scalars['Float']['input']>;
137
+ lt?: InputMaybe<Scalars['Float']['input']>;
138
+ lte?: InputMaybe<Scalars['Float']['input']>;
139
+ ne?: InputMaybe<Scalars['Float']['input']>;
140
+ };
141
+ export type PageInfo = {
142
+ hasNext: Scalars['Boolean']['output'];
143
+ next?: Maybe<Scalars['Base64']['output']>;
144
+ };
145
+ export type Query = {
146
+ app?: Maybe<Scalars['DRN']['output']>;
147
+ getEchoInstance?: Maybe<EchoInstance>;
148
+ getHttpEndpoint?: Maybe<Scalars['String']['output']>;
149
+ version?: Maybe<Scalars['String']['output']>;
150
+ };
151
+ export type QueryGetEchoInstanceArgs = {
152
+ id: Scalars['ID']['input'];
153
+ };
154
+ export type SearchResultsFacet = {
155
+ name: Scalars['String']['output'];
156
+ stats?: Maybe<SearchResultsFacetStats>;
157
+ values?: Maybe<Array<SearchResultsFacetValue>>;
158
+ };
159
+ export type SearchResultsFacetStats = {
160
+ max?: Maybe<Scalars['Float']['output']>;
161
+ min?: Maybe<Scalars['Float']['output']>;
162
+ };
163
+ export type SearchResultsFacetValue = {
164
+ count: Scalars['Float']['output'];
165
+ value: Scalars['String']['output'];
166
+ };
167
+ export type SearchResultsStats = {
168
+ found: Scalars['Float']['output'];
169
+ page: Scalars['Float']['output'];
170
+ perPage: Scalars['Float']['output'];
171
+ searchTime: Scalars['Float']['output'];
172
+ totalPages: Scalars['Float']['output'];
173
+ };
174
+ export type StringFilterInput = {
175
+ eq?: InputMaybe<Scalars['String']['input']>;
176
+ in?: InputMaybe<Array<Scalars['String']['input']>>;
177
+ ne?: InputMaybe<Scalars['String']['input']>;
178
+ };
179
+ export declare enum Typenames {
180
+ Any = "Any",
181
+ Echo = "Echo",
182
+ GraphqlConnections = "GraphqlConnections",
183
+ GraphqlSubscriptions = "GraphqlSubscriptions"
184
+ }
185
+ export type UpdateEchoAppInput = {
186
+ id: Scalars['ID']['input'];
187
+ messages?: InputMaybe<Array<I18nTextInput>>;
188
+ name?: InputMaybe<Scalars['String']['input']>;
189
+ };
190
+ export type EchoInstanceFragment = (Pick<EchoInstance, 'id' | 'name' | 'createdAt' | 'updatedAt'> & {
191
+ messages: Array<Pick<I18nText, 'lang' | 'value'>>;
192
+ });
193
+ export type GetEchoInstanceQueryVariables = Exact<{
194
+ id: Scalars['ID']['input'];
195
+ }>;
196
+ export type GetEchoInstanceQuery = {
197
+ getEchoInstance?: Maybe<EchoInstanceFragment>;
198
+ };
199
+ export type CreateEchoInstanceMutationVariables = Exact<{
200
+ input: CreateEchoAppInput;
201
+ }>;
202
+ export type CreateEchoInstanceMutation = {
203
+ createEchoInstance?: Maybe<EchoInstanceFragment>;
204
+ };
205
+ export type UpdateEchoInstanceMutationVariables = Exact<{
206
+ input: UpdateEchoAppInput;
207
+ }>;
208
+ export type UpdateEchoInstanceMutation = {
209
+ updateEchoInstance?: Maybe<EchoInstanceFragment>;
210
+ };
211
+ export type RemoveEchoInstanceMutationVariables = Exact<{
212
+ id: Scalars['ID']['input'];
213
+ }>;
214
+ export type RemoveEchoInstanceMutation = {
215
+ removeEchoInstance?: Maybe<EchoInstanceFragment>;
216
+ };
217
+ export declare const EchoInstanceFragmentDoc = "\n fragment echoInstance on EchoInstance {\n id\n name\n messages {\n lang\n value\n }\n createdAt\n updatedAt\n}\n ";
218
+ export declare const GetEchoInstanceDocument = "\n query getEchoInstance($id: ID!) {\n getEchoInstance(id: $id) {\n ...echoInstance\n }\n}\n \n fragment echoInstance on EchoInstance {\n id\n name\n messages {\n lang\n value\n }\n createdAt\n updatedAt\n}\n ";
219
+ export declare const CreateEchoInstanceDocument = "\n mutation createEchoInstance($input: CreateEchoAppInput!) {\n createEchoInstance(input: $input) {\n ...echoInstance\n }\n}\n \n fragment echoInstance on EchoInstance {\n id\n name\n messages {\n lang\n value\n }\n createdAt\n updatedAt\n}\n ";
220
+ export declare const UpdateEchoInstanceDocument = "\n mutation updateEchoInstance($input: UpdateEchoAppInput!) {\n updateEchoInstance(input: $input) {\n ...echoInstance\n }\n}\n \n fragment echoInstance on EchoInstance {\n id\n name\n messages {\n lang\n value\n }\n createdAt\n updatedAt\n}\n ";
221
+ export declare const RemoveEchoInstanceDocument = "\n mutation removeEchoInstance($id: ID!) {\n removeEchoInstance(id: $id) {\n ...echoInstance\n }\n}\n \n fragment echoInstance on EchoInstance {\n id\n name\n messages {\n lang\n value\n }\n createdAt\n updatedAt\n}\n ";
222
+ export type Requester<C = {}> = <R, V>(doc: string, vars?: V, options?: C) => Promise<R> | AsyncIterableIterator<R>;
223
+ export declare function getSdk<C>(requester: Requester<C>): {
224
+ getEchoInstance(variables: GetEchoInstanceQueryVariables, options?: C): Promise<GetEchoInstanceQuery>;
225
+ createEchoInstance(variables: CreateEchoInstanceMutationVariables, options?: C): Promise<CreateEchoInstanceMutation>;
226
+ updateEchoInstance(variables: UpdateEchoInstanceMutationVariables, options?: C): Promise<UpdateEchoInstanceMutation>;
227
+ removeEchoInstance(variables: RemoveEchoInstanceMutationVariables, options?: C): Promise<RemoveEchoInstanceMutation>;
228
+ };
229
+ export type Sdk = ReturnType<typeof getSdk>;
230
+ export declare const serviceName = "@droz/utilities";
@@ -0,0 +1,75 @@
1
+ "use strict";
2
+ /* istanbul ignore file */
3
+ Object.defineProperty(exports, "__esModule", { value: true });
4
+ exports.serviceName = exports.getSdk = exports.RemoveEchoInstanceDocument = exports.UpdateEchoInstanceDocument = exports.CreateEchoInstanceDocument = exports.GetEchoInstanceDocument = exports.EchoInstanceFragmentDoc = exports.Typenames = exports.AppInstanceStatus = void 0;
5
+ var AppInstanceStatus;
6
+ (function (AppInstanceStatus) {
7
+ AppInstanceStatus["Active"] = "Active";
8
+ AppInstanceStatus["Failing"] = "Failing";
9
+ AppInstanceStatus["Inactive"] = "Inactive";
10
+ })(AppInstanceStatus || (exports.AppInstanceStatus = AppInstanceStatus = {}));
11
+ var Typenames;
12
+ (function (Typenames) {
13
+ Typenames["Any"] = "Any";
14
+ Typenames["Echo"] = "Echo";
15
+ Typenames["GraphqlConnections"] = "GraphqlConnections";
16
+ Typenames["GraphqlSubscriptions"] = "GraphqlSubscriptions";
17
+ })(Typenames || (exports.Typenames = Typenames = {}));
18
+ exports.EchoInstanceFragmentDoc = `
19
+ fragment echoInstance on EchoInstance {
20
+ id
21
+ name
22
+ messages {
23
+ lang
24
+ value
25
+ }
26
+ createdAt
27
+ updatedAt
28
+ }
29
+ `;
30
+ exports.GetEchoInstanceDocument = `
31
+ query getEchoInstance($id: ID!) {
32
+ getEchoInstance(id: $id) {
33
+ ...echoInstance
34
+ }
35
+ }
36
+ ${exports.EchoInstanceFragmentDoc}`;
37
+ exports.CreateEchoInstanceDocument = `
38
+ mutation createEchoInstance($input: CreateEchoAppInput!) {
39
+ createEchoInstance(input: $input) {
40
+ ...echoInstance
41
+ }
42
+ }
43
+ ${exports.EchoInstanceFragmentDoc}`;
44
+ exports.UpdateEchoInstanceDocument = `
45
+ mutation updateEchoInstance($input: UpdateEchoAppInput!) {
46
+ updateEchoInstance(input: $input) {
47
+ ...echoInstance
48
+ }
49
+ }
50
+ ${exports.EchoInstanceFragmentDoc}`;
51
+ exports.RemoveEchoInstanceDocument = `
52
+ mutation removeEchoInstance($id: ID!) {
53
+ removeEchoInstance(id: $id) {
54
+ ...echoInstance
55
+ }
56
+ }
57
+ ${exports.EchoInstanceFragmentDoc}`;
58
+ function getSdk(requester) {
59
+ return {
60
+ getEchoInstance(variables, options) {
61
+ return requester(exports.GetEchoInstanceDocument, variables, options);
62
+ },
63
+ createEchoInstance(variables, options) {
64
+ return requester(exports.CreateEchoInstanceDocument, variables, options);
65
+ },
66
+ updateEchoInstance(variables, options) {
67
+ return requester(exports.UpdateEchoInstanceDocument, variables, options);
68
+ },
69
+ removeEchoInstance(variables, options) {
70
+ return requester(exports.RemoveEchoInstanceDocument, variables, options);
71
+ }
72
+ };
73
+ }
74
+ exports.getSdk = getSdk;
75
+ exports.serviceName = '@droz/utilities';
@@ -107,6 +107,10 @@ export type I18nText = {
107
107
  lang: Scalars['Locale']['output'];
108
108
  value: Scalars['String']['output'];
109
109
  };
110
+ export type I18nTextInput = {
111
+ lang: Scalars['Locale']['input'];
112
+ value: Scalars['String']['input'];
113
+ };
110
114
  export type Mutation = {
111
115
  createZendeskInstance?: Maybe<ZendeskInstance>;
112
116
  removeZendeskInstance?: Maybe<ZendeskInstance>;