I suspect the only option is to use the REST API to retrieve the user properties based on FME_SECURITY_USER:
GET /security/accounts/$(FME_SECURITY_USER)
Response:
account {
email (string, optional): Email of the account,
enabled (boolean): Whether the account is currently enabled or not,
fullName (string): Full name of the account,
name (string): Unique name of the account,
password (string): Account password,
roles (array[string], optional): Roles assigned to the account,
type (string) = ['System' or 'Ldap']: Type of the account
}
You can use the FME_SERVER_HOST + FME_SERVER_PORT as a basis for the query URL.
I suspect the only option is to use the REST API to retrieve the user properties based on FME_SECURITY_USER:
GET /security/accounts/$(FME_SECURITY_USER)
Response:
account {
email (string, optional): Email of the account,
enabled (boolean): Whether the account is currently enabled or not,
fullName (string): Full name of the account,
name (string): Unique name of the account,
password (string): Account password,
roles (array[string], optional): Roles assigned to the account,
type (string) = ['System' or 'Ldap']: Type of the account
}
You can use the FME_SERVER_HOST + FME_SERVER_PORT as a basis for the query URL.
Hi @david_r , thank you for your suggestion. Is a good idea. Yesterday I've cheked the other way to querying the useraccount table in fmeserver db and get the mail from it and works. I will to switch to api to have more flexibility in the future.
I open an Idea to create a new variables like FME_SECURITY_USER but f.e. FME_SECURITY_USER_EMAIL with the email automagically set by fme.
Thank you
Hi @david_r , thank you for your suggestion. Is a good idea. Yesterday I've cheked the other way to querying the useraccount table in fmeserver db and get the mail from it and works. I will to switch to api to have more flexibility in the future.
I open an Idea to create a new variables like FME_SECURITY_USER but f.e. FME_SECURITY_USER_EMAIL with the email automagically set by fme.
Thank you
That's a nice workaround, but since you're using an undocumented function be sure to specifically re-test this every time you upgrade FME Server.
I voted for your idea, it's a good one.