ai 5.0.108 → 5.0.109

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/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # ai
2
2
 
3
+ ## 5.0.109
4
+
5
+ ### Patch Changes
6
+
7
+ - 427547a: Improve ai gateway error message when api key is not present
8
+
3
9
  ## 5.0.108
4
10
 
5
11
  ### Patch Changes
package/dist/index.js CHANGED
@@ -777,7 +777,7 @@ function detectMediaType({
777
777
  var import_provider_utils2 = require("@ai-sdk/provider-utils");
778
778
 
779
779
  // src/version.ts
780
- var VERSION = true ? "5.0.108" : "0.0.0-test";
780
+ var VERSION = true ? "5.0.109" : "0.0.0-test";
781
781
 
782
782
  // src/util/download/download.ts
783
783
  var download = async ({ url }) => {
@@ -1499,7 +1499,7 @@ function wrapGatewayError(error) {
1499
1499
  if (import_gateway2.GatewayAuthenticationError.isInstance(error) || import_gateway2.GatewayModelNotFoundError.isInstance(error)) {
1500
1500
  return new import_provider20.AISDKError({
1501
1501
  name: "GatewayError",
1502
- message: "Vercel AI Gateway access failed. If you want to use AI SDK providers directly, use the providers, e.g. @ai-sdk/openai, or register a different global default provider.",
1502
+ message: "Unauthenticated. Configure AI_GATEWAY_API_KEY or configure and use a provider module. Learn more: https://vercel.link/unauthenticated-ai-gateway",
1503
1503
  cause: error
1504
1504
  });
1505
1505
  }