Commit 9ee7746d authored by Travis Fischer's avatar Travis Fischer

chore: update ts docs

parent 83bb9cf8
......@@ -49,7 +49,7 @@ An error if it fails.
#### Defined in
[src/abstract-chatgpt-api.ts:69](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/abstract-chatgpt-api.ts#L69)
[src/abstract-chatgpt-api.ts:69](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/abstract-chatgpt-api.ts#L69)
___
......@@ -66,7 +66,7 @@ otherwise.
#### Defined in
[src/abstract-chatgpt-api.ts:39](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/abstract-chatgpt-api.ts#L39)
[src/abstract-chatgpt-api.ts:39](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/abstract-chatgpt-api.ts#L39)
___
......@@ -87,7 +87,7 @@ An error if the session failed to initialize properly.
#### Defined in
[src/abstract-chatgpt-api.ts:10](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/abstract-chatgpt-api.ts#L10)
[src/abstract-chatgpt-api.ts:10](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/abstract-chatgpt-api.ts#L10)
___
......@@ -111,7 +111,7 @@ Access credentials for the new session.
#### Defined in
[src/abstract-chatgpt-api.ts:49](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/abstract-chatgpt-api.ts#L49)
[src/abstract-chatgpt-api.ts:49](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/abstract-chatgpt-api.ts#L49)
___
......@@ -135,7 +135,7 @@ Access credentials for the new session.
#### Defined in
[src/abstract-chatgpt-api.ts:59](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/abstract-chatgpt-api.ts#L59)
[src/abstract-chatgpt-api.ts:59](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/abstract-chatgpt-api.ts#L59)
___
......@@ -164,4 +164,4 @@ the `response` text.
#### Defined in
[src/abstract-chatgpt-api.ts:30](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/abstract-chatgpt-api.ts#L30)
[src/abstract-chatgpt-api.ts:30](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/abstract-chatgpt-api.ts#L30)
......@@ -64,7 +64,7 @@ to obtain your `clearanceToken`.
#### Defined in
[src/chatgpt-api.ts:45](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L45)
[src/chatgpt-api.ts:45](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L45)
## Accessors
......@@ -80,7 +80,7 @@ Gets the current Cloudflare clearance token (`cf_clearance` cookie value).
#### Defined in
[src/chatgpt-api.ts:143](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L143)
[src/chatgpt-api.ts:143](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L143)
___
......@@ -96,7 +96,7 @@ Gets the current session token.
#### Defined in
[src/chatgpt-api.ts:138](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L138)
[src/chatgpt-api.ts:138](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L138)
___
......@@ -112,7 +112,7 @@ Gets the currently signed-in user, if authenticated, `null` otherwise.
#### Defined in
[src/chatgpt-api.ts:133](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L133)
[src/chatgpt-api.ts:133](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L133)
___
......@@ -128,7 +128,7 @@ Gets the current user agent.
#### Defined in
[src/chatgpt-api.ts:148](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L148)
[src/chatgpt-api.ts:148](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L148)
## Methods
......@@ -152,7 +152,7 @@ An error if it fails.
#### Defined in
[src/chatgpt-api.ts:470](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L470)
[src/chatgpt-api.ts:470](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L470)
___
......@@ -173,7 +173,7 @@ the token fails.
#### Defined in
[src/chatgpt-api.ts:367](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L367)
[src/chatgpt-api.ts:367](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L367)
___
......@@ -194,7 +194,7 @@ is valid.
#### Defined in
[src/chatgpt-api.ts:156](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L156)
[src/chatgpt-api.ts:156](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L156)
___
......@@ -224,7 +224,7 @@ A valid access token
#### Defined in
[src/chatgpt-api.ts:386](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L386)
[src/chatgpt-api.ts:386](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L386)
___
......@@ -252,7 +252,7 @@ Access credentials for the new session.
#### Defined in
[src/abstract-chatgpt-api.ts:59](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/abstract-chatgpt-api.ts#L59)
[src/abstract-chatgpt-api.ts:59](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/abstract-chatgpt-api.ts#L59)
___
......@@ -287,7 +287,7 @@ The response from ChatGPT
#### Defined in
[src/chatgpt-api.ts:180](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L180)
[src/chatgpt-api.ts:180](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L180)
___
......@@ -307,4 +307,4 @@ ___
#### Defined in
[src/chatgpt-api.ts:324](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api.ts#L324)
[src/chatgpt-api.ts:324](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api.ts#L324)
......@@ -49,11 +49,13 @@ Creates a new client for automating the ChatGPT webapp.
| `opts.executablePath?` | `string` | **`Default Value`** `undefined` * |
| `opts.isGoogleLogin?` | `boolean` | **`Default Value`** `false` * |
| `opts.isMicrosoftLogin?` | `boolean` | **`Default Value`** `false` * |
| `opts.isProAccount?` | `boolean` | **`Default Value`** `false` * |
| `opts.markdown?` | `boolean` | **`Default Value`** `true` * |
| `opts.minimize?` | `boolean` | **`Default Value`** `true` * |
| `opts.nopechaKey?` | `string` | **`Default Value`** `undefined` * |
| `opts.password` | `string` | - |
| `opts.proxyServer?` | `string` | **`Default Value`** `undefined` * |
| `opts.userDataDir?` | `string` | **`Default Value`** `random directory with email as prefix` * |
#### Overrides
......@@ -61,7 +63,7 @@ Creates a new client for automating the ChatGPT webapp.
#### Defined in
[src/chatgpt-api-browser.ts:44](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L44)
[src/chatgpt-api-browser.ts:48](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L48)
## Accessors
......@@ -75,7 +77,7 @@ Creates a new client for automating the ChatGPT webapp.
#### Defined in
[src/chatgpt-api-browser.ts:741](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L741)
[src/chatgpt-api-browser.ts:640](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L640)
## Methods
......@@ -95,7 +97,7 @@ Creates a new client for automating the ChatGPT webapp.
#### Defined in
[src/chatgpt-api-browser.ts:249](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L249)
[src/chatgpt-api-browser.ts:255](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L255)
___
......@@ -115,7 +117,7 @@ ___
#### Defined in
[src/chatgpt-api-browser.ts:286](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L286)
[src/chatgpt-api-browser.ts:292](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L292)
___
......@@ -139,7 +141,7 @@ An error if it fails.
#### Defined in
[src/chatgpt-api-browser.ts:687](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L687)
[src/chatgpt-api-browser.ts:586](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L586)
___
......@@ -160,7 +162,7 @@ otherwise.
#### Defined in
[src/chatgpt-api-browser.ts:422](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L422)
[src/chatgpt-api-browser.ts:425](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L425)
___
......@@ -185,7 +187,7 @@ An error if the session failed to initialize properly.
#### Defined in
[src/chatgpt-api-browser.ts:119](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L119)
[src/chatgpt-api-browser.ts:133](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L133)
___
......@@ -205,7 +207,7 @@ Attempts to handle 403 errors by refreshing the page.
#### Defined in
[src/chatgpt-api-browser.ts:364](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L364)
[src/chatgpt-api-browser.ts:367](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L367)
___
......@@ -225,7 +227,7 @@ Attempts to handle 401 errors by re-authenticating.
#### Defined in
[src/chatgpt-api-browser.ts:345](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L345)
[src/chatgpt-api-browser.ts:348](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L348)
___
......@@ -239,7 +241,7 @@ ___
#### Defined in
[src/chatgpt-api-browser.ts:679](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L679)
[src/chatgpt-api-browser.ts:578](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L578)
___
......@@ -272,4 +274,4 @@ the `response` text.
#### Defined in
[src/chatgpt-api-browser.ts:499](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/chatgpt-api-browser.ts#L499)
[src/chatgpt-api-browser.ts:439](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/chatgpt-api-browser.ts#L439)
......@@ -66,7 +66,7 @@ node_modules/.pnpm/typescript@4.9.3/node_modules/typescript/lib/lib.es2022.error
#### Defined in
[src/types.ts:297](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L297)
[src/types.ts:297](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L297)
___
......@@ -76,7 +76,7 @@ ___
#### Defined in
[src/types.ts:296](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L296)
[src/types.ts:296](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L296)
___
......@@ -86,7 +86,7 @@ ___
#### Defined in
[src/types.ts:294](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L294)
[src/types.ts:294](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L294)
___
......@@ -96,4 +96,4 @@ ___
#### Defined in
[src/types.ts:295](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L295)
[src/types.ts:295](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L295)
......@@ -46,6 +46,7 @@
- [defaultChromeExecutablePath](modules.md#defaultchromeexecutablepath)
- [getBrowser](modules.md#getbrowser)
- [getOpenAIAuth](modules.md#getopenaiauth)
- [getPage](modules.md#getpage)
- [initializeNopechaExtension](modules.md#initializenopechaextension)
- [isRelevantRequest](modules.md#isrelevantrequest)
- [markdownToText](modules.md#markdowntotext)
......@@ -60,7 +61,7 @@
#### Defined in
[src/types.ts:109](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L109)
[src/types.ts:109](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L109)
___
......@@ -81,7 +82,7 @@ ___
#### Defined in
[src/types.ts:300](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L300)
[src/types.ts:300](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L300)
___
......@@ -99,7 +100,7 @@ ___
#### Defined in
[src/types.ts:306](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L306)
[src/types.ts:306](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L306)
___
......@@ -109,7 +110,7 @@ ___
#### Defined in
[src/types.ts:1](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L1)
[src/types.ts:1](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L1)
___
......@@ -131,7 +132,7 @@ https://chat.openapi.com/backend-api/conversation
#### Defined in
[src/types.ts:134](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L134)
[src/types.ts:134](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L134)
___
......@@ -149,7 +150,7 @@ ___
#### Defined in
[src/types.ts:251](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L251)
[src/types.ts:251](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L251)
___
......@@ -174,7 +175,7 @@ ___
#### Defined in
[src/types.ts:257](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L257)
[src/types.ts:257](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L257)
___
......@@ -184,7 +185,7 @@ ___
#### Defined in
[src/types.ts:276](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L276)
[src/types.ts:276](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L276)
___
......@@ -201,7 +202,7 @@ ___
#### Defined in
[src/types.ts:270](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L270)
[src/types.ts:270](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L270)
___
......@@ -223,7 +224,7 @@ https://chat.openapi.com/backend-api/conversation/message_feedback
#### Defined in
[src/types.ts:193](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L193)
[src/types.ts:193](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L193)
___
......@@ -233,7 +234,7 @@ ___
#### Defined in
[src/types.ts:249](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L249)
[src/types.ts:249](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L249)
___
......@@ -253,7 +254,7 @@ ___
#### Defined in
[src/types.ts:222](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L222)
[src/types.ts:222](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L222)
___
......@@ -263,7 +264,7 @@ ___
#### Defined in
[src/types.ts:220](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L220)
[src/types.ts:220](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L220)
___
......@@ -273,7 +274,7 @@ ___
#### Defined in
[src/types.ts:275](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L275)
[src/types.ts:275](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L275)
___
......@@ -291,7 +292,7 @@ ___
#### Defined in
[src/types.ts:77](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L77)
[src/types.ts:77](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L77)
___
......@@ -309,7 +310,7 @@ https://chat.openapi.com/backend-api/models
#### Defined in
[src/types.ts:70](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L70)
[src/types.ts:70](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L70)
___
......@@ -328,7 +329,7 @@ https://chat.openapi.com/backend-api/moderations
#### Defined in
[src/types.ts:97](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L97)
[src/types.ts:97](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L97)
___
......@@ -348,7 +349,7 @@ https://chat.openapi.com/backend-api/moderations
#### Defined in
[src/types.ts:114](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L114)
[src/types.ts:114](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L114)
___
......@@ -364,13 +365,12 @@ to authenticate with the unofficial ChatGPT API.
| Name | Type |
| :------ | :------ |
| `clearanceToken` | `string` |
| `cookies?` | `Record`<`string`, `Protocol.Network.Cookie`\> |
| `sessionToken` | `string` |
| `userAgent` | `string` |
#### Defined in
[src/openai-auth.ts:29](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/openai-auth.ts#L29)
[src/openai-auth.ts:29](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/openai-auth.ts#L29)
___
......@@ -388,7 +388,7 @@ ___
#### Defined in
[src/types.ts:161](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L161)
[src/types.ts:161](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L161)
___
......@@ -405,7 +405,7 @@ ___
#### Defined in
[src/types.ts:178](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L178)
[src/types.ts:178](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L178)
___
......@@ -415,7 +415,7 @@ ___
#### Defined in
[src/types.ts:3](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L3)
[src/types.ts:3](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L3)
___
......@@ -425,7 +425,7 @@ ___
#### Defined in
[src/types.ts:288](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L288)
[src/types.ts:288](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L288)
___
......@@ -447,7 +447,7 @@ ___
#### Defined in
[src/types.ts:278](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L278)
[src/types.ts:278](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L278)
___
......@@ -468,7 +468,7 @@ https://chat.openapi.com/api/auth/session
#### Defined in
[src/types.ts:8](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L8)
[src/types.ts:8](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L8)
___
......@@ -490,7 +490,7 @@ ___
#### Defined in
[src/types.ts:30](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/types.ts#L30)
[src/types.ts:30](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/types.ts#L30)
## Functions
......@@ -517,7 +517,7 @@ included them in here.
#### Defined in
[src/utils.ts:79](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/utils.ts#L79)
[src/utils.ts:79](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/utils.ts#L79)
___
......@@ -533,7 +533,7 @@ Gets the default path to chrome's executable for the current platform.
#### Defined in
[src/openai-auth.ts:435](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/openai-auth.ts#L435)
[src/openai-auth.ts:469](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/openai-auth.ts#L469)
___
......@@ -557,7 +557,7 @@ recognizes it and blocks access.
#### Defined in
[src/openai-auth.ts:269](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/openai-auth.ts#L269)
[src/openai-auth.ts:299](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/openai-auth.ts#L299)
___
......@@ -603,7 +603,29 @@ with your updated credentials.
#### Defined in
[src/openai-auth.ts:51](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/openai-auth.ts#L51)
[src/openai-auth.ts:50](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/openai-auth.ts#L50)
___
### getPage
**getPage**(`browser`, `opts`): `Promise`<`Page`\>
#### Parameters
| Name | Type |
| :------ | :------ |
| `browser` | `Browser` |
| `opts` | `Object` |
| `opts.proxyServer?` | `string` |
#### Returns
`Promise`<`Page`\>
#### Defined in
[src/openai-auth.ts:262](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/openai-auth.ts#L262)
___
......@@ -620,6 +642,7 @@ ___
| `opts.debug?` | `boolean` |
| `opts.minimize?` | `boolean` |
| `opts.nopechaKey?` | `string` |
| `opts.proxyServer?` | `string` |
| `opts.timeoutMs?` | `number` |
#### Returns
......@@ -628,7 +651,7 @@ ___
#### Defined in
[src/openai-auth.ts:401](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/openai-auth.ts#L401)
[src/openai-auth.ts:434](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/openai-auth.ts#L434)
___
......@@ -648,7 +671,7 @@ ___
#### Defined in
[src/utils.ts:45](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/utils.ts#L45)
[src/utils.ts:45](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/utils.ts#L45)
___
......@@ -668,7 +691,7 @@ ___
#### Defined in
[src/utils.ts:18](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/utils.ts#L18)
[src/utils.ts:18](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/utils.ts#L18)
___
......@@ -688,7 +711,7 @@ ___
#### Defined in
[src/utils.ts:35](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/utils.ts#L35)
[src/utils.ts:35](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/utils.ts#L35)
___
......@@ -708,4 +731,4 @@ ___
#### Defined in
[src/utils.ts:25](https://github.com/transitive-bullshit/chatgpt-api/blob/4a0f780/src/utils.ts#L25)
[src/utils.ts:25](https://github.com/transitive-bullshit/chatgpt-api/blob/83bb9cf/src/utils.ts#L25)
......@@ -2,7 +2,7 @@ chatgpt / [Exports](modules.md)
# Update January 12, 2023 <!-- omit in toc -->
This package works to access ChatGPT pretty consistently, even after OpenAI added Cloudflare protections. To circumvent these protections, we've added a **fully automated browser-based solution**, which uses Puppeteer and CAPTCHA solvers under the hood. 🔥
This package allows you to access ChatGPT from Node.js – even with OpenAI's Cloudflare protections. It uses a **fully automated browser-based solution**, which uses Puppeteer and CAPTCHA solvers under the hood. 🔥
```ts
import { ChatGPTAPIBrowser } from 'chatgpt'
......@@ -23,9 +23,9 @@ We recently added support for CAPTCHA automation using either [nopecha](https://
There are some restrictions to be aware of, however:
- Cloudflare doesn't like requests coming from data center IPs, so you'll either have to run it locally or use a residential IP proxy.
- Cloudflare doesn't like requests coming from data center IPs, so you'll likely either need to run it locally or use a residential IP proxy.
- You should only have one `sendMessage` request at a time per browser instance and OpenAI account.
- It can be difficult to reliably process `sendMessage` requests after awhile. My best advice for handling this is to wrap your usage in some basic retry logic as well as a daemon which restarts your Node.js process every hour or so. This is unfortunately a byproduct of there not being an official API, so keep that in mind before using this in production.
- It can be difficult to reliably process `sendMessage` requests after awhile. My best advice for handling this is to wrap your usage in some basic retry logic as well as a daemon which restarts your Node.js process every hour or so. This is unfortunately a by-product of there not being an official API, so keep that in mind before using this in production.
If you run into any issues, we do have a pretty active [Discord](https://discord.gg/v9gERj825w) with a bunch of ChatGPT hackers from the Node.js & Python communities.
......@@ -338,6 +338,8 @@ All of these awesome projects are built using the `chatgpt` package. 🤯
- [Discord Bot #2](https://github.com/Nageld/ChatGPT-Bot)
- [Discord Bot #3](https://github.com/leinstay/gptbot)
- [Discord Bot #4 (selfbot)](https://github.com/0x7030676e31/cumsocket)
- [Discord Bot #5](https://github.com/itskdhere/ChatGPT-Discord-BOT)
- [Discord Bot #6 (Shakespeare bot)](https://gist.github.com/TheBrokenRail/4b37e7c44e8f721d8bd845050d034c16)
- [WeChat Bot #1](https://github.com/AutumnWhj/ChatGPT-wechat-bot)
- [WeChat Bot #2](https://github.com/fuergaosi233/wechat-chatgpt)
- [WeChat Bot #3](https://github.com/wangrongding/wechat-bot)
......@@ -362,6 +364,7 @@ All of these awesome projects are built using the `chatgpt` package. 🤯
- [Teams Bot](https://github.com/formulahendry/chatgpt-teams-bot)
- [Askai](https://github.com/yudax42/askai)
- [TalkGPT](https://github.com/ShadovvBeast/TalkGPT)
- [ChatGPT With Voice](https://github.com/thanhsonng/chatgpt-voice)
- [iOS Shortcut](https://github.com/leecobaby/shortcuts/blob/master/other/ChatGPT_EN.md)
- [Slack Bot #1](https://github.com/trietphm/chatgpt-slackbot/)
- [Slack Bot #2](https://github.com/lokwkin/chatgpt-slackbot-node/) (with queueing mechanism)
......@@ -373,6 +376,7 @@ All of these awesome projects are built using the `chatgpt` package. 🤯
- [NestJS server](https://github.com/RusDyn/chatgpt_nestjs_server)
- [NestJS ChatGPT Starter Boilerplate](https://github.com/mitkodkn/nestjs-chatgpt-starter)
- [Wordsmith: Add-in for Microsoft Word](https://github.com/xtremehpx/Wordsmith)
- [QuizGPT: Create Kahoot quizzes with ChatGPT](https://github.com/Kladdy/quizgpt)
If you create a cool integration, feel free to open a PR and add it to the list.
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment