Yokoy User API
Users in Yokoy reflect the fundamental roles of submitter, approver, and finance user. Mandatory user information depends on the specific organization requirements and Yokoy features enabled.Email addresses must be unique for the organization. You cannot create two users with the same email address. If the email address provided already exists in the organization, the API returns an error.Bank information can be provided as part of POST, PUT, and PATCH requests, however, the response does not return this information for security reasons.**Note**: You can‘t use the User endpoints to determine the roles and permissions assigned to a user. You can only use the endpoints to create a new user.Roles and permissions are granted to a user in Yokoy (**Admin > Finance/HR roles**). You must have previously created the user before assigning roles and permissions.- **Booking strategy**: You can export expenses based on the user selected currency (instead of the company currency or the original expense currency). If you choose this option, you need to provide the user's currency.- **Approval strategy**: If you plan to approve expenses using a line manager approval strategy, then you need to enter a line manager for each user.- **Expense accounting**: If expenses are to be posted via the employee vendor account, the field `employeeId` should reflect employee vendor account number. If you want to track the employee number, you should set up a custom field to add this information.- **User policy**: You can assign rank-specific expense policies to certain users and user groups to determine applicable expense rules, per diem and mileage rates, as well as expense categories. If you choose this option, then you need to enter the policy ID.For any unrecognized IDs, Yokoy creates or updates the user attribute with the value `null`. For example, if you pass `Y6cp2G30M` as the `lineManagerId` and no user exists for that ID, Yokoy updates the line manager ID attribute as `null`.To guarantee spend data traceability, when you delete a user via the Yokoy API, the email is changed to an email address with the format: `deleted_user_` + user ID. For example, `deleted_user_lK6jo1GmSkXJzSyZSA2f@localhost.invalid`. The user is still displayed in **HR > User management** with a deleted tag and can’t be re-activated or edited. The user can still be retrieved via the Yokoy API using the Yokoy user ID. However, the user is not returned if you retrieve all users using a GET method. Deleted users can’t be re-activated in any way.
Yokoy User API is one of 22 APIs that Yokoy publishes on the APIs.io network, described by a machine-readable OpenAPI specification.
Tagged areas include User. The published artifact set on APIs.io includes an OpenAPI specification and authentication docs.
This API exposes 6 operations across 2 paths, and defines 3 schemas. It is described by OpenAPI 3.0.0, at version 1.41.0.
Requests are made against 2 base URLs: https://api.yokoy.ai/v1/organizations/{organizationId}, https://api.test.yokoy.ai/v1/organizations/{organizationId}.
Metadata
The identity and technical contract details declared by the specification.
Authentication & Security 1
Yokoy User API declares
1 security scheme
for authenticating requests.
It supports OAuth 2.0 (OAuth2) using the clientCredentials flow.
OAuth2— Authentication to the Yokoy API relies on the standard OAuth2 client credentials flow. 1. Obtain an access token Perform a POST request to https://accounts.yok…
Paths & Operations 6
Across 2 paths, the API surfaces 6 operations — 1 DELETE, 2 GET, 1 PATCH, 1 POST, 1 PUT. Each is listed below with its method, path, parameters, and response codes.
Users in Yokoy reflect the fundamental roles of submitter, approver, and finance user. Mandatory user information depends on the specific organization requirements and Yokoy featu…
Schemas 3
The contract defines 3 schemas that model the data the API accepts and returns. The most detailed are User (20 properties), UserBankInformation (3 properties), Error (2 properties). Each schema is shown below with its type and property counts.
Specification
The full machine-readable OpenAPI contract behind this narrative.
Source
More from Yokoy 12
Other APIs Yokoy publishes across the network.