This repository was archived by the owner on Sep 1, 2022. It is now read-only.
File tree Expand file tree Collapse file tree 2 files changed +12
-1
lines changed
Expand file tree Collapse file tree 2 files changed +12
-1
lines changed Original file line number Diff line number Diff line change @@ -35,12 +35,14 @@ const strapi = new Strapi('http://localhost:1337');
3535## API
3636
3737### ` Strapi(baseURL, requestConfig) `
38+ ### ` request(method, url, requestConfig) `
3839### ` register(username, email, password) `
3940### ` login(identifier, password) `
4041### ` forgotPassword(email, url) `
4142### ` resetPassword(code, password, passwordConfirmation) `
43+ ### ` getProviderAuthenticationUrl(provider) `
44+ ### ` authenticateProvider(provider, params) `
4245### ` setToken(token) `
43- ### ` request(method, url, requestConfig) `
4446### ` getEntries(contentType, params) `
4547### ` getEntry(contentType, id) `
4648### ` createEntry(contentType, data) `
Original file line number Diff line number Diff line change @@ -144,10 +144,19 @@ export default class Strapi {
144144 } ) ;
145145 }
146146
147+ /**
148+ * Retrieve the connect provider URL
149+ * @param provider
150+ */
147151 public getProviderAuthenticationUrl ( provider : Provider ) : string {
148152 return `${ this . axios . defaults . baseURL } /connect/${ provider } ` ;
149153 }
150154
155+ /**
156+ * Authenticate the user with the token present on the URL (for browser) or in `params` (on Node.js)
157+ * @param provider
158+ * @param params
159+ */
151160 public async authenticateProvider (
152161 provider : Provider ,
153162 params ?: Token
You can’t perform that action at this time.
0 commit comments