PhoenixGenAI

Good to know: All GenAI interfaces need to use token as the request header.

Base GenAI

Generating an image by base mode

POST https://www.phoenix.global/sdk/computation/LLM/callGenImage

Headers

Request Body

{
  "code": 200,
  "msg": "success",
  "path": "http://xxxxxx.jpg",
  "tokens_balance": 43400
}

The usage of curl and golang sdk is as follows:

curl --location 'https://www.phoenix.global/sdk/computation/LLM/callGenImage' \
--header 'Token: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJFbWFpbCI6IjExMUBnbWFpbC5jb20iLCJleHAiOjE2NzgyNzM4Mjh9.7Qy6jh5L1qvVVbOZYR3JrmWdothI2SCF-oGyC2BfZDs' \
--header 'Content-Type: application/json' \
--data '{
    "negative_prompt": "ugly,watermark,jpeg artifacts,error,text,username",
    "prompt": "iron man skiing on steep slope, hd, high quality"
}'

SDXL GenAI

Generating an image by SDXL mode

POST https://www.phoenix.global/sdk/computation/LLM/callGenSDXLImage

Headers

Request Body

{
  "code": 200,
  "msg": "success",
  "path": "http://xxxxxx.jpg",
  "tokens_balance": 43400
}

The usage of curl and golang sdk is as follows:

curl --location 'https://www.phoenix.global/sdk/computation/LLM/callGenSDXLImage' \
--header 'Token: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJFbWFpbCI6IjExMUBnbWFpbC5jb20iLCJleHAiOjE2NzgyNzM4Mjh9.7Qy6jh5L1qvVVbOZYR3JrmWdothI2SCF-oGyC2BfZDs' \
--header 'Content-Type: application/json' \
--data '{
    "prompt": "iron man skiing on steep slope, hd, high quality",
    "negative_prompt": "ugly,watermark,jpeg artifacts,error,text,username"
}'

Text to Motion

Generating a gif from prompts

POST https://www.phoenix.global/sdk/computation/LLM/callTextToMotion

Headers

Request Body

{
  "code": 200,
  "msg": "success",
  "path": "http://xxxxxx.jif",
  "tokens_balance": 43400
}

The usage of curl and golang sdk is as follows:

curl --location 'https://www.phoenix.global/sdk/computation/LLM/callTextToMotion' \
--header 'token: eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJFbWFpbCI6IjExMUBnbWFpbC5jb20iLCJleHAiOjE2NzgyNzM4Mjh9.7Qy6jh5L1qvVVbOZYR3JrmWdothI2SCF-oGyC2BfZDs' \
--header 'Content-Type: application/json' \
--data '{
    "prompt": "iron man skiing on steep slope, hd, high quality",
    "negative_prompt": "blurry"
}'

Image to Motion

Generating a gif from an image

POST https://genapi.phoenix.global/sdk/computation/LLM/callImgToMotion

Headers

Body

Response

{
    "code": 200,
    "msg": "success",
    "path": "https://xxxxxx.jif",
    "tokens_balance": 43400
}

The usage of curl and golang sdk is as follows:

curl --location 'https://genapi.phoenix.global/sdk/computation/LLM/callImgToMotion' \
--header 'token: eyJhxxxxxxiCGOK2hWU' \
--header 'Content-Type: application/json' \
--data '{
    "image_path": "https://xxxxxx.jpeg"
}'

Last updated