Skip to content

Commit

Permalink
Draft v1
Browse files Browse the repository at this point in the history
  • Loading branch information
dilame committed Apr 6, 2019
1 parent 48230a2 commit 40edb23
Show file tree
Hide file tree
Showing 82 changed files with 480 additions and 5,066 deletions.
15 changes: 0 additions & 15 deletions .travis.yml

This file was deleted.

90 changes: 90 additions & 0 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

10 changes: 6 additions & 4 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -12,17 +12,18 @@
"node": ">=8.0.0"
},
"bugs": {
"url": "https://github.com/huttarichard/instagram-private-api/issues",
"email": "huttarichard@gmail.com"
"url": "https://github.com/dilame/instagram-private-api/issues",
"email": "dilame.nickolson@gmail.com"
},
"repository": {
"type": "git",
"url": "https://github.com/huttarichard/instagram-private-api.git"
"url": "https://github.com/dilame/instagram-private-api.git"
},
"homepage": "https://github.com/huttarichard/instagram-private-api",
"homepage": "https://github.com/dilame/instagram-private-api",
"scripts": {
"build": "rm -rf dist && tsc -p tsconfig.build.json",
"format": "prettier --write \"src/**/*.ts\"",
"lint": "tslint -p tsconfig.json -c tslint.json",
"typecheck": "tsc -p tsconfig.build.json --noEmit",
"prepare": "npm run build",
"test": "mocha --inline-diffs --timeout 1000000 tests/run.js"
Expand Down Expand Up @@ -77,6 +78,7 @@
"sinon": "^1.17.3",
"tmp": "0.0.28",
"ts-node": "^8.0.2",
"tslint": "^5.15.0",
"typescript": "^3.4.1"
}
}
11 changes: 11 additions & 0 deletions src/client.ts
Original file line number Diff line number Diff line change
@@ -0,0 +1,11 @@
import { State, Request } from './core';
import { AuthRepository } from './repositories/auth.repository';
import { FeedFactory } from './feeds/feed.factory';

export class IgApiClient {
public state = new State();
public request = new Request(this);
public auth = new AuthRepository(this);
public feed = new FeedFactory(this);
constructor() {}
}
14 changes: 0 additions & 14 deletions src/constants/constants.ts
Original file line number Diff line number Diff line change
Expand Up @@ -2,23 +2,9 @@ export import EXPERIMENTS = require('./experiments.json');
export import LOGIN_EXPERIMENTS = require('./login-experiments.json');
export import SUPPORTED_CAPABILITIES = require('./supported-capabilities.json');

export const APP_CREDENTIALS = {
SIG_KEY: '19ce5f445dbfd9d29c59dc2a78c616a7fc090a8e018b9267bc4240a30244c53b',
SIG_VERSION: '4',
VERSION: '76.0.0.15.395',
VERSION_CODE: '138226743',
FB_ANALYTICS_APPLICATION_ID: '567067343352427',
LANGUAGE: 'en_US',
};

export const TLD = 'instagram.com';
export const HOSTNAME = 'i.instagram.com';
export const WEB_HOSTNAME = 'www.instagram.com';
export const HOST = `https://${HOSTNAME}/`;
export const WEBHOST = `https://${WEB_HOSTNAME}/`;
export const API_ENDPOINT = `${HOST}api/v1/`;

export const HEADERS = {
X_IG_Connection_Type: 'WIFI',
X_IG_Capabilities: '3brTPw==',
};
37 changes: 0 additions & 37 deletions src/core/cookies/cookie-file-storage.ts

This file was deleted.

10 changes: 0 additions & 10 deletions src/core/cookies/cookie-memory-storage.ts

This file was deleted.

69 changes: 0 additions & 69 deletions src/core/cookies/cookie-storage.ts

This file was deleted.

3 changes: 0 additions & 3 deletions src/core/cookies/index.ts

This file was deleted.

15 changes: 0 additions & 15 deletions src/core/devices/device.interface.ts

This file was deleted.

Loading

0 comments on commit 40edb23

Please sign in to comment.