@cedarjs/api-server 5.0.5-rc.3 → 5.0.5-rc.5

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/bin.js CHANGED
@@ -584,7 +584,10 @@ async function redwoodFastifyGraphQLServer(fastify2, options) {
584
584
  handler: async (req, reply) => {
585
585
  const request = createFetchRequest(req, reply);
586
586
  const cedarContext = await buildCedarContext2(request, {
587
- authDecoder: graphqlOptions.authDecoder
587
+ authDecoder: graphqlOptions.authDecoder,
588
+ // Has to happen before Yoga reads the request body, so it can't be
589
+ // left to `useRedwoodAuthContext`'s fallback
590
+ withAuthState: true
588
591
  });
589
592
  try {
590
593
  return await yoga.handle(request, {
package/dist/cjs/bin.js CHANGED
@@ -598,7 +598,10 @@ async function redwoodFastifyGraphQLServer(fastify2, options) {
598
598
  handler: async (req, reply) => {
599
599
  const request = createFetchRequest(req, reply);
600
600
  const cedarContext = await (0, import_runtime2.buildCedarContext)(request, {
601
- authDecoder: graphqlOptions.authDecoder
601
+ authDecoder: graphqlOptions.authDecoder,
602
+ // Has to happen before Yoga reads the request body, so it can't be
603
+ // left to `useRedwoodAuthContext`'s fallback
604
+ withAuthState: true
602
605
  });
603
606
  try {
604
607
  return await yoga.handle(request, {
@@ -1 +1 @@
1
- {"version":3,"file":"graphql.d.ts","sourceRoot":"","sources":["../../../src/plugins/graphql.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EACV,eAAe,EAIhB,MAAM,SAAS,CAAA;AAOhB,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAKjE,MAAM,WAAW,4BAA4B;IAC3C,OAAO,EAAE;QACP,WAAW,CAAC,EAAE,MAAM,CAAA;QACpB,OAAO,CAAC,EAAE,kBAAkB,CAAA;KAC7B,CAAA;CACF;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,eAAe,EACxB,OAAO,EAAE,4BAA4B,iBAuHtC"}
1
+ {"version":3,"file":"graphql.d.ts","sourceRoot":"","sources":["../../../src/plugins/graphql.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EACV,eAAe,EAIhB,MAAM,SAAS,CAAA;AAOhB,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAKjE,MAAM,WAAW,4BAA4B;IAC3C,OAAO,EAAE;QACP,WAAW,CAAC,EAAE,MAAM,CAAA;QACpB,OAAO,CAAC,EAAE,kBAAkB,CAAA;KAC7B,CAAA;CACF;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,eAAe,EACxB,OAAO,EAAE,4BAA4B,iBA0HtC"}
@@ -78,7 +78,10 @@ async function redwoodFastifyGraphQLServer(fastify, options) {
78
78
  handler: async (req, reply) => {
79
79
  const request = createFetchRequest(req, reply);
80
80
  const cedarContext = await (0, import_runtime.buildCedarContext)(request, {
81
- authDecoder: graphqlOptions.authDecoder
81
+ authDecoder: graphqlOptions.authDecoder,
82
+ // Has to happen before Yoga reads the request body, so it can't be
83
+ // left to `useRedwoodAuthContext`'s fallback
84
+ withAuthState: true
82
85
  });
83
86
  try {
84
87
  return await yoga.handle(request, {
@@ -1 +1 @@
1
- {"version":3,"file":"graphql.d.ts","sourceRoot":"","sources":["../../src/plugins/graphql.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EACV,eAAe,EAIhB,MAAM,SAAS,CAAA;AAOhB,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAKjE,MAAM,WAAW,4BAA4B;IAC3C,OAAO,EAAE;QACP,WAAW,CAAC,EAAE,MAAM,CAAA;QACpB,OAAO,CAAC,EAAE,kBAAkB,CAAA;KAC7B,CAAA;CACF;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,eAAe,EACxB,OAAO,EAAE,4BAA4B,iBAuHtC"}
1
+ {"version":3,"file":"graphql.d.ts","sourceRoot":"","sources":["../../src/plugins/graphql.ts"],"names":[],"mappings":"AAKA,OAAO,KAAK,EACV,eAAe,EAIhB,MAAM,SAAS,CAAA;AAOhB,OAAO,KAAK,EAAE,kBAAkB,EAAE,MAAM,yBAAyB,CAAA;AAKjE,MAAM,WAAW,4BAA4B;IAC3C,OAAO,EAAE;QACP,WAAW,CAAC,EAAE,MAAM,CAAA;QACpB,OAAO,CAAC,EAAE,kBAAkB,CAAA;KAC7B,CAAA;CACF;AAED,wBAAsB,2BAA2B,CAC/C,OAAO,EAAE,eAAe,EACxB,OAAO,EAAE,4BAA4B,iBA0HtC"}
@@ -45,7 +45,10 @@ async function redwoodFastifyGraphQLServer(fastify, options) {
45
45
  handler: async (req, reply) => {
46
46
  const request = createFetchRequest(req, reply);
47
47
  const cedarContext = await buildCedarContext(request, {
48
- authDecoder: graphqlOptions.authDecoder
48
+ authDecoder: graphqlOptions.authDecoder,
49
+ // Has to happen before Yoga reads the request body, so it can't be
50
+ // left to `useRedwoodAuthContext`'s fallback
51
+ withAuthState: true
49
52
  });
50
53
  try {
51
54
  return await yoga.handle(request, {
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cedarjs/api-server",
3
- "version": "5.0.5-rc.3",
3
+ "version": "5.0.5-rc.5",
4
4
  "description": "CedarJS's HTTP server for Serverless Functions",
5
5
  "repository": {
6
6
  "type": "git",
@@ -133,11 +133,11 @@
133
133
  "test:watch": "vitest watch"
134
134
  },
135
135
  "dependencies": {
136
- "@cedarjs/context": "5.0.5-rc.3",
137
- "@cedarjs/fastify-web": "5.0.5-rc.3",
138
- "@cedarjs/internal": "5.0.5-rc.3",
139
- "@cedarjs/project-config": "5.0.5-rc.3",
140
- "@cedarjs/web-server": "5.0.5-rc.3",
136
+ "@cedarjs/context": "5.0.5-rc.5",
137
+ "@cedarjs/fastify-web": "5.0.5-rc.5",
138
+ "@cedarjs/internal": "5.0.5-rc.5",
139
+ "@cedarjs/project-config": "5.0.5-rc.5",
140
+ "@cedarjs/web-server": "5.0.5-rc.5",
141
141
  "@fastify/multipart": "9.4.0",
142
142
  "@fastify/url-data": "6.0.3",
143
143
  "ansis": "4.2.0",
@@ -155,7 +155,7 @@
155
155
  "yargs": "17.7.3"
156
156
  },
157
157
  "devDependencies": {
158
- "@cedarjs/framework-tools": "5.0.5-rc.3",
158
+ "@cedarjs/framework-tools": "5.0.5-rc.5",
159
159
  "@types/aws-lambda": "8.10.162",
160
160
  "@types/dotenv-defaults": "^5.0.0",
161
161
  "@types/split2": "4.2.3",
@@ -169,7 +169,7 @@
169
169
  "vitest": "3.2.6"
170
170
  },
171
171
  "peerDependencies": {
172
- "@cedarjs/graphql-server": "5.0.5-rc.3"
172
+ "@cedarjs/graphql-server": "5.0.5-rc.5"
173
173
  },
174
174
  "peerDependenciesMeta": {
175
175
  "@cedarjs/graphql-server": {