dilame / instagram-private-api

NodeJS Instagram private API SDK. Written in TypeScript.
MIT License
5.92k stars 1.13k forks source link

Where from does live APIs get the camera feed or video ? #1192

Open helpsocialbotspy opened 4 years ago

helpsocialbotspy commented 4 years ago

I dont fully understand the live APIs, if I start a live https://github.com/dilame/instagram-private-api/blob/master/examples/live.example.ts what will it stream, where from will it get the camera feed or video ?

Form

Put an [x] if you meet the condition, else leave [ ].

I dont fully understand the live APIs, if I start a live https://github.com/dilame/instagram-private-api/blob/master/examples/live.example.ts what will it stream, where from will it get the camera feed or video ?

await ig.live.create({
    // create a stream in 720x1280 (9:16)
    previewWidth: 720,
    previewHeight: 1280,
    // this message is not necessary, because it doesn't show up in the notification
    message: 'My message',
  });
  // (optional) get the key and url for programs such as OBS
  const { stream_key, stream_url } = LiveEntity.getUrlAndKey({ broadcast_id, upload_url });

Where is path to video to be streamed ?

Nerixyz commented 4 years ago

If you've streamed with OBS before, you maybe know, there's a StreamUrl and a StreamKey, the url is the destination of your live broadcast and the stream key is like your password.

You can view your Livestream either on the website itself or using the dash_playback_url with players like VLC

helpsocialbotspy commented 4 years ago

ok got it working with OBS, thanks a lot. now I can access and reply to chats too.

I have another question, I want to pin a chat from one specific user how do I do that?

Nerixyz commented 4 years ago

Use ig.live.pinComment(broadcastId, commentId).