Stable Diffusion
    Stable Diffusion
    • Stable Diffusion API 文档
    • A1111 调度程序
    • Stable Diffusion API
      • 概述
      • 文本到图像
        POST
      • 图像到图像
        POST
      • 修复
        POST
      • 获取排队图像
        POST
      • 系统负载
        POST
    • 训练模型
      • 概述
      • Lora 模型
        POST
      • Dreambooth 模型 (V2)
        POST
      • Dreambooth 模型
        POST
      • 训练状态
        POST
      • 获取模型列表
        POST
      • 删除训练
        POST
      • 取消训练
        POST
      • 裁剪 Base64 图像
        POST
    • 文字转视频
      • 概述
      • 创建视频
        POST
      • 将文本训练为视频
        POST
    • 社区模型 API V4
      • 概述
      • 文本转图像
        POST
      • LoRA
        POST
      • LoRA 多功能设备
        POST
      • 图像到图像
        POST
      • 修复
        POST
      • 获取排队图像接口
        POST
      • 重新加载模型接口
        POST
    • 管理信息系统
      • 概述
      • 裁剪 Base64 图像
      • 删除图像
      • 获取训练过的模型列表
      • 获取公共型号列表
      • 清除用户缓存
      • 购买 Dreambooth 模型
      • 购买订阅计划
      • 取消订阅计划
      • NSFW 图像检查
      • 上传模型
      • 创建房间内部接口
    • 控制网
      • 概述
      • ControlNet 主要终端
      • ControlNet 多功能终端
    • 企业计划
      • 概述
      • 系统详情
      • 重新启动服务器终端
      • 更新服务器
      • 更新 S3 详细信息
      • 清楚缓存
      • 列表调度程序
      • 负载模型
      • 验证模型
      • 获取所有模型
      • 删除模型
      • Controlnet
      • 文字转图像
      • 文字转视频
      • 图像到图像
      • 修复
      • 超分辨率
      • 上传图片
      • 同步模型
      • 负载 Vae
      • NSFW 图像检查
      • 获取排队图像
    • Dreambooth 沙盒
      • 概述
      • 创建 Dreambooth 请求(沙盒)
      • 获取训练状态(沙盒)
    • 图像编辑
      • 概述
      • 外部绘画
      • Blip 扩散
      • 魔术混合接口
      • 图像深度
      • 图像混合器
      • 图像引导编辑
      • 删除背景
      • 超分辨率
      • 混合画布
    • 文本转 3D
      • 概述
      • 文本转 3D
      • 图像转 3D
    • 未经审查的聊天
      POST

      未经审查的聊天

      开发环境
      https://stablediffusionapi.com/v1
      开发环境
      https://stablediffusionapi.com/v1
      POST
      https://stablediffusionapi.com/api/v5/uncensored_chat
      POST向https://stablediffusionapi.com/api/v5/uncensored_chat端点发送请求,并将 api 的响应附加到请求中。
      调用端点后,示例响应如下所示;
      身体原料
      {
          "status": "success",
          "message": "Here is an example of a PHP function that makes an API call using the cURL extension:\n
                      \nfunction make_api_call($url, $data = []) {\n    $ch = curl_init();\n    curl_setopt($ch, CURLOPT_URL, $url);\n    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n    curl_setopt($ch, CURLOPT_POST, true);\n    curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));\n    curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);\n    $response = curl_exec($ch);\n    curl_close($ch);\n    return $response;\n}\n",
          "meta": {
              "messages": [
                  {
                      "role": "user",
                      "content": "write php function to make api call"
                  }
              ],
              "max_tokens": 1000,
              "temperature": 1,
              "top_p": 1,
              "presence_penalty": 0,
              "frequency_penalty": 0,
              "track_id": null,
              "webhook": null
          }
      }
      role要继续下一个 API 调用,请将属性和的对象附加content到消息数组中,其中role值为assistant,值为上一次content调用的响应。message之后,附加具有相同属性的另一个对象,并将role值作为用户传递,并将content值作为新描述传递以继续聊天。请求看起来像这样;
      身体原料
      {
      "key": "",
      "messages": [
              {
                  "role": "user",
                  "content": "write php function to make api call"
              },
              {
                  "role":"assistant",
                  "content":"Here is an example of a PHP function that makes an API call using the cURL extension:\n
                      \nfunction make_api_call($url, $data = []) {\n    $ch = curl_init();\n    curl_setopt($ch, CURLOPT_URL, $url);\n    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n    curl_setopt($ch, CURLOPT_POST, true);\n    curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));\n    curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);\n    $response = curl_exec($ch);\n    curl_close($ch);\n    return $response;\n}\n"
              },
              {
                  "role": "user",
                  "content": "write function to make api call to openai"
              },
      
          ],
      "max_tokens": 1000
      }
      上述请求的响应如下所示
      身体原料
      {
          "status": "success",
          "message": " Here is an example of a PHP function that makes an API call to OpenAI using the curl_ext extension:\n
          \nfunction make_openai_api_call($endpoint, $params) {\n    $ch = curl_init();\n    curl_setopt($ch, CURLOPT_URL, $endpoint);\n    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n    curl_setopt($ch, CURLOPT_SSL_VERIFYPEER, false);\n    curl_setopt($ch, CURLOPT_SSL_VERIFYHOST, 2);\n    curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);\n    curl_setopt($ch, CURLOPT_POST, true);\n    curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($params));\n    $response = curl_exec($ch);\n    curl_close($ch);\n    return $response;\n}\n",
          "meta": {
              "messages": [
                  {
                      "role": "user",
                      "content": "write php function to make api call"
                  },
                  {
                      "role": "assistant",
                      "content": "Here is an example of a PHP function that makes an API call using the cURL extension:\n
                        \nfunction make_api_call($url, $data = []) {\n    $ch = curl_init();\n    curl_setopt($ch, CURLOPT_URL, $url);\n    curl_setopt($ch, CURLOPT_RETURNTRANSFER, true);\n    curl_setopt($ch, CURLOPT_POST, true);\n    curl_setopt($ch, CURLOPT_POSTFIELDS, json_encode($data));\n    curl_setopt($ch, CURLOPT_HTTPHEADER, ['Content-Type: application/json']);\n    $response = curl_exec($ch);\n    curl_close($ch);\n    return $response;\n}\n
                        "
                  },
                  {
                      "role": "user",
                      "content": "write function to make api call to openai"
                  }
              ],
              "max_tokens": 1000,
              "temperature": 1,
              "top_p": 1,
              "presence_penalty": 0,
              "frequency_penalty": 0,
              "track_id": null,
              "webhook": null
          }
      }
      尽可能多次重复该过程,直到您对结果满意为止
      使用的型号是 Mistral 7B Instruct-v0.1
      请求示例请求示例
      Shell
      JavaScript
      Java
      Swift
      curl --location --request POST 'https://stablediffusionapi.com/api/v5/uncensored_chat' \
      --header 'Content-Type: application/json' \
      --data-raw '{
      "key": "",
      "messages": [
              {
                  "role": "user",
                  "content": "write php function to make api call"
              },
          ],
      "max_tokens": 1000
      }'
      响应示例响应示例
      {
        "status": "string",
        "message": "string"
      }

      请求参数

      Body 参数application/json
      key
      string 
      必需
      您用于请求授权的 API Key
      messages
      array [object {2}] 
      必需
      它接受角色 和内容密钥。角色接受或的值,同时内容接受聊天描述userassistant
      role
      string 
      可选
      content
      string 
      可选
      max_tokens
      integer 
      最大token数量
      必需
      示例

      返回响应

      🟢200成功
      application/json
      Body
      status
      string 
      必需
      message
      string 
      必需
      上一页
      图像转 3D
      Built with