Interroga GET /replicate/v1/predictions/ per recuperare i dettagli della prediction di Replicate e l’avanzamento in tempo reale per ID attività nei flussi di lavoro di generazione di immagini.
curl --request GET \
--url https://api.cometapi.com/replicate/v1/predictions/{id} \
--header 'Authorization: Bearer <token>'{
"id": "<string>",
"input": {},
"model": "<string>",
"output": [
"<string>"
],
"status": "<string>",
"created_at": "<string>",
"data_removed": true,
"logs": "<string>",
"urls": {
"get": "<string>",
"cancel": "<string>",
"stream": "<string>"
},
"error": "<string>",
"metrics": {
"image_count": 123,
"predict_time": 123
},
"version": "<string>",
"started_at": "<string>",
"completed_at": "<string>"
}status per vedere se la prediction è ancora in esecuzione o è già terminataoutput per gli URL delle risorse generateerror per gli errori lato providermetrics quando ti servono i tempi di esecuzione o i dettagli sul numero di immaginiCrea prima la prediction
Esegui il polling tramite prediction id
status non diventa terminale e output non viene popolato oppure non viene restituito un errore del provider.Bearer token authentication. Use your CometAPI key.
Prediction id returned by the create endpoint.
Current prediction state.
Show child attributes
Show child attributes
curl --request GET \
--url https://api.cometapi.com/replicate/v1/predictions/{id} \
--header 'Authorization: Bearer <token>'{
"id": "<string>",
"input": {},
"model": "<string>",
"output": [
"<string>"
],
"status": "<string>",
"created_at": "<string>",
"data_removed": true,
"logs": "<string>",
"urls": {
"get": "<string>",
"cancel": "<string>",
"stream": "<string>"
},
"error": "<string>",
"metrics": {
"image_count": 123,
"predict_time": 123
},
"version": "<string>",
"started_at": "<string>",
"completed_at": "<string>"
}