Hi,
My DB protected with user permission,
means that any access to DB table can be done only with session token.
I created few scripts, some of them are invoked by rest call and some by schedule job.
The one that invoked using rest call I have no issue since the user info taken from request, doing authentication (DatabaseUser.login(dbId, user, pass).sessionToken), getting the token and using it for any DB call.
The issue is with schedule job,
Here I cannot take the user information from request since no one invoked it (its schedule), due to that I don't have any user information and cannot get any valid token to proceed with operation.
How this can be supported?
I saw in Appery docs one note for "obtain token":
Note: Token is not required if the user added “token” to the request header (click “obtain token” on the server code Test tab).
I cannot understand how this can be used here, can you elaborate?