<ruby id="bdb3f"></ruby>

    <p id="bdb3f"><cite id="bdb3f"></cite></p>

      <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
        <p id="bdb3f"><cite id="bdb3f"></cite></p>

          <pre id="bdb3f"></pre>
          <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

          <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
          <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

          <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                <ruby id="bdb3f"></ruby>

                ??碼云GVP開源項目 12k star Uniapp+ElementUI 功能強大 支持多語言、二開方便! 廣告
                ## 個人中心 ### 首頁 在個人中心首頁可以看到當前你的消費統計和應用調用統計。 ![](https://img.kancloud.cn/74/4f/744f7abaab36ccfff16f2d2cda6bfff5_1920x937.png) ### 應用 創建應用之后會給當前應用分配一個應用秘鑰,用這個秘鑰就可以調用繪畫接口。 ![](https://img.kancloud.cn/e6/03/e603d66efe2c101df5c53948df6490a1_1920x937.png) 在首頁可以的頂部可以看到文檔地址,點擊進去后就可以根據文檔進行開發了。 ![](https://img.kancloud.cn/fd/43/fd4359e6901aad0840f019cee46bc3d6_1920x937.png) ### MJ機器人 如果你當前用戶有機器人托管權限,可以直接托管,然后進行調用。 ![](https://img.kancloud.cn/d9/b2/d9b2673f4f19358f4c3cf838c8019c0c_1920x937.png) ### 我的調用示例 這是我對接到GPT系統的調用示例,僅供參考。 ``` public function MidJourneyOpen($action = "U1", $image_id) { try { $index = 0; $base_url = $this->channels['base_url'] . "/app/ycMidjourney/api/imagine"; if ($action != "generate") { ## U 和 V操作 if (strpos($action, "V") !== false) { $index = ltrim($action, "V"); $base_url = $this->channels['base_url'] . "/app/ycMidjourney/api/Generate/generate"; } if (strpos($action, "U") !== false) { $index = ltrim($action, "U"); $base_url = $this->channels['base_url'] . "/app/ycMidjourney/api/Upscale/upscale"; } if ($index <= 0) { return $this->renderJson(202, "操作繪畫錯誤~!"); } } ## 提交作圖請求 $response = curlPost($base_url, [ 'prompt' => $this->prompt, 'file_id' => $image_id, 'upscale_index' => $index - 1 ], ['Token:' . $this->channels['app_key']]); file_put_contents("./draw_" . time() . ".txt", $response); $response = json_decode($response, true); if (!$response || $response['code'] != 200) { return $this->renderError($response["msg"] ? $response["msg"] : '繪畫失敗,請重試!@'); } $image_id = ""; if (isset($response['data']['id']) && $response['data']['id']) { $image_id = $response['data']['id']; } if ($action != "generate") { ## U 和 V操作 if (strpos($action, "U") !== false) { $image_id = ""; } } ## 執行繪畫扣費 $this->drawEndRequest(); ## 返回繪畫結果 return $this->renderSuccess(['image_url' => $response['data']['image_url'], 'image_id' => $image_id]); } catch (\Exception $e) { return $this->renderJson(202, $e->getMessage()); } } ```
                  <ruby id="bdb3f"></ruby>

                  <p id="bdb3f"><cite id="bdb3f"></cite></p>

                    <p id="bdb3f"><cite id="bdb3f"><th id="bdb3f"></th></cite></p><p id="bdb3f"></p>
                      <p id="bdb3f"><cite id="bdb3f"></cite></p>

                        <pre id="bdb3f"></pre>
                        <pre id="bdb3f"><del id="bdb3f"><thead id="bdb3f"></thead></del></pre>

                        <ruby id="bdb3f"><mark id="bdb3f"></mark></ruby><ruby id="bdb3f"></ruby>
                        <pre id="bdb3f"><pre id="bdb3f"><mark id="bdb3f"></mark></pre></pre><output id="bdb3f"></output><p id="bdb3f"></p><p id="bdb3f"></p>

                        <pre id="bdb3f"><del id="bdb3f"><progress id="bdb3f"></progress></del></pre>

                              <ruby id="bdb3f"></ruby>

                              哎呀哎呀视频在线观看