Skip to content

Commit

Permalink
disable multi-factor authentication
Browse files Browse the repository at this point in the history
  • Loading branch information
KTNG-3 committed Apr 19, 2024
1 parent 714eaa5 commit 9dbc7ec
Show file tree
Hide file tree
Showing 9 changed files with 13 additions and 31 deletions.
5 changes: 0 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -68,11 +68,6 @@ VAL_REGION="na"
VAL_USER="RiotUsername"
VAL_PASS="Passowrd"

# multi-factor must be "enable"
VAL_MFA_REGION="ap"
VAL_MFA_USER="RiotUsername"
VAL_MFA_PASS="Password"

# https://developer.riotgames.com
VAL_RIOT_API="API_KEY_123"
```
10 changes: 5 additions & 5 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -17,16 +17,16 @@
"license": "MIT",
"devDependencies": {
"@types/jest": "^29.5.12",
"@types/node": "^20.12.2",
"@typescript-eslint/eslint-plugin": "^7.5.0",
"@typescript-eslint/parser": "^7.5.0",
"@types/node": "^20.12.7",
"@typescript-eslint/eslint-plugin": "^7.7.0",
"@typescript-eslint/parser": "^7.7.0",
"dotenv": "^16.4.5",
"eslint": "^8.57.0",
"jest": "29.7.0",
"rimraf": "^5.0.5",
"ts-jest": "^29.1.2",
"typedoc": "^0.25.12",
"typescript": "^5.4.3"
"typedoc": "^0.25.13",
"typescript": "^5.4.5"
},
"scripts": {
"test": "jest --detectOpenHandles",
Expand Down
8 changes: 0 additions & 8 deletions packages/@valapi/auth/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -71,14 +71,6 @@ const authClient = new AuthClient();
await authClient.login("BestUsername", "SuperSecretPassword");
```

```typescript
if (client.authenticationInfo.isMultifactor) {
const verificationCode = 428793;

await authClient.verify(verificationCode);
}
```

**Subject** (PlayerUUID)

```typescript
Expand Down
2 changes: 1 addition & 1 deletion packages/@valapi/auth/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@
"homepage": "https://github.com/valapi/node-valapi/tree/master/packages/@valapi/auth#readme",
"dependencies": {
"@valapi/lib": "^4.0.0",
"http-cookie-agent": "^6.0.1",
"http-cookie-agent": "^6.0.3",
"tough-cookie": "^4.1.3"
},
"devDependencies": {
Expand Down
1 change: 1 addition & 0 deletions packages/@valapi/auth/src/client/AuthClient.ts
Original file line number Diff line number Diff line change
Expand Up @@ -40,6 +40,7 @@ export class AuthClient extends AuthCore {

/**
* Multi-Factor Authentication
* @deprecated Please, Contact us if you find out how its works
* @param {number} verificationCode Verification Code
* @returns {Promise<void>}
*/
Expand Down
1 change: 1 addition & 0 deletions packages/@valapi/auth/src/service/Multifactor.ts
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,7 @@ import type { AuthCore } from "../client/AuthCore";

export class Multifactor extends AuthService {
/**
* @deprecated Please, Contact us if you find out how its works
* @param {number} verificationCode Verification Code
* @returns {Promise<AuthCore.Json>}
*/
Expand Down
11 changes: 2 additions & 9 deletions packages/valorant.ts/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@

<div align="center">

# Valorant API - Support Multifactor
# Valorant API

[![Profile][githubrepo_image]][github_url]

Expand All @@ -39,7 +39,6 @@ NodeJS package that make more easier to use Valorant API
## Why Valorant.ts ?

- Support **Two-Factor Authentication**
- All-In-One
- Authentication
- API
Expand Down Expand Up @@ -82,12 +81,6 @@ Authentication
await AuthClient.login("BestUsername", "SuperSecretPassword");
```

Two-Factor Authentication

```javascript
await AuthClient.verify(428793 /* <--- Verification Code */);
```

Daily Offers

```javascript
Expand All @@ -113,7 +106,7 @@ async function getOffersOf(ItemsId: string) {
};
}

const todayStore = await WebClient.Store.getStorefront(WebClient.getSubject());
const todayStore = await WebClient.Store.StoreFront.get(WebClient.getSubject());

for (const ItemID of todayStore.data.SkinsPanelLayout.SingleItemOffers) {
console.log(await getOffersOf(ItemID));
Expand Down
2 changes: 1 addition & 1 deletion packages/valorant.ts/package.json
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
"registry": "https://registry.npmjs.org",
"access": "public"
},
"description": "Valorant Api - Support Multifactor",
"description": "Valorant API",
"keywords": [
"riot",
"api",
Expand Down
4 changes: 2 additions & 2 deletions tsconfig.test.json
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
{
"compilerOptions": {
"composite": true,
"target": "es2023",
"lib": [ "es2023", "es2022.error", "es2021.promise" ],
"target": "es2022",
"lib": [ "es2022", "es2022.error", "es2021.promise" ],
"module": "commonjs",
"moduleResolution": "node",
"resolveJsonModule": true,
Expand Down

0 comments on commit 9dbc7ec

Please sign in to comment.