@arbol-ai/sdk 2.18.0 → 3.0.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.
- package/README.md +19 -1
- package/dist/client.d.ts +4 -0
- package/dist/client.js +10 -0
- package/dist/index.d.ts +1 -1
- package/dist/models.d.ts +396 -0
- package/dist/models.js +5 -1
- package/dist/nuevaEps/affiliations/models.d.ts +6 -5
- package/dist/nuevaEps/connections/models.d.ts +18 -18
- package/dist/nuevaEps/index.d.ts +1 -1
- package/dist/nuevaEps/models.d.ts +16 -232
- package/dist/{visoft/tools → orsovision/agencies}/client.d.ts +13 -19
- package/dist/{visoft/tools → orsovision/agencies}/client.js +2 -2
- package/dist/orsovision/agencies/index.d.ts +5 -0
- package/dist/orsovision/agencies/models.d.ts +107 -0
- package/dist/orsovision/appointments/client.d.ts +39 -0
- package/dist/orsovision/appointments/client.js +29 -0
- package/dist/orsovision/appointments/index.d.ts +5 -0
- package/dist/orsovision/appointments/models.d.ts +206 -0
- package/dist/orsovision/appointments/models.js +9 -0
- package/dist/orsovision/availability/client.d.ts +32 -0
- package/dist/orsovision/availability/client.js +19 -0
- package/dist/orsovision/availability/index.d.ts +5 -0
- package/dist/orsovision/availability/models.d.ts +239 -0
- package/dist/orsovision/availability/models.js +15 -0
- package/dist/orsovision/client.d.ts +27 -0
- package/dist/orsovision/client.js +50 -0
- package/dist/orsovision/clinic/client.d.ts +34 -0
- package/dist/{visoft/specialtyRules → orsovision/clinic}/client.js +3 -3
- package/dist/orsovision/clinic/index.d.ts +5 -0
- package/dist/orsovision/clinic/models.d.ts +89 -0
- package/dist/orsovision/contracts/client.d.ts +69 -0
- package/dist/orsovision/contracts/client.js +18 -0
- package/dist/orsovision/contracts/index.d.ts +5 -0
- package/dist/orsovision/contracts/models.d.ts +108 -0
- package/dist/orsovision/index.d.ts +5 -0
- package/dist/orsovision/index.js +4 -0
- package/dist/orsovision/models.d.ts +227 -0
- package/dist/orsovision/patients/client.d.ts +52 -0
- package/dist/orsovision/patients/client.js +34 -0
- package/dist/orsovision/patients/index.d.ts +5 -0
- package/dist/orsovision/patients/models.d.ts +297 -0
- package/dist/orsovision/patients/models.js +3 -0
- package/dist/orsovision/services/client.d.ts +74 -0
- package/dist/orsovision/services/client.js +18 -0
- package/dist/orsovision/services/index.d.ts +5 -0
- package/dist/orsovision/services/index.js +4 -0
- package/dist/orsovision/services/models.d.ts +105 -0
- package/dist/orsovision/services/models.js +3 -0
- package/dist/orsovision/tools/client.d.ts +44 -0
- package/dist/{raiz/roles → orsovision/tools}/client.js +3 -3
- package/dist/orsovision/tools/index.d.ts +5 -0
- package/dist/orsovision/tools/index.js +4 -0
- package/dist/orsovision/tools/models.d.ts +101 -0
- package/dist/orsovision/tools/models.js +3 -0
- package/dist/raiz/agents/models.d.ts +1 -0
- package/dist/raiz/client.d.ts +0 -4
- package/dist/raiz/client.js +0 -10
- package/dist/raiz/conversations/client.d.ts +7 -3
- package/dist/raiz/conversations/index.d.ts +1 -1
- package/dist/raiz/conversations/models.d.ts +22 -0
- package/dist/raiz/organization/client.d.ts +40 -40
- package/dist/raiz/organization/client.js +10 -10
- package/dist/raiz/organization/index.d.ts +1 -1
- package/dist/raiz/reports/client.d.ts +3 -3
- package/dist/raiz/reports/client.js +2 -2
- package/dist/raiz/reports/index.d.ts +1 -1
- package/dist/somos/appointments/client.d.ts +40 -0
- package/dist/somos/appointments/client.js +29 -0
- package/dist/somos/appointments/index.d.ts +5 -0
- package/dist/somos/appointments/index.js +4 -0
- package/dist/somos/appointments/models.d.ts +301 -0
- package/dist/somos/appointments/models.js +9 -0
- package/dist/somos/availability/client.d.ts +33 -0
- package/dist/somos/availability/client.js +19 -0
- package/dist/somos/availability/index.d.ts +5 -0
- package/dist/somos/availability/index.js +4 -0
- package/dist/somos/availability/models.d.ts +340 -0
- package/dist/somos/availability/models.js +15 -0
- package/dist/somos/client.d.ts +29 -0
- package/dist/somos/client.js +55 -0
- package/dist/somos/clinic/client.d.ts +33 -0
- package/dist/somos/clinic/client.js +18 -0
- package/dist/somos/clinic/index.d.ts +5 -0
- package/dist/somos/clinic/index.js +4 -0
- package/dist/somos/clinic/models.d.ts +89 -0
- package/dist/somos/clinic/models.js +3 -0
- package/dist/somos/contracts/client.d.ts +74 -0
- package/dist/somos/contracts/client.js +18 -0
- package/dist/somos/contracts/index.d.ts +5 -0
- package/dist/somos/contracts/index.js +4 -0
- package/dist/somos/contracts/models.d.ts +107 -0
- package/dist/somos/contracts/models.js +3 -0
- package/dist/somos/groups/client.d.ts +67 -0
- package/dist/{visoft → somos}/groups/client.js +2 -2
- package/dist/somos/groups/index.d.ts +5 -0
- package/dist/somos/groups/index.js +4 -0
- package/dist/somos/groups/models.d.ts +117 -0
- package/dist/somos/groups/models.js +3 -0
- package/dist/somos/index.d.ts +5 -0
- package/dist/somos/index.js +4 -0
- package/dist/somos/models.d.ts +227 -0
- package/dist/somos/models.js +3 -0
- package/dist/somos/patients/client.d.ts +51 -0
- package/dist/somos/patients/client.js +34 -0
- package/dist/somos/patients/index.d.ts +5 -0
- package/dist/somos/patients/index.js +4 -0
- package/dist/somos/patients/models.d.ts +327 -0
- package/dist/somos/patients/models.js +3 -0
- package/dist/somos/services/client.d.ts +117 -0
- package/dist/somos/services/client.js +26 -0
- package/dist/somos/services/index.d.ts +5 -0
- package/dist/somos/services/index.js +4 -0
- package/dist/somos/services/models.d.ts +272 -0
- package/dist/somos/services/models.js +3 -0
- package/dist/somos/specialtyRules/client.d.ts +44 -0
- package/dist/somos/specialtyRules/client.js +18 -0
- package/dist/somos/specialtyRules/index.d.ts +5 -0
- package/dist/somos/specialtyRules/index.js +4 -0
- package/dist/somos/specialtyRules/models.d.ts +54 -0
- package/dist/somos/specialtyRules/models.js +3 -0
- package/dist/{raiz/roles → somos/tools}/client.d.ts +14 -12
- package/dist/{visoft/agencies → somos/tools}/client.js +3 -3
- package/dist/somos/tools/index.d.ts +5 -0
- package/dist/somos/tools/index.js +4 -0
- package/dist/somos/tools/models.d.ts +101 -0
- package/dist/somos/tools/models.js +3 -0
- package/dist/visoft/appointments/client.d.ts +20 -194
- package/dist/visoft/appointments/client.js +5 -4
- package/dist/visoft/appointments/index.d.ts +1 -0
- package/dist/visoft/appointments/models.d.ts +391 -0
- package/dist/visoft/appointments/models.js +15 -0
- package/dist/visoft/availability/client.d.ts +10 -164
- package/dist/visoft/availability/client.js +9 -9
- package/dist/visoft/availability/index.d.ts +2 -2
- package/dist/visoft/availability/models.d.ts +154 -64
- package/dist/visoft/availability/models.js +10 -8
- package/dist/visoft/client.d.ts +6 -8
- package/dist/visoft/client.js +15 -20
- package/dist/visoft/clinic/client.d.ts +30 -0
- package/dist/visoft/clinic/client.js +18 -0
- package/dist/visoft/{specialtyRules → clinic}/index.d.ts +1 -0
- package/dist/visoft/clinic/index.js +4 -0
- package/dist/visoft/clinic/models.d.ts +13 -0
- package/dist/visoft/clinic/models.js +3 -0
- package/dist/visoft/clinics/client.d.ts +2 -31
- package/dist/visoft/clinics/client.js +1 -8
- package/dist/visoft/clinics/index.d.ts +2 -2
- package/dist/visoft/clinics/models.d.ts +13 -24
- package/dist/visoft/connections/client.d.ts +17 -74
- package/dist/visoft/connections/client.js +10 -11
- package/dist/visoft/connections/index.d.ts +1 -1
- package/dist/visoft/connections/models.d.ts +93 -1
- package/dist/visoft/connections/models.js +6 -0
- package/dist/visoft/contracts/client.d.ts +14 -49
- package/dist/visoft/contracts/client.js +2 -2
- package/dist/visoft/contracts/index.d.ts +1 -1
- package/dist/visoft/contracts/models.d.ts +43 -7
- package/dist/visoft/index.d.ts +1 -1
- package/dist/visoft/models.d.ts +311 -139
- package/dist/visoft/patients/client.d.ts +24 -264
- package/dist/visoft/patients/client.js +7 -6
- package/dist/visoft/patients/index.d.ts +1 -0
- package/dist/visoft/patients/models.d.ts +737 -0
- package/dist/visoft/patients/models.js +15 -0
- package/dist/visoft/professionals/client.d.ts +56 -0
- package/dist/visoft/professionals/client.js +18 -0
- package/dist/visoft/professionals/index.d.ts +5 -0
- package/dist/visoft/professionals/index.js +4 -0
- package/dist/visoft/professionals/models.d.ts +54 -0
- package/dist/visoft/professionals/models.js +3 -0
- package/dist/visoft/serviceCatalogs/client.d.ts +45 -0
- package/dist/visoft/serviceCatalogs/client.js +18 -0
- package/dist/visoft/serviceCatalogs/index.d.ts +5 -0
- package/dist/visoft/serviceCatalogs/index.js +4 -0
- package/dist/visoft/serviceCatalogs/models.d.ts +68 -0
- package/dist/visoft/serviceCatalogs/models.js +3 -0
- package/dist/visoft/services/client.d.ts +25 -61
- package/dist/visoft/services/client.js +2 -2
- package/dist/visoft/services/index.d.ts +1 -1
- package/dist/visoft/services/models.d.ts +52 -15
- package/package.json +9 -3
- package/dist/raiz/members/client.d.ts +0 -102
- package/dist/raiz/members/client.js +0 -35
- package/dist/raiz/members/index.d.ts +0 -5
- package/dist/raiz/members/models.d.ts +0 -48
- package/dist/raiz/members/models.js +0 -10
- package/dist/raiz/roles/index.d.ts +0 -5
- package/dist/raiz/roles/models.d.ts +0 -32
- package/dist/visoft/agencies/client.d.ts +0 -58
- package/dist/visoft/agencies/index.d.ts +0 -5
- package/dist/visoft/agencies/models.d.ts +0 -29
- package/dist/visoft/groups/client.d.ts +0 -69
- package/dist/visoft/groups/index.d.ts +0 -5
- package/dist/visoft/groups/models.d.ts +0 -39
- package/dist/visoft/specialtyRules/client.d.ts +0 -50
- package/dist/visoft/tools/index.d.ts +0 -5
- package/dist/visoft/tools/models.d.ts +0 -37
- /package/dist/{raiz/members → orsovision/agencies}/index.js +0 -0
- /package/dist/{raiz/roles → orsovision/agencies}/models.js +0 -0
- /package/dist/{raiz/roles → orsovision/appointments}/index.js +0 -0
- /package/dist/{visoft/agencies → orsovision/availability}/index.js +0 -0
- /package/dist/{visoft/groups → orsovision/clinic}/index.js +0 -0
- /package/dist/{visoft/agencies → orsovision/clinic}/models.js +0 -0
- /package/dist/{visoft/specialtyRules → orsovision/contracts}/index.js +0 -0
- /package/dist/{visoft/groups → orsovision/contracts}/models.js +0 -0
- /package/dist/{visoft/tools → orsovision}/models.js +0 -0
- /package/dist/{visoft/tools → orsovision/patients}/index.js +0 -0
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { type BaseClientOptions, type RequestOptions, Transport } from "../../_/index.js";
|
|
2
|
-
import type
|
|
3
|
-
import { type VisoftAvailabilitySlotPage } from "./models.js";
|
|
2
|
+
import { type VisoftAvailabilityResponse, type VisoftLookupAvailabilityBody } from "./models.js";
|
|
4
3
|
export interface ClientOptions extends BaseClientOptions {
|
|
5
4
|
/**
|
|
6
5
|
* The URL the paths of the API are relative to.
|
|
@@ -9,170 +8,17 @@ export interface ClientOptions extends BaseClientOptions {
|
|
|
9
8
|
}
|
|
10
9
|
export interface Client {
|
|
11
10
|
/**
|
|
12
|
-
* Find
|
|
11
|
+
* Find free slots
|
|
13
12
|
*
|
|
14
|
-
*
|
|
15
|
-
*
|
|
16
|
-
* reference
|
|
17
|
-
*
|
|
18
|
-
*
|
|
19
|
-
* asked for had none; alternative, the time preference had none (say those
|
|
20
|
-
* first). A completed search without slots is TOOL_REFUSED (NO_AVAILABILITY);
|
|
21
|
-
* never search again without the person's filters. This read never books
|
|
22
|
-
* anything. A refusal is TOOL_REFUSED: data.reason says why, data.guidance
|
|
23
|
-
* what to do next and data.details what it offers instead; it is never an
|
|
24
|
-
* outage. The connection's clinic sets this tool's rules, parameters and
|
|
25
|
-
* accepted values: visoft.tools.list answers them for the connection, and
|
|
26
|
-
* every call is checked against them.
|
|
13
|
+
* The free slots of one service under one contract at a cost centre, from a
|
|
14
|
+
* day on, read from every professional's agenda (or the one named), each with
|
|
15
|
+
* the reference visoft.appointments.create takes. A professional whose agenda
|
|
16
|
+
* SIIPS did not answer is failed:true: their slots are unknown, never none.
|
|
17
|
+
* Never cached. This read never books anything.
|
|
27
18
|
*/
|
|
28
|
-
|
|
19
|
+
lookup(request: LookupRequest, options?: RequestOptions): Promise<LookupResponse>;
|
|
29
20
|
}
|
|
30
21
|
export declare function createClient(options: ClientOptions): Client;
|
|
31
22
|
export declare function bind(transport: Transport): Client;
|
|
32
|
-
export
|
|
33
|
-
|
|
34
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
35
|
-
* meaning, accepted values and whether it is required.
|
|
36
|
-
*/
|
|
37
|
-
documentNumber?: string;
|
|
38
|
-
/**
|
|
39
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
40
|
-
* meaning, accepted values and whether it is required.
|
|
41
|
-
*/
|
|
42
|
-
agency?: string;
|
|
43
|
-
/**
|
|
44
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
45
|
-
* meaning, accepted values and whether it is required.
|
|
46
|
-
*/
|
|
47
|
-
contract?: string;
|
|
48
|
-
/**
|
|
49
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
50
|
-
* meaning, accepted values and whether it is required.
|
|
51
|
-
*/
|
|
52
|
-
service?: string;
|
|
53
|
-
/**
|
|
54
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
55
|
-
* meaning, accepted values and whether it is required.
|
|
56
|
-
*/
|
|
57
|
-
date?: string;
|
|
58
|
-
/**
|
|
59
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
60
|
-
* meaning, accepted values and whether it is required.
|
|
61
|
-
*/
|
|
62
|
-
medic?: string;
|
|
63
|
-
/**
|
|
64
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
65
|
-
* meaning, accepted values and whether it is required.
|
|
66
|
-
*/
|
|
67
|
-
from?: string;
|
|
68
|
-
/**
|
|
69
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
70
|
-
* meaning, accepted values and whether it is required.
|
|
71
|
-
*/
|
|
72
|
-
to?: string;
|
|
73
|
-
/**
|
|
74
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
75
|
-
* meaning, accepted values and whether it is required.
|
|
76
|
-
*/
|
|
77
|
-
refresh?: boolean;
|
|
78
|
-
/**
|
|
79
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
80
|
-
* meaning, accepted values and whether it is required.
|
|
81
|
-
*/
|
|
82
|
-
specialty?: string;
|
|
83
|
-
/**
|
|
84
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
85
|
-
* meaning, accepted values and whether it is required.
|
|
86
|
-
*/
|
|
87
|
-
regimen?: string;
|
|
88
|
-
/**
|
|
89
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
90
|
-
* meaning, accepted values and whether it is required.
|
|
91
|
-
*/
|
|
92
|
-
eps?: string;
|
|
93
|
-
/**
|
|
94
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
95
|
-
* meaning, accepted values and whether it is required.
|
|
96
|
-
*/
|
|
97
|
-
sala?: string;
|
|
98
|
-
/**
|
|
99
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
100
|
-
* meaning, accepted values and whether it is required.
|
|
101
|
-
*/
|
|
102
|
-
modality?: string;
|
|
103
|
-
/**
|
|
104
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
105
|
-
* meaning, accepted values and whether it is required.
|
|
106
|
-
*/
|
|
107
|
-
authorizationService?: string;
|
|
108
|
-
/**
|
|
109
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
110
|
-
* meaning, accepted values and whether it is required.
|
|
111
|
-
*/
|
|
112
|
-
timeFrom?: string;
|
|
113
|
-
/**
|
|
114
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
115
|
-
* meaning, accepted values and whether it is required.
|
|
116
|
-
*/
|
|
117
|
-
timeTo?: string;
|
|
118
|
-
/**
|
|
119
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
120
|
-
* meaning, accepted values and whether it is required.
|
|
121
|
-
*/
|
|
122
|
-
intent?: string;
|
|
123
|
-
/**
|
|
124
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
125
|
-
* meaning, accepted values and whether it is required.
|
|
126
|
-
*/
|
|
127
|
-
patientAgeMonths?: string;
|
|
128
|
-
/**
|
|
129
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
130
|
-
* meaning, accepted values and whether it is required.
|
|
131
|
-
*/
|
|
132
|
-
fonoGroup?: string;
|
|
133
|
-
/**
|
|
134
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
135
|
-
* meaning, accepted values and whether it is required.
|
|
136
|
-
*/
|
|
137
|
-
toGroup?: string;
|
|
138
|
-
/**
|
|
139
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
140
|
-
* meaning, accepted values and whether it is required.
|
|
141
|
-
*/
|
|
142
|
-
pairWithNext?: boolean;
|
|
143
|
-
/**
|
|
144
|
-
* As the connection's clinic defines it: visoft.tools.list answers its
|
|
145
|
-
* meaning, accepted values and whether it is required.
|
|
146
|
-
*/
|
|
147
|
-
professionalChangeConfirmed?: boolean;
|
|
148
|
-
/**
|
|
149
|
-
* Opaque cursor returned by pageInfo; omit it to request the first page.
|
|
150
|
-
*/
|
|
151
|
-
cursor?: string;
|
|
152
|
-
/**
|
|
153
|
-
* Direction to traverse the stable keyset ordering from the supplied cursor.
|
|
154
|
-
*/
|
|
155
|
-
direction?: "forward" | "backward";
|
|
156
|
-
/**
|
|
157
|
-
* Maximum items returned in one page. Defaults to 25; larger reads require
|
|
158
|
-
* another cursor.
|
|
159
|
-
*/
|
|
160
|
-
limit?: number;
|
|
161
|
-
/**
|
|
162
|
-
* The connection to run on. Optional when the organization has one Visoft
|
|
163
|
-
* connection; required when it has several. Another organization's connection
|
|
164
|
-
* is NOT_FOUND.
|
|
165
|
-
*/
|
|
166
|
-
connectionId?: string;
|
|
167
|
-
/**
|
|
168
|
-
* The channel the conversation happens on: voice, whatsapp or web (the
|
|
169
|
-
* default).
|
|
170
|
-
*/
|
|
171
|
-
channel?: "voice" | "web" | "whatsapp";
|
|
172
|
-
}
|
|
173
|
-
export interface ListResponse {
|
|
174
|
-
data: VisoftAvailabilitySlotPage;
|
|
175
|
-
error: null;
|
|
176
|
-
metadata: ResponseMetadata;
|
|
177
|
-
success: true;
|
|
178
|
-
}
|
|
23
|
+
export type LookupRequest = VisoftLookupAvailabilityBody;
|
|
24
|
+
export type LookupResponse = VisoftAvailabilityResponse;
|
|
@@ -1,19 +1,19 @@
|
|
|
1
1
|
// Code generated by forge. DO NOT EDIT.
|
|
2
2
|
/* eslint-disable */
|
|
3
|
-
import { Transport,
|
|
4
|
-
import {
|
|
3
|
+
import { Transport, } from "../../_/index.js";
|
|
4
|
+
import { VisoftAvailabilityResponseCodec, } from "./models.js";
|
|
5
5
|
export function createClient(options) {
|
|
6
6
|
return bind(new Transport(options));
|
|
7
7
|
}
|
|
8
8
|
export function bind(transport) {
|
|
9
9
|
return {
|
|
10
|
-
|
|
10
|
+
lookup: (request, options) => transport.send(LookupOperation, request, options),
|
|
11
11
|
};
|
|
12
12
|
}
|
|
13
|
-
const
|
|
14
|
-
method: "
|
|
15
|
-
route: "/v1/visoft/availability",
|
|
16
|
-
|
|
17
|
-
response:
|
|
18
|
-
errors: { "400": true, "401": true, "403": true, "404": true, "
|
|
13
|
+
const LookupOperation = {
|
|
14
|
+
method: "POST",
|
|
15
|
+
route: "/v1/visoft/availability/lookup",
|
|
16
|
+
body: "flat",
|
|
17
|
+
response: VisoftAvailabilityResponseCodec,
|
|
18
|
+
errors: { "400": true, "401": true, "403": true, "404": true, "409": true, "413": true, "415": true, "422": true, "429": true, "500": true, "502": true, "503": true, "504": true },
|
|
19
19
|
};
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
export { ApiError } from "../../_/index.js";
|
|
2
2
|
export type { RequestOptions } from "../../_/index.js";
|
|
3
3
|
export { createClient } from "./client.js";
|
|
4
|
-
export type { Client, ClientOptions,
|
|
5
|
-
export type {
|
|
4
|
+
export type { Client, ClientOptions, LookupRequest, LookupResponse, } from "./client.js";
|
|
5
|
+
export type { VisoftAvailability, VisoftAvailabilityResponse, VisoftAvailableSlot, VisoftLookupAvailabilityBadGatewayError, VisoftLookupAvailabilityBadGatewayFailure, VisoftLookupAvailabilityBody, VisoftLookupAvailabilityNotFoundError, VisoftLookupAvailabilityNotFoundFailure, VisoftLookupAvailabilityUnprocessableContentError, VisoftLookupAvailabilityUnprocessableContentFailure, VisoftProfessionalAvailability, VisoftProfessionalNotFoundFailure, } from "./models.js";
|
|
@@ -1,100 +1,190 @@
|
|
|
1
|
-
import type {
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
sala?: string;
|
|
15
|
-
service: string;
|
|
16
|
-
specialty?: string;
|
|
17
|
-
time: string;
|
|
18
|
-
toGroup?: string;
|
|
1
|
+
import type { ConnectionNotFoundFailure, CredentialsRejectedFailure, Empty, OutcomeUnknownFailure, ProviderUnavailableFailure } from "../../models.js";
|
|
2
|
+
import type { VisoftAgencyNotServedFailure, VisoftProfessional, VisoftResponseMetadata } from "../models.js";
|
|
3
|
+
export interface VisoftAvailability {
|
|
4
|
+
/**
|
|
5
|
+
* The day the search started, in the clinic: YYYY-MM-DD.
|
|
6
|
+
*/
|
|
7
|
+
from: string;
|
|
8
|
+
/**
|
|
9
|
+
* Every professional of the service at the cost centre (or the one asked
|
|
10
|
+
* for), in the directory's order, each with their free slots. Never cached:
|
|
11
|
+
* read for this call.
|
|
12
|
+
*/
|
|
13
|
+
professionals: VisoftProfessionalAvailability[];
|
|
19
14
|
}
|
|
20
|
-
|
|
15
|
+
/**
|
|
16
|
+
* A successful answer.
|
|
17
|
+
*/
|
|
18
|
+
export interface VisoftAvailabilityResponse {
|
|
19
|
+
data: VisoftAvailability;
|
|
20
|
+
error: null;
|
|
21
21
|
/**
|
|
22
|
-
*
|
|
22
|
+
* What every answer carries besides its data or error.
|
|
23
23
|
*/
|
|
24
|
-
|
|
24
|
+
metadata: VisoftResponseMetadata;
|
|
25
|
+
success: true;
|
|
26
|
+
}
|
|
27
|
+
export interface VisoftAvailableSlot {
|
|
25
28
|
/**
|
|
26
|
-
*
|
|
27
|
-
* person confirms this slot and service; add the confirmed documentNumber.
|
|
28
|
-
* Retain separately confirmed consent. Never replace the service or contract
|
|
29
|
-
* with a fresh EPS guess.
|
|
29
|
+
* The cost centre the slot is at.
|
|
30
30
|
*/
|
|
31
|
-
|
|
31
|
+
agencyCode: string;
|
|
32
32
|
/**
|
|
33
|
-
* The
|
|
33
|
+
* The professional's SIIPS id.
|
|
34
34
|
*/
|
|
35
|
-
|
|
35
|
+
professionalId: string;
|
|
36
36
|
/**
|
|
37
|
-
* The
|
|
37
|
+
* The professional, as SIIPS names them.
|
|
38
38
|
*/
|
|
39
|
-
|
|
40
|
-
fonoGroup?: string;
|
|
39
|
+
professionalName: string;
|
|
41
40
|
/**
|
|
42
|
-
* The
|
|
41
|
+
* The purpose SIIPS shows on the agenda.
|
|
43
42
|
*/
|
|
44
|
-
|
|
43
|
+
purpose: string;
|
|
45
44
|
/**
|
|
46
|
-
* The
|
|
45
|
+
* The free slot's SIIPS key, as visoft.availability.lookup answered it: pass
|
|
46
|
+
* it unchanged to visoft.appointments.create.
|
|
47
47
|
*/
|
|
48
|
-
|
|
49
|
-
modality?: string;
|
|
48
|
+
reference: string;
|
|
50
49
|
/**
|
|
51
|
-
*
|
|
52
|
-
* professional is free too.
|
|
50
|
+
* The agenda block the slot belongs to.
|
|
53
51
|
*/
|
|
54
|
-
|
|
52
|
+
scheduleId: string;
|
|
55
53
|
/**
|
|
56
|
-
* The
|
|
54
|
+
* The slot's position in its agenda block.
|
|
57
55
|
*/
|
|
58
|
-
|
|
56
|
+
slotNumber: string;
|
|
59
57
|
/**
|
|
60
|
-
* The
|
|
58
|
+
* The specialty SIIPS shows on the agenda.
|
|
61
59
|
*/
|
|
62
60
|
specialty: string;
|
|
63
61
|
/**
|
|
64
|
-
* The
|
|
62
|
+
* The moment, as an RFC 3339 instant written in the clinic's own offset (for
|
|
63
|
+
* example "2026-11-04T08:50:00-05:00"), so its first ten characters are the
|
|
64
|
+
* clinic's day and the next eight its hour.
|
|
65
|
+
*/
|
|
66
|
+
startsAt: Temporal.Instant;
|
|
67
|
+
/**
|
|
68
|
+
* SIIPS's status of the slot.
|
|
69
|
+
*/
|
|
70
|
+
status: string;
|
|
71
|
+
/**
|
|
72
|
+
* The sub cost centre of the agenda.
|
|
73
|
+
*/
|
|
74
|
+
subCostCenter: string;
|
|
75
|
+
}
|
|
76
|
+
/**
|
|
77
|
+
* A failed answer.
|
|
78
|
+
*/
|
|
79
|
+
export interface VisoftLookupAvailabilityBadGatewayError {
|
|
80
|
+
data: null;
|
|
81
|
+
error: VisoftLookupAvailabilityBadGatewayFailure;
|
|
82
|
+
/**
|
|
83
|
+
* What every answer carries besides its data or error.
|
|
84
|
+
*/
|
|
85
|
+
metadata: VisoftResponseMetadata;
|
|
86
|
+
success: false;
|
|
87
|
+
}
|
|
88
|
+
export type VisoftLookupAvailabilityBadGatewayFailure = OutcomeUnknownFailure | ProviderUnavailableFailure;
|
|
89
|
+
export interface VisoftLookupAvailabilityBody {
|
|
90
|
+
/**
|
|
91
|
+
* One of the clinic's cost centres, as visoft.clinic.get lists them. Optional
|
|
92
|
+
* when the clinic has a default one.
|
|
93
|
+
*/
|
|
94
|
+
agencyCode?: string;
|
|
95
|
+
/**
|
|
96
|
+
* How many agendas are read from SIIPS at once (5 by default).
|
|
65
97
|
*/
|
|
66
|
-
|
|
67
|
-
toGroup?: string;
|
|
98
|
+
concurrency?: number;
|
|
68
99
|
/**
|
|
69
|
-
* The
|
|
70
|
-
* when
|
|
100
|
+
* The connection to run on. Optional when the organization has one Visoft
|
|
101
|
+
* connection; required when it has several. Another organization's connection
|
|
102
|
+
* is CONNECTION_NOT_FOUND.
|
|
71
103
|
*/
|
|
72
|
-
|
|
104
|
+
connectionId?: string;
|
|
73
105
|
/**
|
|
74
|
-
* The
|
|
106
|
+
* The contract, by the code visoft.contracts.list answers.
|
|
75
107
|
*/
|
|
76
|
-
|
|
108
|
+
contractCode: string;
|
|
77
109
|
/**
|
|
78
|
-
*
|
|
79
|
-
*
|
|
80
|
-
* those dates but outside the time preference, which had none.
|
|
110
|
+
* The day the search starts, in the clinic's time (YYYY-MM-DD): SIIPS answers
|
|
111
|
+
* each professional's free slots from that day on.
|
|
81
112
|
*/
|
|
82
|
-
|
|
113
|
+
from: string;
|
|
114
|
+
/**
|
|
115
|
+
* One professional's id, as visoft.professionals.list answers it: only their
|
|
116
|
+
* agenda.
|
|
117
|
+
*/
|
|
118
|
+
professionalId?: string;
|
|
119
|
+
/**
|
|
120
|
+
* Read the professional directory again instead of its one-hour cache.
|
|
121
|
+
*/
|
|
122
|
+
refreshProfessionals?: boolean;
|
|
123
|
+
/**
|
|
124
|
+
* The service, by the code a contract's services answer ("CUPS-890208").
|
|
125
|
+
*/
|
|
126
|
+
serviceCode: string;
|
|
127
|
+
}
|
|
128
|
+
/**
|
|
129
|
+
* A failed answer.
|
|
130
|
+
*/
|
|
131
|
+
export interface VisoftLookupAvailabilityNotFoundError {
|
|
132
|
+
data: null;
|
|
133
|
+
error: VisoftLookupAvailabilityNotFoundFailure;
|
|
134
|
+
/**
|
|
135
|
+
* What every answer carries besides its data or error.
|
|
136
|
+
*/
|
|
137
|
+
metadata: VisoftResponseMetadata;
|
|
138
|
+
success: false;
|
|
83
139
|
}
|
|
84
|
-
export
|
|
140
|
+
export type VisoftLookupAvailabilityNotFoundFailure = ConnectionNotFoundFailure | VisoftProfessionalNotFoundFailure;
|
|
141
|
+
/**
|
|
142
|
+
* A failed answer.
|
|
143
|
+
*/
|
|
144
|
+
export interface VisoftLookupAvailabilityUnprocessableContentError {
|
|
145
|
+
data: null;
|
|
146
|
+
error: VisoftLookupAvailabilityUnprocessableContentFailure;
|
|
147
|
+
/**
|
|
148
|
+
* What every answer carries besides its data or error.
|
|
149
|
+
*/
|
|
150
|
+
metadata: VisoftResponseMetadata;
|
|
151
|
+
success: false;
|
|
152
|
+
}
|
|
153
|
+
export type VisoftLookupAvailabilityUnprocessableContentFailure = CredentialsRejectedFailure | VisoftAgencyNotServedFailure;
|
|
154
|
+
export interface VisoftProfessionalAvailability {
|
|
155
|
+
/**
|
|
156
|
+
* Whether SIIPS failed to answer this professional's agenda: their slots are
|
|
157
|
+
* unknown, never none.
|
|
158
|
+
*/
|
|
159
|
+
failed: boolean;
|
|
160
|
+
professional: VisoftProfessional;
|
|
161
|
+
/**
|
|
162
|
+
* Their free slots, in the order SIIPS lists them.
|
|
163
|
+
*/
|
|
164
|
+
slots: VisoftAvailableSlot[];
|
|
165
|
+
}
|
|
166
|
+
/**
|
|
167
|
+
* No professional with that id attends the service at the clinic's cost centre.
|
|
168
|
+
*/
|
|
169
|
+
export interface VisoftProfessionalNotFoundFailure {
|
|
170
|
+
/**
|
|
171
|
+
* The failure code, stable across releases.
|
|
172
|
+
*/
|
|
173
|
+
code: "PROFESSIONAL_NOT_FOUND";
|
|
85
174
|
/**
|
|
86
|
-
*
|
|
175
|
+
* No fields.
|
|
87
176
|
*/
|
|
88
|
-
data:
|
|
177
|
+
data: Empty;
|
|
89
178
|
/**
|
|
90
|
-
*
|
|
179
|
+
* What went wrong, for people; it never contains input values.
|
|
91
180
|
*/
|
|
92
|
-
|
|
181
|
+
message: string;
|
|
93
182
|
/**
|
|
94
|
-
*
|
|
183
|
+
* Whether repeating the same request may succeed.
|
|
95
184
|
*/
|
|
96
|
-
|
|
185
|
+
retryable: false;
|
|
97
186
|
}
|
|
98
|
-
export declare const
|
|
99
|
-
export declare const
|
|
100
|
-
export declare const
|
|
187
|
+
export declare const VisoftAvailabilityCodec: import("../../_/codec.js").Codec;
|
|
188
|
+
export declare const VisoftAvailabilityResponseCodec: import("../../_/codec.js").Codec;
|
|
189
|
+
export declare const VisoftAvailableSlotCodec: import("../../_/codec.js").Codec;
|
|
190
|
+
export declare const VisoftProfessionalAvailabilityCodec: import("../../_/codec.js").Codec;
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
// Code generated by forge. DO NOT EDIT.
|
|
2
2
|
/* eslint-disable */
|
|
3
|
-
import { array,
|
|
4
|
-
export const
|
|
5
|
-
["
|
|
3
|
+
import { array, instant, object } from "../../_/index.js";
|
|
4
|
+
export const VisoftAvailabilityCodec = object([
|
|
5
|
+
["professionals", null, array(() => VisoftProfessionalAvailabilityCodec)],
|
|
6
6
|
]);
|
|
7
|
-
export const
|
|
8
|
-
["
|
|
9
|
-
["date", null, date],
|
|
7
|
+
export const VisoftAvailabilityResponseCodec = object([
|
|
8
|
+
["data", null, () => VisoftAvailabilityCodec],
|
|
10
9
|
]);
|
|
11
|
-
export const
|
|
12
|
-
["
|
|
10
|
+
export const VisoftAvailableSlotCodec = object([
|
|
11
|
+
["startsAt", null, instant],
|
|
12
|
+
]);
|
|
13
|
+
export const VisoftProfessionalAvailabilityCodec = object([
|
|
14
|
+
["slots", null, array(() => VisoftAvailableSlotCodec)],
|
|
13
15
|
]);
|
package/dist/visoft/client.d.ts
CHANGED
|
@@ -1,15 +1,14 @@
|
|
|
1
1
|
import { type BaseClientOptions, Transport } from "../_/index.js";
|
|
2
|
-
import { type Client as AgenciesClient } from "./agencies/client.js";
|
|
3
2
|
import { type Client as AppointmentsClient } from "./appointments/client.js";
|
|
4
3
|
import { type Client as AvailabilityClient } from "./availability/client.js";
|
|
4
|
+
import { type Client as ClinicClient } from "./clinic/client.js";
|
|
5
5
|
import { type Client as ClinicsClient } from "./clinics/client.js";
|
|
6
6
|
import { type Client as ConnectionsClient } from "./connections/client.js";
|
|
7
7
|
import { type Client as ContractsClient } from "./contracts/client.js";
|
|
8
|
-
import { type Client as GroupsClient } from "./groups/client.js";
|
|
9
8
|
import { type Client as PatientsClient } from "./patients/client.js";
|
|
9
|
+
import { type Client as ProfessionalsClient } from "./professionals/client.js";
|
|
10
|
+
import { type Client as ServiceCatalogsClient } from "./serviceCatalogs/client.js";
|
|
10
11
|
import { type Client as ServicesClient } from "./services/client.js";
|
|
11
|
-
import { type Client as SpecialtyRulesClient } from "./specialtyRules/client.js";
|
|
12
|
-
import { type Client as ToolsClient } from "./tools/client.js";
|
|
13
12
|
export interface ClientOptions extends BaseClientOptions {
|
|
14
13
|
/**
|
|
15
14
|
* The URL the paths of the API are relative to.
|
|
@@ -17,17 +16,16 @@ export interface ClientOptions extends BaseClientOptions {
|
|
|
17
16
|
baseUrl: string;
|
|
18
17
|
}
|
|
19
18
|
export interface Client {
|
|
20
|
-
readonly agencies: AgenciesClient;
|
|
21
19
|
readonly appointments: AppointmentsClient;
|
|
22
20
|
readonly availability: AvailabilityClient;
|
|
21
|
+
readonly clinic: ClinicClient;
|
|
23
22
|
readonly clinics: ClinicsClient;
|
|
24
23
|
readonly connections: ConnectionsClient;
|
|
25
24
|
readonly contracts: ContractsClient;
|
|
26
|
-
readonly groups: GroupsClient;
|
|
27
25
|
readonly patients: PatientsClient;
|
|
26
|
+
readonly professionals: ProfessionalsClient;
|
|
27
|
+
readonly serviceCatalogs: ServiceCatalogsClient;
|
|
28
28
|
readonly services: ServicesClient;
|
|
29
|
-
readonly specialtyRules: SpecialtyRulesClient;
|
|
30
|
-
readonly tools: ToolsClient;
|
|
31
29
|
}
|
|
32
30
|
export declare function createClient(options: ClientOptions): Client;
|
|
33
31
|
export declare function bind(transport: Transport): Client;
|
package/dist/visoft/client.js
CHANGED
|
@@ -1,42 +1,40 @@
|
|
|
1
1
|
// Code generated by forge. DO NOT EDIT.
|
|
2
2
|
/* eslint-disable */
|
|
3
3
|
import { Transport } from "../_/index.js";
|
|
4
|
-
import { bind as bindAgencies, } from "./agencies/client.js";
|
|
5
4
|
import { bind as bindAppointments, } from "./appointments/client.js";
|
|
6
5
|
import { bind as bindAvailability, } from "./availability/client.js";
|
|
6
|
+
import { bind as bindClinic, } from "./clinic/client.js";
|
|
7
7
|
import { bind as bindClinics, } from "./clinics/client.js";
|
|
8
8
|
import { bind as bindConnections, } from "./connections/client.js";
|
|
9
9
|
import { bind as bindContracts, } from "./contracts/client.js";
|
|
10
|
-
import { bind as bindGroups, } from "./groups/client.js";
|
|
11
10
|
import { bind as bindPatients, } from "./patients/client.js";
|
|
11
|
+
import { bind as bindProfessionals, } from "./professionals/client.js";
|
|
12
|
+
import { bind as bindServiceCatalogs, } from "./serviceCatalogs/client.js";
|
|
12
13
|
import { bind as bindServices, } from "./services/client.js";
|
|
13
|
-
import { bind as bindSpecialtyRules, } from "./specialtyRules/client.js";
|
|
14
|
-
import { bind as bindTools, } from "./tools/client.js";
|
|
15
14
|
export function createClient(options) {
|
|
16
15
|
return bind(new Transport(options));
|
|
17
16
|
}
|
|
18
17
|
export function bind(transport) {
|
|
19
|
-
let agenciesClient;
|
|
20
18
|
let appointmentsClient;
|
|
21
19
|
let availabilityClient;
|
|
20
|
+
let clinicClient;
|
|
22
21
|
let clinicsClient;
|
|
23
22
|
let connectionsClient;
|
|
24
23
|
let contractsClient;
|
|
25
|
-
let groupsClient;
|
|
26
24
|
let patientsClient;
|
|
25
|
+
let professionalsClient;
|
|
26
|
+
let serviceCatalogsClient;
|
|
27
27
|
let servicesClient;
|
|
28
|
-
let specialtyRulesClient;
|
|
29
|
-
let toolsClient;
|
|
30
28
|
return {
|
|
31
|
-
get agencies() {
|
|
32
|
-
return (agenciesClient ??= bindAgencies(transport));
|
|
33
|
-
},
|
|
34
29
|
get appointments() {
|
|
35
30
|
return (appointmentsClient ??= bindAppointments(transport));
|
|
36
31
|
},
|
|
37
32
|
get availability() {
|
|
38
33
|
return (availabilityClient ??= bindAvailability(transport));
|
|
39
34
|
},
|
|
35
|
+
get clinic() {
|
|
36
|
+
return (clinicClient ??= bindClinic(transport));
|
|
37
|
+
},
|
|
40
38
|
get clinics() {
|
|
41
39
|
return (clinicsClient ??= bindClinics(transport));
|
|
42
40
|
},
|
|
@@ -46,20 +44,17 @@ export function bind(transport) {
|
|
|
46
44
|
get contracts() {
|
|
47
45
|
return (contractsClient ??= bindContracts(transport));
|
|
48
46
|
},
|
|
49
|
-
get groups() {
|
|
50
|
-
return (groupsClient ??= bindGroups(transport));
|
|
51
|
-
},
|
|
52
47
|
get patients() {
|
|
53
48
|
return (patientsClient ??= bindPatients(transport));
|
|
54
49
|
},
|
|
55
|
-
get
|
|
56
|
-
return (
|
|
50
|
+
get professionals() {
|
|
51
|
+
return (professionalsClient ??= bindProfessionals(transport));
|
|
57
52
|
},
|
|
58
|
-
get
|
|
59
|
-
return (
|
|
53
|
+
get serviceCatalogs() {
|
|
54
|
+
return (serviceCatalogsClient ??= bindServiceCatalogs(transport));
|
|
60
55
|
},
|
|
61
|
-
get
|
|
62
|
-
return (
|
|
56
|
+
get services() {
|
|
57
|
+
return (servicesClient ??= bindServices(transport));
|
|
63
58
|
},
|
|
64
59
|
};
|
|
65
60
|
}
|
|
@@ -0,0 +1,30 @@
|
|
|
1
|
+
import { type BaseClientOptions, type RequestOptions, Transport } from "../../_/index.js";
|
|
2
|
+
import type { VisoftClinicResponse } from "./models.js";
|
|
3
|
+
export interface ClientOptions extends BaseClientOptions {
|
|
4
|
+
/**
|
|
5
|
+
* The URL the paths of the API are relative to.
|
|
6
|
+
*/
|
|
7
|
+
baseUrl: string;
|
|
8
|
+
}
|
|
9
|
+
export interface Client {
|
|
10
|
+
/**
|
|
11
|
+
* Get the clinic
|
|
12
|
+
*
|
|
13
|
+
* The clinic a connection signs in to: its name, its SIIPS address, its
|
|
14
|
+
* timezone (every startsAt the clinical operations answer carries its offset)
|
|
15
|
+
* and its cost centres, with the one a call that names none runs at. Another
|
|
16
|
+
* organization's connection answers CONNECTION_NOT_FOUND. Contains no patient
|
|
17
|
+
* data and performs no clinical login.
|
|
18
|
+
*/
|
|
19
|
+
get(request?: GetRequest, options?: RequestOptions): Promise<GetResponse>;
|
|
20
|
+
}
|
|
21
|
+
export declare function createClient(options: ClientOptions): Client;
|
|
22
|
+
export declare function bind(transport: Transport): Client;
|
|
23
|
+
export interface GetRequest {
|
|
24
|
+
/**
|
|
25
|
+
* The connection whose clinic to read. Optional when the organization has one
|
|
26
|
+
* Visoft connection; required when it has several.
|
|
27
|
+
*/
|
|
28
|
+
connectionId?: string;
|
|
29
|
+
}
|
|
30
|
+
export type GetResponse = VisoftClinicResponse;
|