@corelayer-ai/cli 0.4.3 → 0.4.4

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.
@@ -128,7 +128,28 @@ export class CorelayerClient {
128
128
  params.set("groupId", groupId);
129
129
  }
130
130
  const suffix = params.toString() ? `?${params.toString()}` : "";
131
- return this.request("GET", `/api/v1/integrations/accounts${suffix}`);
131
+ const raw = await this.request("GET", `/api/v1/integrations/accounts${suffix}`);
132
+ return {
133
+ accounts: (raw.accounts ?? []).map(account => ({
134
+ id: account.id,
135
+ group_id: account.group_id,
136
+ provider_code: account.provider_code,
137
+ is_active: account.is_active,
138
+ created_at: account.created_at,
139
+ resources: (account.resources ?? []).map(resource => ({
140
+ id: resource.id,
141
+ resource_type: resource.resource_type,
142
+ external_id: resource.external_id,
143
+ name: resource.name,
144
+ is_active: resource.is_active,
145
+ })),
146
+ })),
147
+ providers: (raw.providers ?? []).map(provider => ({
148
+ provider_code: provider.provider_code,
149
+ display_name: provider.display_name,
150
+ })),
151
+ total: raw.total ?? 0,
152
+ };
132
153
  }
133
154
  }
134
155
  export async function exchangeCliCode(baseUrl, code) {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@corelayer-ai/cli",
3
- "version": "0.4.3",
3
+ "version": "0.4.4",
4
4
  "description": "Corelayer CLI",
5
5
  "type": "module",
6
6
  "bin": {