Skip to main content

GPT4

Query the /gpt4 endpoint for GPT4 models. These models are used when there is a complex instruction in the prompt or a difficult problem to be solved.

Notice here that you have to include the type key that can be equal to prompt or completion.

Making the request

Endpoint: /gpt4

Method: POST

Request body:

{"model": "model_name", "content": "your_content_here", "type": "completion/prompt"}

Example:

import requests
headers = {"X-API-KEY": "4088bbb2b9a34d75944e03810bbbe763"}
data = {"model": "text-curie-001", "content": "Hey there from AiPrice.dev!", "type": "usage"}
content = requests.post("https://api.aiprice.dev/gpt4", json=data, headers=headers)
print(content.json())