Utwórz zadanie imagine w Midjourney
Użyj POST /mj/submit/imagine w CometAPI, aby tworzyć zadania imagine w Midjourney z pełnymi parametrami Discord, śledzić status task_id i włączać efekty ruchu image-to-video.
Co daje pierwsza odpowiedź
resultto id zadania, które będziesz odpytywać w następnym krokucodenadal może być kodem sukcesu, nawet jeśli nie jest to200w stylu HTTP
Główny przepływ pracy
Prześlij zadanie imagine
Odpytuj, aż zadanie się zakończy
SUCCESS, MODAL lub FAILURE.Kontynuuj post-processing
Opcjonalny wzorzec promptu wideo
Jeśli chcesz uzyskać ruch ze źródłowego obrazu, dodaj adres URL obrazu oraz flagi wideo Midjourney w prompt, takie jak--video i --motion.Autoryzacje
Bearer token authentication. Use your CometAPI key.
Treść
Text prompt for the generation. Supports standard Midjourney parameters such as --v, --ar, --stylize, etc.
"a paper boat floating on calm water at sunrise --v 6.1"
Bot type to use. MID_JOURNEY for Midjourney (default), NIJI_JOURNEY for Niji.
MID_JOURNEY, NIJI_JOURNEY Filter which Midjourney account modes may be used for this task.
Base64-encoded reference images. Each item should be a data URI such as data:image/png;base64,xxx.
Custom state string. Returned as-is in the task result and webhook callback for your own tracking.
Odpowiedź
Task accepted.
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.
Task id returned after submission.