Postman请求Azure的OpenAI

界面是:

 AZURE_OPENAI_ENDPOINT/openai/deployments/deployment_name/chat/completions?api-version=2023-05-15

注意Body下的raw选json格式

 

{
    "messages": [
        {
            "role": "system",
            "content": "You are a helpful assistant."
        },
        {
            "role": "user",
            "content": "Does Azure OpenAI support customer managed keys?"
        },
        {
            "role": "assistant",
            "content": "Yes, customer managed keys are supported by Azure OpenAI."
        },
        {
            "role": "user",
            "content": "Do other Azure Cognitive Services support this too?"
        },
          {
            "role": "user",
            "content": "Do you know capital of china?"
        }
    ]
}

头文件:

 返回结果:

 

posted @ 2023-05-31 12:27  有翅膀的大象  阅读(525)  评论(0)    收藏  举报