@better-auth/oauth-provider 1.5.0-beta.7 → 1.5.0-beta.8
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.mjs +10 -10
- package/package.json +5 -5
package/dist/index.mjs
CHANGED
|
@@ -1524,9 +1524,9 @@ const SafeUrlSchema = z.url().superRefine((val, ctx) => {
|
|
|
1524
1524
|
async function getClientEndpoint(ctx, opts) {
|
|
1525
1525
|
const session = await getSessionFromCtx(ctx);
|
|
1526
1526
|
if (!session) throw new APIError$1("UNAUTHORIZED");
|
|
1527
|
-
if (!ctx.
|
|
1527
|
+
if (!ctx.headers) throw new APIError$1("BAD_REQUEST");
|
|
1528
1528
|
if (opts.clientPrivileges && !await opts.clientPrivileges({
|
|
1529
|
-
headers: ctx.
|
|
1529
|
+
headers: ctx.headers,
|
|
1530
1530
|
action: "read",
|
|
1531
1531
|
session: session.session,
|
|
1532
1532
|
user: session.user
|
|
@@ -1572,9 +1572,9 @@ async function getClientPublicEndpoint(ctx, opts) {
|
|
|
1572
1572
|
async function getClientsEndpoint(ctx, opts) {
|
|
1573
1573
|
const session = await getSessionFromCtx(ctx);
|
|
1574
1574
|
if (!session) throw new APIError$1("UNAUTHORIZED");
|
|
1575
|
-
if (!ctx.
|
|
1575
|
+
if (!ctx.headers) throw new APIError$1("BAD_REQUEST");
|
|
1576
1576
|
if (opts.clientPrivileges && !await opts.clientPrivileges({
|
|
1577
|
-
headers: ctx.
|
|
1577
|
+
headers: ctx.headers,
|
|
1578
1578
|
action: "list",
|
|
1579
1579
|
session: session.session,
|
|
1580
1580
|
user: session.user
|
|
@@ -1613,9 +1613,9 @@ async function getClientsEndpoint(ctx, opts) {
|
|
|
1613
1613
|
async function deleteClientEndpoint(ctx, opts) {
|
|
1614
1614
|
const session = await getSessionFromCtx(ctx);
|
|
1615
1615
|
if (!session) throw new APIError$1("UNAUTHORIZED");
|
|
1616
|
-
if (!ctx.
|
|
1616
|
+
if (!ctx.headers) throw new APIError$1("BAD_REQUEST");
|
|
1617
1617
|
if (opts.clientPrivileges && !await opts.clientPrivileges({
|
|
1618
|
-
headers: ctx.
|
|
1618
|
+
headers: ctx.headers,
|
|
1619
1619
|
action: "delete",
|
|
1620
1620
|
session: session.session,
|
|
1621
1621
|
user: session.user
|
|
@@ -1646,9 +1646,9 @@ async function deleteClientEndpoint(ctx, opts) {
|
|
|
1646
1646
|
async function updateClientEndpoint(ctx, opts) {
|
|
1647
1647
|
const session = await getSessionFromCtx(ctx);
|
|
1648
1648
|
if (!session) throw new APIError$1("UNAUTHORIZED");
|
|
1649
|
-
if (!ctx.
|
|
1649
|
+
if (!ctx.headers) throw new APIError$1("BAD_REQUEST");
|
|
1650
1650
|
if (opts.clientPrivileges && !await opts.clientPrivileges({
|
|
1651
|
-
headers: ctx.
|
|
1651
|
+
headers: ctx.headers,
|
|
1652
1652
|
action: "update",
|
|
1653
1653
|
session: session.session,
|
|
1654
1654
|
user: session.user
|
|
@@ -1697,9 +1697,9 @@ async function updateClientEndpoint(ctx, opts) {
|
|
|
1697
1697
|
async function rotateClientSecretEndpoint(ctx, opts) {
|
|
1698
1698
|
const session = await getSessionFromCtx(ctx);
|
|
1699
1699
|
if (!session) throw new APIError$1("UNAUTHORIZED");
|
|
1700
|
-
if (!ctx.
|
|
1700
|
+
if (!ctx.headers) throw new APIError$1("BAD_REQUEST");
|
|
1701
1701
|
if (opts.clientPrivileges && !await opts.clientPrivileges({
|
|
1702
|
-
headers: ctx.
|
|
1702
|
+
headers: ctx.headers,
|
|
1703
1703
|
action: "rotate",
|
|
1704
1704
|
session: session.session,
|
|
1705
1705
|
user: session.user
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@better-auth/oauth-provider",
|
|
3
|
-
"version": "1.5.0-beta.
|
|
3
|
+
"version": "1.5.0-beta.8",
|
|
4
4
|
"type": "module",
|
|
5
5
|
"description": "An oauth provider plugin for Better Auth",
|
|
6
6
|
"main": "dist/index.mjs",
|
|
@@ -42,8 +42,8 @@
|
|
|
42
42
|
"@modelcontextprotocol/sdk": "^1.25.2",
|
|
43
43
|
"listhen": "^1.9.0",
|
|
44
44
|
"tsdown": "^0.19.0",
|
|
45
|
-
"better-auth": "1.5.0-beta.
|
|
46
|
-
"
|
|
45
|
+
"@better-auth/core": "1.5.0-beta.8",
|
|
46
|
+
"better-auth": "1.5.0-beta.8"
|
|
47
47
|
},
|
|
48
48
|
"dependencies": {
|
|
49
49
|
"jose": "^6.1.0",
|
|
@@ -53,8 +53,8 @@
|
|
|
53
53
|
"@better-auth/utils": "0.3.0",
|
|
54
54
|
"@better-fetch/fetch": "1.1.21",
|
|
55
55
|
"better-call": "1.1.8",
|
|
56
|
-
"@better-auth/core": "1.5.0-beta.
|
|
57
|
-
"better-auth": "1.5.0-beta.
|
|
56
|
+
"@better-auth/core": "1.5.0-beta.8",
|
|
57
|
+
"better-auth": "1.5.0-beta.8"
|
|
58
58
|
},
|
|
59
59
|
"files": [
|
|
60
60
|
"dist"
|