Skip to content

Conversation

@zeke
Copy link
Contributor

@zeke zeke commented Oct 29, 2025

This PR fixes two issues in the AI Gateway documentation for Replicate:

  1. Authorization header: Changes from Authorization: Token r8_... to Authorization: Bearer r8_..., which is the correct format that actually works. The old format works, but is deprecated.
  2. Missing version field: Adds the required version field to the request body with anthropic/claude-4.5-haiku as an example.

These corrections were discovered through hands-on testing with the Cloudflare AI Gateway and Replicate API.

A working example repository is available at https://github.com/replicate/cloudflare-ai-gateway-replicate-test

- Change Authorization header from 'Token' to 'Bearer' prefix
- Add version field to request body with anthropic/claude-4.5-haiku example
- These changes reflect the actual working implementation
@github-actions github-actions bot added October 2025 product:ai-gateway AI Gateway: https://developers.cloudflare.com/ai-gateway/ labels Oct 29, 2025
@zeke zeke changed the title fix: update Replicate example to use Bearer auth and include version fix: update AI Gateway docs for Replicate provider Oct 29, 2025
@palashgo palashgo enabled auto-merge (squash) October 29, 2025 17:37
@palashgo palashgo merged commit 6dd7a72 into cloudflare:production Oct 29, 2025
2 checks passed
@workers-devprod workers-devprod added the contribution [Holopin] Recognizes a docs contribution, big or small label Oct 29, 2025
@holopin-bot
Copy link

holopin-bot bot commented Oct 29, 2025

Congratulations @zeke, the maintainer of this repository has issued you a holobyte! Here it is: https://holopin.io/holobyte/cmhcaldkg008zjm04m61i7lvd

This badge can only be claimed by you, so make sure that your GitHub account is linked to your Holopin account. You can manage those preferences here: https://holopin.io/account.
Or if you're new to Holopin, you can simply sign up with GitHub, which will do the trick!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

contribution [Holopin] Recognizes a docs contribution, big or small October 2025 product:ai-gateway AI Gateway: https://developers.cloudflare.com/ai-gateway/ size/xs

Projects

None yet

Development

Successfully merging this pull request may close these issues.

8 participants