Comments (3)
sure!
when using the client the call looked like this:
this.faClient.patchRegistration(entry.accountId, {
registration: {
applicationId: this.applicationId,
roles: newRoles,
},
});
i had to make a call before this to get the registration info and add the additional roles to the existing roles to get newRoles
. If I don't do this, the roles get overwritten and only include the newly added roles, not the existing ones.
when making the axios call it looks like this:
axios.patch(`${this.faClient.host}/api/user/registration/${entry.accountId}/${this.applicationId}`, {
registration: {
applicationId: this.applicationId,
roles: [entry.role],
}
}, {
headers: {
Authorization: this.faClient.apiKey
}
});
when doing it this way, the new role was correctly concatenated to the existing list without having to make a call to get the existing roles first.
from fusionauth-typescript-client.
@shemming sorry to hear that!
We have some issues with patch support (see FusionAuth/fusionauth-issues#441 and upvote it if it is important to you).
Can you please share sample code so we can see if this is an issue with the client library or something else?
from fusionauth-typescript-client.
Also running into this issue. When using patchRegistration
, the user's registration roles are being wiped - even though I have not specified the roles key in the RequestRequest
from fusionauth-typescript-client.
Related Issues (20)
- connection refused (`ECONNREFUSED`) when it tries to register and create a user HOT 2
- What is the default timeout for the operation ? HOT 1
- UpdateUser Changes the Password Unexpectedly HOT 2
- SDK method to return current access token or refresh it if expired HOT 4
- ClientResponse `exception` key should be defined as `Errors` type instead of `Error`
- retrieveUserByX does not allow specification of a tenant id HOT 5
- Client and API Documentation don't align - searchEntityTypes HOT 2
- client.logout("refreshtokien here") dont work HOT 2
- Issue with domain sync HOT 5
- EventType includes unused types HOT 4
- Missing /oauth2/device_authorize endpoint
- Missing "Complete the Device Authorization Grant Request" method call HOT 1
- searchUsersByIds Badly formats the query, resulting in an error HOT 1
- Add a default timeout that isn't 0 for requests
- Sveltkit or authJS examples HOT 7
- Unexpected Response for `FusionAuthClient#searchUsersByQuery` When Using `sortFields`. HOT 3
- Receiving punycode deprecation warning HOT 1
- Patch user request types do not allow for removing a user property
- Misguided documentation
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-typescript-client.