instagram-private-api
instagram-private-api copied to clipboard
Error while trying to call 'api/v1/media/configure_to_igtv/' manually
General Question
This question is not related to api library, instead related to instagram api.
Notes
I'm trying to manually call instagram api endpoints to upload video in post. All endpoints return successful results, ids, etc..
Headers, that used in video-related requests:
-
X-Instagram-Rupload-Params
:{ "is_igtv_video": "1", "is_unified_video": "1", "upload_media_height": "540", "xsharing_user_ids": "[]", "upload_media_width": "540", "upload_media_duration_ms": "10000", "content_tags": "use_default_cover", "upload_id": current timestamp for all kinds of this field, "retry_context": "{\"num_reupload\":0,\"num_step_auto_retry\":0,\"num_step_manual_retry\":0}", "media_type": "2" }
-
Segment-Type
:2
-
Offset
:0
-
Segment-Start-Offset
:segment.offset
-
Stream-Id
:returned from initial phase=start call
-
X_fb_video_waterfall_id
:all video-related endpoints receive same: random(1000000000, 9999999999)
-
Retry_context
:{ "num_reupload": 0, "num_step_auto_retry": 0, "num_step_manual_retry": 0 }
Body, that used in configure_to_igtv
request(signed_body=SIGNATURE. included):
{
"is_igtv_video": "1",
"is_unified_video": "1",
"igtv_ads_toggled_on": "0",
"camera_entry_point": "173",
"filter_type": "0",
"timezone_offset": "10800",
"media_folder": "Camera",
"source_type": "4",
"_uid": "xxx",
"device_id": "xxx",
"keep_shoppable_products": "0",
"_uuid": "xxx",
"caption": "",
"date_time_original": "19040101T000000.000Z",
"igtv_share_preview_to_feed": "0",
"upload_id": "the same, that used in previous requests",
"igtv_composer_session_id": "5bd65f86-68a2-4e3f-a094-2e51bfc7144b",
"device": {
"manufacturer": "Xiaomi",
"model": "Mi 9T",
"android_version": 29,
"android_release": "10"
},
"length": 10.000,
"clips": [
{
"length": 10.000,
"source_type": "4"
}
],
"extra": {
"source_width": 540,
"source_height": 540
},
"audio_muted": false,
"poster_frame_index": 0
}
Flow that i use:
-
GET /api/v1/igtv/igtv_creation_tools/
- Start segments uploading
POST /rupload_igvideo/{uuid4::random()}?segmented=true&phase=start
- Init segment upload(before transfer)
GET /rupload_igvideo/{uuid4(without '-')-0-segment_size}?segmented=true&phase=transfer
- Transfer segment
POST /rupload_igvideo/{uuid4(without '-')-0-segment_size}?segmented=true&phase=transfer
- End segments uploading
POST /rupload_igvideo/{uuid4::random()}?segmented=true&phase=end
- Upload photo
POST /rupload_igphoto/{uuid4::random()}
- Finish video upload(configure)
POST /api/v1/media/configure_to_igtv/?video=1
<- this fail
Form
- [x] I've searched the Issues
- [x] I've read the basic concepts
- [ ] I'm using the latest version
Question
Why i receive server processing error: um_request_failure
error while trying to manually upload video in post?, how i can fix that?
Code
- Nothing
Error and Output
{
"message": "server processing error: um_request_failure",
"status": "fail"
}
HTTP/1.1 400 Bad Request
Content-Type: application/json; charset=utf-8
Vary: Accept-Language, Cookie
Content-Language: en
Date: Sat, 05 Feb 2022 16:11:05 GMT
Strict-Transport-Security: max-age=31536000
Cache-Control: private, no-cache, no-store, must-revalidate
Pragma: no-cache
Expires: Sat, 01 Jan 2000 00:00:00 GMT
X-Frame-Options: SAMEORIGIN
content-security-policy: report-uri https://www.instagram.com/security/csp_report/; default-src 'self' https://www.instagram.com; navigate-to 'none'; object-src 'none'; form-action 'none'; base-uri 'none'; upgrade-insecure-requests; sandbox; img-src https://*.giphy.com
cross-origin-embedder-policy-report-only: require-corp;report-to="coep"
report-to: {"group": "coep", "max_age": 86400, "endpoints": [{"url": "/security/coep_report/"}]},{"group": "coop", "max_age": 86400, "endpoints": [{"url": "/security/coop_report/"}]}
origin-trial: xxx
cross-origin-opener-policy: same-origin-allow-popups;report-to="coop"
X-Content-Type-Options: nosniff
X-XSS-Protection: 0
x-ig-push-state: c2
x-aed: 48
x-ig-set-www-claim: xxx
Access-Control-Expose-Headers: X-IG-Set-WWW-Claim
x-ig-request-elapsed-time-ms: 663
ig-set-ig-u-ig-direct-region-hint: 0
ig-set-ig-u-ds-user-id: xxx
x-ig-origin-region: xxx
X-FB-TRIP-ID: xxx
X-FB-Client-IP-Forwarded: x.x.x.x
X-FB-Server-Cluster-Forwarded: arn2c01
Alt-Svc: h3=":443"; ma=3600,h3-29=":443"; ma=3600
Content-Length: 73
Connection: keep-alive
{"message":"server processing error: um_request_failure","status":"fail"}
Hello! Were you able to resolve this issue with um_request_failure?
this is maybe the problem with upload video. you should upload video with 'Content-Type': 'video/mp4'
up