@mymehq/sdk 4.10.0 → 5.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/dist/auth/index.js +6 -6
- package/dist/index.d.ts +1 -1
- package/dist/index.js +1 -1
- package/package.json +2 -2
package/dist/auth/index.js
CHANGED
|
@@ -142,12 +142,12 @@ var StoredTokenProvider = class {
|
|
|
142
142
|
try {
|
|
143
143
|
const res = await this.fetch(`${this.issuer}/auth/token`, {
|
|
144
144
|
method: "POST",
|
|
145
|
-
headers: { "Content-Type": "application/
|
|
146
|
-
body:
|
|
145
|
+
headers: { "Content-Type": "application/x-www-form-urlencoded" },
|
|
146
|
+
body: new URLSearchParams({
|
|
147
147
|
grant_type: "refresh_token",
|
|
148
148
|
refresh_token: refreshToken,
|
|
149
149
|
client_id: this.clientId
|
|
150
|
-
})
|
|
150
|
+
}).toString()
|
|
151
151
|
});
|
|
152
152
|
const body = await res.json();
|
|
153
153
|
if (!res.ok || !body.access_token) {
|
|
@@ -269,14 +269,14 @@ var MymeAuth = class {
|
|
|
269
269
|
}
|
|
270
270
|
const res = await this.fetch(`${this.issuer}/auth/token`, {
|
|
271
271
|
method: "POST",
|
|
272
|
-
headers: { "Content-Type": "application/
|
|
273
|
-
body:
|
|
272
|
+
headers: { "Content-Type": "application/x-www-form-urlencoded" },
|
|
273
|
+
body: new URLSearchParams({
|
|
274
274
|
grant_type: "authorization_code",
|
|
275
275
|
code,
|
|
276
276
|
code_verifier: pending.verifier,
|
|
277
277
|
redirect_uri: pending.redirectUri,
|
|
278
278
|
client_id: this.clientId
|
|
279
|
-
})
|
|
279
|
+
}).toString()
|
|
280
280
|
});
|
|
281
281
|
const body = await res.json();
|
|
282
282
|
if (!res.ok || !body.access_token || !body.refresh_token) {
|
package/dist/index.d.ts
CHANGED
|
@@ -524,7 +524,7 @@ declare class MymeClient {
|
|
|
524
524
|
readonly keys: {
|
|
525
525
|
/** Creates an API key. The raw key value is returned exactly once on
|
|
526
526
|
* creation; the rest of the shape mirrors the persisted ApiKey record
|
|
527
|
-
* (source,
|
|
527
|
+
* (source, default_tier, type_permissions, and
|
|
528
528
|
* extension_permissions are all stamped at create time and visible
|
|
529
529
|
* here so the caller doesn't need a follow-up GET /keys to inspect
|
|
530
530
|
* them). */
|
package/dist/index.js
CHANGED
|
@@ -818,7 +818,7 @@ var MymeClient = class {
|
|
|
818
818
|
keys = {
|
|
819
819
|
/** Creates an API key. The raw key value is returned exactly once on
|
|
820
820
|
* creation; the rest of the shape mirrors the persisted ApiKey record
|
|
821
|
-
* (source,
|
|
821
|
+
* (source, default_tier, type_permissions, and
|
|
822
822
|
* extension_permissions are all stamped at create time and visible
|
|
823
823
|
* here so the caller doesn't need a follow-up GET /keys to inspect
|
|
824
824
|
* them). */
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mymehq/sdk",
|
|
3
|
-
"version": "
|
|
3
|
+
"version": "5.0.0",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"publishConfig": {
|
|
6
6
|
"registry": "https://registry.npmjs.org",
|
|
@@ -20,7 +20,7 @@
|
|
|
20
20
|
"dist"
|
|
21
21
|
],
|
|
22
22
|
"dependencies": {
|
|
23
|
-
"@mymehq/shared": "
|
|
23
|
+
"@mymehq/shared": "5.0.0"
|
|
24
24
|
},
|
|
25
25
|
"devDependencies": {
|
|
26
26
|
"@types/node": "^22.0.0",
|