instagram-private-api
instagram-private-api copied to clipboard
Create account is outdated/doesn't work
Bug Report
I believe Instagram updated their account creation endpoint(s).
Form
Requirements
- [X] I've searched the Issues
- [X] I've read the basic concepts
- [X] I'm using the latest version
- [X] I've debugged my code using the
DEBUGvariable.
Platform
- [X] I'm using Node.js version
14.16.0 - [ ] I'm using electron
Description
Check the account creation functionality. Once the app constants are updated (Open MR here: https://github.com/dilame/instagram-private-api/pull/1572), and you attempt to create an account, you're given a 400 error:
Code
require('dotenv').config();
const { IgApiClient } = require('instagram-private-api');
const ig = new IgApiClient();
ig.state.generateDevice("TEST");
ig.state.proxyUrl = process.env.IG_PROXY;
(async () => {
const username = "XXX",
email = "[email protected]",
password = "XXX",
first_name = "XXX";
ig.account.create({ username, password, email, first_name });
})()`
Error and Output
(node:29771) UnhandledPromiseRejectionWarning: IgResponseError: POST /api/v1/accounts/create/ - 400 Bad Request;
@Nerixyz any idea?
I think API was changed by IG.
Their encoding of text is not support by this lib unless it has dict for decode. this lib does not support encoding for x-fb-dz I hope @Nerixyz will look into this.
I hope @Nerixyz will look into this.
This is out of scope for me. I'm trying to make sure the library compiles but can't guarantee that everything will work. Creating accounts is heavily checked by Instagram to make sure only real people create accounts and I can respect that. If anyone opens a PR to fix/patch this, I'm totally fine with merging it.
Their encoding of text is not support by this lib unless it has dict for decode. this lib does not support encoding for x-fb-dz
That's another issue but I beleive you can set the appropriate headers to receive gzip/zstd in responses. Related: mitmproxy/mitmproxy#4394
@Nerixyz Thanks
Read my comment in #1580
I updated my private library, I am added zstd encode support, sn_nonce, sn_result. But still I am getting challenge_required error. @Nerixyz
I updated my private library, I am added zstd encode support, sn_nonce, sn_result. But still I am getting challenge_required error. @Nerixyz
use this https://github.com/SaeidB/insta_create
I updated my private library, I am added zstd encode support, sn_nonce, sn_result. But still I am getting challenge_required error. @Nerixyz
use this https://github.com/SaeidB/insta_create
It is using third-party API, we need direct API
I updated my private library, I am added zstd encode support, sn_nonce, sn_result. But still I am getting challenge_required error. @Nerixyz
use this https://github.com/SaeidB/insta_create
It is using third-party API, we need direct API
it uses direct api in backend, do u need requests data directly?
need direct api, no third-party please.
need direct api, no third-party please.
Pm me on telegram