@mymehq/sdk 3.0.0 → 3.1.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/dist/index.d.ts +7 -2
- package/dist/index.js +9 -0
- package/package.json +2 -2
package/dist/index.d.ts
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { ConflictSnapshot, ItemState, CreateItemInput, Item, PaginatedResult, ItemWithMetadata, Version, Edge, Metadata, SearchResult, CreateEdgeInput, EdgeTypeSchema, TypeSchema, CreateKeyInput, ApiKey, CreateWebhookInput, Webhook, UpdateWebhookInput, WebhookDelivery, TenantConfig } from '@mymehq/shared';
|
|
2
|
-
export { ApiKey, ConflictSnapshot, CreateItemInput, CreateKeyInput, Item, ItemState, Metadata, PaginatedResult, SearchResult, TypeSchema, Version } from '@mymehq/shared';
|
|
1
|
+
import { ConflictSnapshot, ItemState, CreateItemInput, Item, PaginatedResult, ItemWithMetadata, Version, Edge, Metadata, SearchResult, CreateEdgeInput, EdgeTypeSchema, TypeSchema, CreateKeyInput, ApiKey, UpdateKeyInput, CreateWebhookInput, Webhook, UpdateWebhookInput, WebhookDelivery, TenantConfig } from '@mymehq/shared';
|
|
2
|
+
export { ApiKey, ConflictSnapshot, CreateItemInput, CreateKeyInput, Item, ItemState, Metadata, PaginatedResult, SearchResult, TypeSchema, UpdateKeyInput, Version } from '@mymehq/shared';
|
|
3
3
|
|
|
4
4
|
/**
|
|
5
5
|
* Conflict resolution strategy for item updates.
|
|
@@ -183,6 +183,11 @@ declare class MymeClient {
|
|
|
183
183
|
key: string;
|
|
184
184
|
}>;
|
|
185
185
|
list: () => Promise<ApiKey[]>;
|
|
186
|
+
/** Update mutable fields on an existing key (PATCH semantics —
|
|
187
|
+
* omitted fields are left untouched). `source` and `role` are
|
|
188
|
+
* immutable after creation and cannot be changed; the server rejects
|
|
189
|
+
* them with a 400. */
|
|
190
|
+
update: (id: string, input: UpdateKeyInput) => Promise<ApiKey>;
|
|
186
191
|
revoke: (id: string) => Promise<void>;
|
|
187
192
|
};
|
|
188
193
|
readonly webhooks: {
|
package/dist/index.js
CHANGED
|
@@ -560,6 +560,15 @@ var MymeClient = class {
|
|
|
560
560
|
);
|
|
561
561
|
return res.keys;
|
|
562
562
|
},
|
|
563
|
+
/** Update mutable fields on an existing key (PATCH semantics —
|
|
564
|
+
* omitted fields are left untouched). `source` and `role` are
|
|
565
|
+
* immutable after creation and cannot be changed; the server rejects
|
|
566
|
+
* them with a 400. */
|
|
567
|
+
update: async (id, input) => {
|
|
568
|
+
return this.transport.request("PATCH", `/keys/${id}`, {
|
|
569
|
+
body: input
|
|
570
|
+
});
|
|
571
|
+
},
|
|
563
572
|
revoke: async (id) => {
|
|
564
573
|
await this.transport.request("DELETE", `/keys/${id}`);
|
|
565
574
|
}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mymehq/sdk",
|
|
3
|
-
"version": "3.
|
|
3
|
+
"version": "3.1.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org",
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
"dist"
|
|
17
17
|
],
|
|
18
18
|
"dependencies": {
|
|
19
|
-
"@mymehq/shared": "3.
|
|
19
|
+
"@mymehq/shared": "3.1.0"
|
|
20
20
|
},
|
|
21
21
|
"devDependencies": {
|
|
22
22
|
"@types/node": "^22.0.0",
|