OhMyGPT API
English
  • 中文
  • English
  • 日本語
OhMyGPT
OhMyGPT
English
  • 中文
  • English
  • 日本語
    • Introduction to this site
    • Change log
    • OpenAI
      • Responses
        • Create model response
        • Get model response
        • Delete model response
        • Cancel response
        • List input items
      • Conversations
        • create conversation
        • Retrieve conversation
        • update conversation
        • delete conversation
        • Create items
        • list items
        • Retrieve item
        • Delete item
      • create completion
        POST
      • TTS text to speech
        POST
      • Embeddings
        POST
      • image generation
        POST
      • image editing
        POST
    • Store
      • List chat completions
        POST
      • Get chat completed
        POST
      • Deletion of chat completed
        POST
    • Claude
      • Anthropic native Completions enterprise commercial API
        POST
      • Anthropic native Messages API
        POST
      • Anthropic native Messages Token Count API
        POST
    • OAuth开放API
      • Introduction to Open OAuth API
      • User authorization page
        GET
      • Code display page
        GET
      • Apply for access_token
        POST
      • Read basic user information
        POST
      • Read user balance information
        POST
      • Charge user fees
        POST
      • Create a Stripe Checkout recharge order for the user
        POST
      • Create a Stripe Invoice recharge order for the user
        POST
      • Call other open APIs
        POST
      • Read user management token through OAuth Token
        POST
      • Update user management token through OAuth Token
        POST
    • other
      • search
        • Google Custom Search API
        • Google Search By Serper
      • Azure
        • Azure text-to-speech
        • Azure gets TTS voice list
    • Override rules
      • Create rules
      • Update rules
      • delete rule
      • Get rules
      • list rules
      • Batch enable/disable
      • Copy rules
      • test rules
      • Get statistics
      • Get restriction configuration
      • Check rule name
      • Batch delete
      • Export rules
      • Import rules
    • image generation
      • other
        • ND image generation API
      • Flux
        • Flux Schnell image generation
        • Flux Dev image generation
        • Flux Pro image generation
        • Flux Pro 1.1 image generation
        • Flux 1.1 Pro Ultura image generation
    • Storage service
      • File storage service
      • File upload
      • File information update
      • Delete files
      • User query (pagination)
      • User metadata query (by fileUinqueIds)
      • File download interface (Public file download)
      • File download interface (Private private file download)
      • Obtain public file metadata
    • API KEY management
      • Create new API Key
      • Modify API Key information
      • Query all API Keys of the user
      • Delete the specified API Key
      • Interface for querying user membership expiration date
      • User balance query interface
      • Query the current model magnification interface
    • Archive documents
      • Self-service invoicing system usage documentation
      • Telegram Bot usage documentation
      • Self-built Cloudflare Worker anti-generation tutorial
      • Claude Code forwarding service
      • CodeX forwarding service
      • Introduction to the new website
    • Model list
      GET

    Introduction to this site

    About this site#

    This site provides a variety of currently popular and powerful generative AI services.
    New website: https://www.ohmygpt.com
    New website mirror URL: https://www.wisegpt.top
    Old version mirror URL:
    https://x.dogenet.win
    https://www.aigptx.top
    Here is the public API document of this site. You can check the API document here for development and debugging.
    OpenAI's Audio, Chat, Completions, Embeddings, Images, and Moderations interfaces are all supported. The paths and parameters are consistent with those of OpenAI. Here are only some platform-customized and public API documents. For specific OpenAI compatible interfaces, please refer to the official documentation: https://platform.openai.com/docs/api-reference
    In actual use, you only need to select one of the API endpoints below as the base URL, replace https://api.openai.com, or splice the path in the document later.
    API endpoint list:
    Direct connection to the US main site stable, recommended for local calls in the US, not available in mainland China: https://api.ohmygpt.com
    Cloudflare Pro CDN stable, fast CDN, recommended for non-US regions, global acceleration (not available in mainland China): https://apic.ohmygpt.com
    Mainland optimized CDN: recommended calls in mainland China, stable: https://c-z0-api-01.hash070.com
    High-quality line reverse generation 1 High-quality line: https://www.aigptx.top
    High-quality line reverse generation 2 High-quality line: https://cn2us02.opapi.win
    Note:
    **Since the server is located in the United States, network optimization in other parts of the world may not be ideal. Therefore, when your calling location is far from the United States (such as Hong Kong and Singapore in Asia), it is recommended to connect through Cloudflare CDN or anti-generation API endpoints. **
    When you use a non-streaming request interface, it is recommended to use direct connection or reverse generation endpoints, because the response timeout limit of direct connection and reverse generation endpoints is relatively loose, and Cloudflare's timeout limit is 100s. If it exceeds the timeout limit, your connection with the server will be disconnected.
    When using streaming API calls, you will not be affected by this limitation of Cloudflare.

    How to use multi-modal model with image input?#

    vision#
    Although the chat embedded in the website does not provide the Vision function, you can use the open API provided by this website to cooperate with third-party open source/closed source software calls

    LobeChat#

    LobeChat instance hosted on this site: https://lobe.dogenet.win
    Click the link to enter the website, then click Settings in the lower right corner
    Configure as shown below:
    1710034330061.png
    in
    API Key Fill in the API Key you generated in the "Settings" of this site
    API Proxy Address Fill in https://api.ohmygpt.com/v1
    Custome Model Name: Can fill in the model of Claude series claude-3-opus,claude-3-sonnet
    Then you can start using it:
    Multi-modal models (such as GPT4V, GeminiProV, Claude3, etc.) support image input, with the following effects:
    1710034563396.png
    1710034605156.png
    If you encounter a 401 error, it is usually because your account is in arrears or the key does not have the corresponding model permissions checked. Please check your account balance or update the key's permission list, or create a new key and try again.

    BotGem(AMA)#

    image.png

    Can I use my own openai key directly on this site?#

    No, this site does not support users uploading their own Keys

    How do I use the services of this site in chatGPT-next-web?#

    img

    How do I use the services of this site in GPT academic optimization?#

    1.Ready-made:
    This example is for the host of this site. Simply fill in the APIKey you generated in the site settings and use 0:
    https://ga.dogenet.win
    2.Self-deployment:
    Before use, make two modifications to config.py:
    1.
    Modify API_KEY in line 11 of config.py to be your own KEY on this site
    2.
    Modify the API_URL_REDIRECT value in line 38 of config.py to {"https://api.openai.com/v1/chat/completions": "https://aigptx.top/v1/chat/completions"}

    How do I use the Claude2 service of this site in GPT academic optimization?#

    First of all, please make sure you need to use the Claude2 service. Secondly, using Claude2 of this site in GPT academic optimization requires more configuration and is more complicated.
    Modify as follows:
    1.
    Modify API_KEY in line 11 of config.py to be your own KEY on this site
    2.
    Modify the API_URL_REDIRECT value in line 38 of config.py to {"https://api.openai.com/v1/chat/completions": "https://aigptx.top/v1/chat/completions"}
    3.
    Add model "claude-2-web" to AVAIL_LLM_MODELS in line 73 of config.py
    4.
    In line 622 of toolbox.py, modify the code to:
    Please note the indentation
    5.
    Add a key-value pair to the model_info variable in request_llm/bridge_all.py:
    Then you can use the claude2 model. Select claude-2-web in the web to use it.

    About members and GPT4#

    As shown below, this site offers three packages: Free, VIP, and Premium.
    VIP and Premium can unlock API services for all models (including GPT4).

    How do I obtain permission to use GPT4?#

    You need to upgrade your package to VIP to obtain the usage rights of GPT4. This is the lowest cost method on this site and we recommend you to use it most.
    The way to upgrade to VIP is very simple. As long as you recharge 20 RMB on this site, you can get one month's VIP qualification; if you recharge 40 RMB, you can get six months' VIP qualification. As long as you recharge the specified amount, you can obtain VIP qualifications without paying for VIP qualifications.

    Is the VIP package a monthly package?#

    No, you will get tokens after recharging, which can be used to offset the consumption of each service. VIP qualification is a gift after you top up, and your token balance will not be deducted for obtaining VIP qualification.

    My VIP qualification has expired after recharging 20 yuan. How long can I get VIP privileges by recharging another 20 yuan?#

    5 months.
    The images below can help you better understand our billing mechanism.
    pidPffS.png
    In this case, if your multiple payments have reached VIP conditions, then you will receive the corresponding length of VIP privileges starting from the time of your first payment.

    I cannot access OhMyGPT.com. Is the website service down?#

    The service of this site is very stable. You can check the specific running status:
    https://status.ohmygpt.com/status/main
    or
    https://status.aigptx.top/status/main
    The main reasons why you encounter this situation are DNS pollution and SNI blocking from GFW
    The solution is to open the ladder or use the mirror site of this site: https://aigptx.top
    Join the tg group to get the latest notifications in time: https://t.me/+SfPmr1psSNNhMzg1

    About cost consumption#

    How to calculate expense consumption?#

    Except for midjourney, the actual fee deducted by the system is: the official fee of the AI ​​service is calculated and multiplied by the current multiple.
    For example, if you now successfully request a GPT4 request worth 1 yuan according to the official pricing, this will be multiplied by the current corresponding service multiplier (for example, 0.5), then the actual fee that will be deducted is 1*0.5=0.5 yuan.

    What does each column in the bill table represent?#

    promptTokens model context length used for understanding
    completionTokens text length generated by the model
    RURT request upload time (unit: ms)
    TPS request time (unit: seconds)
    Free Whether this request consumes free quota

    What are promptTokens and completionTokens?#

    For language models, each word is converted from human language into a vector that the model can understand in the form of a "vocabulary", and each mapping corresponds to a token. In other words, token is the smallest unit for language models to understand text.
    At the same time, there are two steps in the interaction mode of the language model: receiving text and replying with a response. It can be simply understood that you need to ask questions to the model before the model will reply to you. Among them, the number of tokens in the question asked is promptTokens, and the text length of the reply is completeinoTokens.
    In addition, each language model has different pricing for promptToken and completionToken, so they need to be distinguished.

    Why are there so many promptTokens when using the web version?#

    The model does not have a memory similar to humans. If you need to associate this question with the previous question, you need to send the previous question content and the model's reply content to the model. This is the main reason why the promptTokens value becomes larger.
    If you need to save money, reducing the number of contexts in the advanced settings can effectively reduce the size of promptTokens per conversation.

    Why is there a system role in addition to users and models in the web version?#

    The system role corresponds to the system role in the OpenAI API, which is used to determine the role and functions the model plays in this session.
    If you need to save money by reducing context, system is the last context to be subtracted. For example:
    The context length is 0, the message sent in the request will only have your question
    The context length is 1, and the message sent in the request is system except for your question.
    The context length is greater than 1. In addition to your question and system, the message sent in the request is the most recent conversation to this conversation.
    Therefore, you can add some important information in this session to the system

    About API#

    You can connect various capabilities to your application through the open API of this site

    I am a newbie, can you give me a code example for calling the service?#

    When calling the OpenAI service, you can choose to use openai's official Python library, or you can choose to use the more general request library + API to access, both are available.
    The following sample code uses the service of this site to send a request, obtain the result in a non-streaming manner, and then print it on the console.
    First, you need to prepare your key
    修改于 2025-10-15 08:07:31
    下一页
    Change log
    Built with