Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add third-party relay #2

Open
Dough-su opened this issue Dec 7, 2023 · 5 comments
Open

Add third-party relay #2

Dough-su opened this issue Dec 7, 2023 · 5 comments
Labels
enhancement New feature or request good first issue Good for newcomers

Comments

@Dough-su
Copy link

Dough-su commented Dec 7, 2023

Is it possible to customize the relay function to help those users who don't have the official api?
For example:
The official api is: api.openai.com
The third-party api is a different address, you just need to replace it with another one.

@davidmigloz
Copy link
Owner

Good one, I can do that.

In your case, would the third-party api require some kind of authentication?

@Dough-su
Copy link
Author

Dough-su commented Dec 7, 2023

Good one, I can do that.

In your case, would the third-party api require some kind of authentication?

It is the same as openai official, the only difference is the url address,The authentication method is the same as the official one, but the transfer station provides their own API key,Currently many transfers are using https://github.com/songquanpeng/one-api/blob/main/README.en.md

@davidmigloz
Copy link
Owner

ah you meant using one-api gotcha. I can add some fields to add custom headers or query params as well in case you want to use a proxy that requires them.

@Dough-su
Copy link
Author

Dough-su commented Dec 7, 2023

ah you meant using one-api gotcha. I can add some fields to add custom headers or query params as well in case you want to use a proxy that requires them.

Yes, there are many Chinese users who cannot directly access the official API of OpenAI. They need additional relays to help them use it. Thank you.

@davidmigloz
Copy link
Owner

Awesome, I'll try to implement it in the following days.

@davidmigloz davidmigloz added enhancement New feature or request good first issue Good for newcomers labels Jan 4, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request good first issue Good for newcomers
Projects
None yet
Development

No branches or pull requests

2 participants