Auth0 node js sdk Client Credentials grant with custom claims

I’m using auth0 node js sdk.
I have use case like my application is have organization level architecture, so for some organization if they want to access our api without user interaction, i’m creating new client for organization in their tenant, and return it with client_id and client_secret. Now i use the client_id and client_secret to create access_token with authenticationClient oauth clientCredentialsGrant. But I want to add custom claim to access_token

Hi @anand2

Welcome to the Auth0 Community!

Thank you for posting your question. Can you share more details about the expected flow and where you want to add the custom claim to access the token?

Generally speaking, you can customize claims with Actions Create Custom Claims

Thanks
Dawid

Hey dawid,
Thanks for your response.
So yeah the actual flow is.
I want to allow external system to acces my APIs with client_id client_secret grant.
So my system contains different organization.
I’m allowing each organisation to create client application in my tenant and it will give them back client_id and client_secret. Now with this they will try to generate access_token using authentication client oauth clientSecretCredentialsGrant (sorry if the names are wrong). Basically it is giving me back access_token, expiration and some more details.
I want to add a custom claim to this access_token being generated.