Comments (6)
I think there are two issues here:
- It looks like there may be a regression issue with this method, previously it was using the API key (if provided on the client constructor). This API can be called with or without an API key and now it is calling w/out it. This may be causing you problems if your API key is locked to a tenant.
- You are seeing an error indicating you need to provide the Tenant Id
Regarding the second issue, how many tenants do you have configured? Was this the same number when you were running 1.11.0? Is your API key locked to a single tenant?
from fusionauth-php-client.
@matthew-altman looks like a regression issue. This will affect all client libraries.
The forgotPassword
method is being called w/out an API key, previously it was using the API key if we had it. The API can be called in both ways, so we'll need to either add a new method that uses the API key, or somehow instruct this method to be called in either mode.
We could just use the start
instead of startAnonymous
since if there is an API key available it doesn't hurt. We should probably do an audit of all of the APIs now using the startAnonymous
method in the client builder to ensure they cannot be optionally be called with an API key.
from fusionauth-php-client.
A work around if you want to use the API key.
In FusionAuthClient.php
change
public function forgotPassword($request)
{
return $this->startAnonymous()->uri("/api/user/forgot-password")
->bodyHandler(new JSONBodyHandler($request))
->post()
->go();
}
to
public function forgotPassword($request)
{
return $this->start()->uri("/api/user/forgot-password")
->bodyHandler(new JSONBodyHandler($request))
->post()
->go();
}
from fusionauth-php-client.
Thanks for the reply @robotdan .
Yes I can confirm we're using the API key for all the calls. Is there a better way going forward?
We have about 5-6 tenants set up, and it was the same number before we upgraded the libs.
For now we've reverted to 1.11 but might implement the work-around if we need to upgrade the versions.
from fusionauth-php-client.
Ok, good to know. You could upgrade FusionAuth and keep with the older php client as well, or patch your client as outlined above.
We'll be patching the client shortly, stay tuned.
from fusionauth-php-client.
1.12.1 is available which contains the corrected behavior. Thanks for letting us know!
https://packagist.org/packages/fusionauth/fusionauth-client
from fusionauth-php-client.
Related Issues (17)
- PSR autoload is failing because of case insensitive namespace HOT 1
- No X-FusionAuth-TenantId header when using withTenantId method HOT 1
- PHP Login User Example Does Not Work HOT 5
- User Sign In Successfully but NOT Signed In to FusionAuth & Everywhere HOT 1
- Delete Group Members does not have the expected API or its API is not documented HOT 1
- Is issue #833 back again? HOT 7
- Getting error due to Silent Mode HOT 1
- Cut 'empty' params in request (JSONBody) HOT 2
- getting invalid_redirect_uri HOT 1
- Support php 8.1 HOT 1
- Missing PHP version constraint HOT 4
- Timeouts and other cURL errors are not handled HOT 1
- Deprecated doc
- Methods using the JWT authorization are failing HOT 1
- Error while generating phpDoc in Actions HOT 1
- option to set TenantID is missing. HOT 3
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from fusionauth-php-client.