@arbol-ai/sdk 2.15.0 → 2.17.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.
@@ -62,7 +62,7 @@ export interface AccountConnection {
62
62
  path: string;
63
63
  };
64
64
  rpcMethod?: string | null;
65
- runtimeInputs?: ("connectionId" | "channel")[];
65
+ runtimeInputs?: ("connectionId" | "channel" | "conversationUrl")[];
66
66
  writesThrough?: string[];
67
67
  }[];
68
68
  /**
@@ -11,10 +11,10 @@ export interface Client {
11
11
  /**
12
12
  * Invite someone to a product
13
13
  *
14
- * Invites someone not yet in the organization by email with a role in Raíz,
14
+ * Invites someone without an Arbol account by email with a role in Raíz,
15
15
  * Agenda, Ámbar or Account. The invitation email comes from the product's own
16
- * application, so its link opens that product. Someone already in the
17
- * organization is given the role with `members.create`.
16
+ * application. Existing accounts receive access with `members.create` and
17
+ * sign in with their current password.
18
18
  */
19
19
  create(request: CreateRequest, options?: RequestOptions): Promise<CreateResponse>;
20
20
  /**
@@ -36,7 +36,7 @@ export declare function createClient(options: ClientOptions): Client;
36
36
  export declare function bind(transport: Transport): Client;
37
37
  export interface CreateRequest {
38
38
  /**
39
- * Who to invite: someone not yet in the organization.
39
+ * Who to invite: someone who does not have an Arbol account yet.
40
40
  */
41
41
  email: string;
42
42
  /**
@@ -11,8 +11,10 @@ export interface Client {
11
11
  /**
12
12
  * Give a member a role in a product
13
13
  *
14
- * Gives someone already in the organization a role in Raíz, Agenda, Ámbar or
15
- * Account, by their email. Anyone else is invited with `invitations.create`.
14
+ * Gives someone with an existing Arbol account a role in Raíz, Agenda, Ámbar
15
+ * or Account, joining them to this organization when needed. They sign in
16
+ * with their current password. Someone without an account is invited with
17
+ * `invitations.create`.
16
18
  */
17
19
  create(request: CreateRequest, options?: RequestOptions): Promise<CreateResponse>;
18
20
  /**
@@ -41,7 +43,8 @@ export declare function createClient(options: ClientOptions): Client;
41
43
  export declare function bind(transport: Transport): Client;
42
44
  export interface CreateRequest {
43
45
  /**
44
- * The email of someone already in the organization.
46
+ * The email of someone with an existing Arbol account, in this organization
47
+ * or another.
45
48
  */
46
49
  email: string;
47
50
  /**
@@ -141,6 +141,13 @@ export interface AccountFailureResponse {
141
141
  };
142
142
  message: "This person is already a member.";
143
143
  retryable: false;
144
+ } | {
145
+ code: "ACCOUNT_EXISTS";
146
+ data: {
147
+ [key: string]: unknown;
148
+ };
149
+ message: "This person already has an Arbol account. Give them access with members.create.";
150
+ retryable: false;
144
151
  } | {
145
152
  code: "INVITATION_EXISTS";
146
153
  data: {
@@ -160,7 +167,7 @@ export interface AccountFailureResponse {
160
167
  data: {
161
168
  [key: string]: unknown;
162
169
  };
163
- message: "This person is not a member.";
170
+ message: "No existing Arbol account was found.";
164
171
  retryable: false;
165
172
  } | {
166
173
  code: "INVITATION_NOT_FOUND";
@@ -8,7 +8,7 @@ export interface AccountPermission {
8
8
  /**
9
9
  * The product or integration the permission belongs to.
10
10
  */
11
- group: "raiz" | "agenda" | "ambar" | "sura" | "visoft" | "account";
11
+ group: "raiz" | "agenda" | "ambar" | "sura" | "visoft" | "nueva-eps" | "account";
12
12
  value: string;
13
13
  }
