Skip to main content
POST
cURL
Use este endpoint depois que uma tarefa do Midjourney retornar botões de ação. Ele inicia uma nova tarefa subsequente, como upscale, variation, reroll, zoom ou pan.

Você precisa de dois valores

  • taskId da tarefa original ou mais recente do Midjourney
  • customId do array buttons mais recente retornado por Fetch Single Task
customId não é estável. Nunca o codifique diretamente. Sempre leia-o da resposta de polling mais recente.

Ações comuns

  • U1 a U4: aplicar upscale em uma imagem da grade
  • V1 a V4: gerar variações a partir de uma posição de imagem
  • Reroll: regenerar a grade completa
  • Zoom e Pan: expandir a composição existente

Depois de enviar uma ação

1

Criar a tarefa subsequente

Envie taskId e customId, depois armazene o novo id de tarefa retornado.
2

Fazer polling da nova tarefa

Consulte Fetch Single Task novamente até que a ação seja concluída.
3

Lidar com ações somente de modal

Se a nova tarefa chegar a MODAL, continue com Modal para fornecer a entrada adicional.

Autorizações

Authorization
string
header
obrigatório

Bearer token authentication. Use your CometAPI key.

Corpo

application/json
customId
string
obrigatório

Action id taken from the latest buttons array returned by the fetch endpoint.

taskId
string
obrigatório

Midjourney task id you want to continue from.

state
string

Custom state string. Returned as-is in the task result and webhook callback for your own tracking.

enableRemix
boolean

Whether to force remix mode when the current action supports it.

chooseSameChannel
boolean

Whether to prefer the same provider account used by the current task.

Resposta

200 - application/json

Action task accepted.

code
integer
obrigatório

Submission status code. 1 = submitted successfully (result carries the task id). 21 = the action opened a confirmation modal; continue with /mj/submit/modal using the returned task id. 4 = parameter error; description explains the cause.

description
string
obrigatório
result
string
obrigatório

New Midjourney task id created for the action.

properties
object