Custom HR

This page will introduce a series of API interfaces for customers who use self-made personnel systems instead of LDAP, so that they can also synchronize user and department data to OMFLOW.

Note: This API needs to be provided by the intermediary application and called by OMFLOW.

Credentials

It is strongly recommended that intermediary applications use SSL/TLS certificates to ensure data transmission security.

Synchronize data

Note: OMFLOW will call this API to synchronize personnel and department data. Please organize the third-party personnel and department data into the following data format.

Method:POST

URL:/sync

Basic Authentication: True

Content-Type: application/json

Return data

When successful, the returned data example is as follows:

{
    "status": "success",
    "user_info_list" : [{
            "username": "<account>", //(unique value)
            "email": "<Email>", //(unique value)
            "nick_name": "<person name>",
            "ad_no": "<employee number>",
            "company": "<company>",
            "phone1": "<phone>",
            "phone2": "<mobile phone>",
            "extension_no": "<extension>",
            "gender":"<gendermale/female>"
        },...
    ],
    "group_info_list": [{
            "display_name": "<department name>",
            "group_no": "<department code>", //(unique value)
            "parent_group_no": "<parent department code>",
            "user_list": [
                "<username1>",
                "<username2>",
                ...
                ]
        },...
    ]
}

In case of failure, the returned data example is as follows:

{
    "status": "fail",
    "message": "<error message>"
}

Note:

  • username, email and group_no are unique values.

  • OMFLOW will judge the username and group_no as the same personnel and departments. If the synchronized data this time is different from the previous synchronized data, it will perform the actions of adding, modifying and deleting.

log in

After synchronizing the data, OMFLOW will call this API for verification when the user logs in. The request content sent by OMFLOW is as follows:

{"username": "<account>", "password": "<password>"}

Please conduct login review according to this content and return the review results.

Note: Please implement the login verification method yourself and return the results in the following format

Method:POST

URL: /authenticate

Basic Authentication: True

Content-Type: application/json

Return data

When the login verification is successful, an example of the returned data is as follows:

{
    "status": "success"
}

When login verification fails, an example of the returned data is as follows:

{
    "status": "fail",
    "message": "<error message>"
}

Last updated