14
14
  export interface AccountPermissionPage {
@@ -19,21 +19,22 @@ export interface Client {
19
19
  * with the doctor and books it. Use reason 'priority' right after
20
20
  * create_appointment when the patient asked for a priority (urgent)
21
21
  * appointment: pass that appointment's id as appointmentId so the team can
22
- * bring it forward. Always pass conversationUrl: this conversation's link in
23
- * Arbol's Contactabilidad (https://raiz.getarbol.com/conversations/…), so the
24
- * team opens it there. Pass the patient's name, document and documentType,
25
- * phone, serviceId and the payer as the patient said it. Use resourceId only
26
- * for the professional the person requested. Calling again for the same
27
- * patient, service and reason returns the same open entry and updates
28
- * supplied consented preferences, note, payer, conversation or appointment
29
- * association. A supplied confirmed phone replaces the patient contact phone;
30
- * omitted or null phone preserves it. Omitted fields preserve their values;
31
- * resourceId:null explicitly accepts any professional. When supplying
32
- * preferences, send the complete consented date/time window; null fields
33
- * clear those limits. Identical repeats do not change the version. Staff
34
- * status, priority and original queue position are preserved. A closed entry
35
- * is not reopened. This registers a waiting-list request, never an
36
- * appointment. Then tell the patient the clinic's team will contact them.
22
+ * bring it forward. For agent calls, the platform supplies conversationUrl
23
+ * from the invoking conversation; omit that field. Direct callers may supply
24
+ * the referring conversation link so the team can reopen it. Pass the
25
+ * patient's name, document and documentType, phone, serviceId and the payer
26
+ * as the patient said it. Use resourceId only for the professional the person
27
+ * requested. Calling again for the same patient, service and reason returns
28
+ * the same open entry and updates supplied consented preferences, note,
29
+ * payer, conversation or appointment association. A supplied confirmed phone
30
+ * replaces the patient contact phone; omitted or null phone preserves it.
31
+ * Omitted fields preserve their values; resourceId:null explicitly accepts
32
+ * any professional. When supplying preferences, send the complete consented
33
+ * date/time window; null fields clear those limits. Identical repeats do not
34
+ * change the version. Staff status, priority and original queue position are
35
+ * preserved. A closed entry is not reopened. This registers a waiting-list
36
+ * request, never an appointment. Then tell the patient the clinic's team will
37
+ * contact them.
37
38
  */
38
39
  join(request: JoinRequest, options?: RequestOptions): Promise<JoinResponse>;
39
40
  /**
@@ -32,6 +32,10 @@ export interface ListRequest {
32
32
  * another cursor.
33
33
  */
34
34
  limit?: number;
35
+ /**
36
+ * Optional verified branch id returned by list_branch_offices. Omit when
37
+ * unknown; one physical site never implies id 1.
38
+ */
35
39
  branchOfficeId?: string;
36
40
  id?: string;
37
41
  serviceId?: string;
@@ -101,6 +101,12 @@ export interface CreateResponse {
101
101
  invoice?: string | null;
102
102
  key?: string | null;
103
103
  location?: string | null;
104
+ mainAttendantDocumentType?: {
105
+ id: string;
106
+ label?: string | null;
107
+ name?: string | null;
108
+ value?: string | null;
109
+ } | null;
104
110
  mainAttendantEmail?: string | null;
105
111
  mainAttendantId?: string | null;
106
112
  mainAttendantIdentification?: string | null;
@@ -145,6 +151,7 @@ export interface CreateResponse {
145
151
  time?: string | null;
146
152
  title?: string | null;
147
153
  userObjectId?: string | null;
154
+ userType?: string | null;
148
155
  viaEntryCode?: string | null;
149
156
  viaEntryId?: string | null;
150
157
  viaEntryName?: string | null;
@@ -224,6 +231,12 @@ export interface UpdateResponse {
224
231
  invoice?: string | null;
225
232
  key?: string | null;
226
233
  location?: string | null;
234
+ mainAttendantDocumentType?: {
235
+ id: string;
236
+ label?: string | null;
237
+ name?: string | null;
238
+ value?: string | null;
239
+ } | null;
227
240
  mainAttendantEmail?: string | null;
228
241
  mainAttendantId?: string | null;
229
242
  mainAttendantIdentification?: string | null;
@@ -268,6 +281,7 @@ export interface UpdateResponse {
268
281
  time?: string | null;
269
282
  title?: string | null;
270
283
  userObjectId?: string | null;
284
+ userType?: string | null;
271
285
  viaEntryCode?: string | null;
272
286
  viaEntryId?: string | null;
273
287
  viaEntryName?: string | null;
@@ -36,6 +36,12 @@ export interface GmedicAppointmentsPage {
36
36
  invoice?: string | null;
37
37
  key?: string | null;
38
38
  location?: string | null;
39
+ mainAttendantDocumentType?: {
40
+ id: string;
41
+ label?: string | null;
42
+ name?: string | null;
43
+ value?: string | null;
44
+ } | null;
39
45
  mainAttendantEmail?: string | null;
40
46
  mainAttendantId?: string | null;
41
47
  mainAttendantIdentification?: string | null;
@@ -80,6 +86,7 @@ export interface GmedicAppointmentsPage {
80
86
  time?: string | null;
81
87
  title?: string | null;
82
88
  userObjectId?: string | null;
89
+ userType?: string | null;
83
90
  viaEntryCode?: string | null;
84
91
  viaEntryId?: string | null;
85
92
  viaEntryName?: string | null;
@@ -20,7 +20,9 @@ export declare function createClient(options: ClientOptions): Client;
20
20
  export declare function bind(transport: Transport): Client;
21
21
  export interface ListRequest {
22
22
  /**
23
- * Opaque cursor returned by pageInfo; omit it to request the first page.
23
+ * Omit on the first lookup. For continuation, copy only a nextCursor returned
24
+ * by this exact query. Never supply an empty string, quotes, braces, a page
25
+ * number or an invented token.
24
26
  */
25
27
  cursor?: string;
26
28
  /**
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@arbol-ai/sdk",
3
- "version": "2.15.0",
3
+ "version": "2.17.0",
4
4
  "description": "The Arbol API for TypeScript and JavaScript, generated by Cloudflare Forge from the platform's public OpenAPI.",
5
5
  "keywords": [
6
6
  "arbol",
@@ -50,8 +50,8 @@
50
50
  "packageManager": "bun@1.4.3",
51
51
  "arbol": {
52
52
  "openapi": {
53
- "release": "1.20261028.202015",
54
- "sha256": "268d85ea2cea9f6a0cc5de011c11912128724fb1e1a101e2b12cb628a5e2c13d"
53
+ "release": "1.20261029.182916",
54
+ "sha256": "30e974049d8c3576a6b73e21c4c4c09b153ff27c1368ff7059075458366afb63"
55
55
  }
56
56
  }
57
57
  }