opencode-pollinations-plugin 6.1.0-beta.6 → 6.1.0-beta.7

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.
@@ -656,10 +656,18 @@ export async function handleChatCompletion(req, res, bodyRaw) {
656
656
  if (authHeader)
657
657
  headers['Authorization'] = authHeader;
658
658
  // 5. Forward (Global Fetch with Retry)
659
+ // BEDROCK COMPATIBILITY: Apply transformation BEFORE first request
660
+ const isBedrockModel = actualModel.includes('nova') ||
661
+ actualModel.includes('amazon') ||
662
+ actualModel.includes('chickytutor');
663
+ const finalProxyBody = isBedrockModel ? sanitizeForBedrock(proxyBody) : proxyBody;
664
+ if (isBedrockModel) {
665
+ log(`[Proxy] Applied Bedrock shim for ${actualModel} (Initial Request)`);
666
+ }
659
667
  const fetchRes = await fetchWithRetry(targetUrl, {
660
668
  method: 'POST',
661
669
  headers: headers,
662
- body: JSON.stringify(proxyBody)
670
+ body: JSON.stringify(finalProxyBody)
663
671
  });
664
672
  res.statusCode = fetchRes.status;
665
673
  fetchRes.headers.forEach((val, key) => {
package/package.json CHANGED
@@ -1,7 +1,7 @@
1
1
  {
2
2
  "name": "opencode-pollinations-plugin",
3
3
  "displayName": "Pollinations AI (V5.6)",
4
- "version": "6.1.0-beta.6",
4
+ "version": "6.1.0-beta.7",
5
5
  "description": "Native Pollinations.ai Provider Plugin for OpenCode",
6
6
  "publisher": "pollinations",
7
7
  "repository": {