Technical¶
Components¶
- Custom endpoints
- Application configuration
- Lime eServices BankID service
Custom endpoint description¶
Below describes the data passed in requests to the endpoints.
POST /login/
Request¶
When using limecrm
type(i.e. username and password).
parameter | datatype | description |
---|---|---|
type | string | The type used to log in, one of: limecrm or bankid |
username | string | Input username |
password | string | Input password |
When using BankID
parameter | datatype | description |
---|---|---|
type | string | The type used to log in, one of: limecrm or bankid |
personal_number | string | Input personal number |
Example response¶
{
"success": true,
"user": {
"_id": 1001,
"firstname": "Test"
"lastname": "Testsson",
"email": "[email protected]"
}
}
POST /bankid/collect/
This endpoint is only called when using BankID as login. Polls the BankID service for signing status.
Request¶
parameter | datatype | description |
---|---|---|
transaction_id | string | Idenitifer for the current transaction |
Example response¶
{
"progressStatus": "COMPLETE",
"user": {
"_id": 1001,
"firstname": "Test"
"lastname": "Testsson",
"email": "[email protected]"
}
}
POST /reset/request/
Request¶
Request a password reset.
parameter | datatype | description |
---|---|---|
username | string | Input username |
Example response¶
{
"msg": "Reset token set",
"token: "_uuid4_"
}
POST /reset/
Request¶
Reset the password using token.
parameter | datatype | description |
---|---|---|
token | string | The token used to identify the request to reset the password |
username | string | Input username |
new_password | string | The new password to be set |
Example response¶
{
"msg": "Password updated"
}
GET /login/openid/
Request¶
parameter | datatype | description |
---|---|---|
state | string | Random string generated by the consumer, e.g. portal |
Returns¶
Flask.redirect(https://provider_url?state=_state_)
GET /oauth2/authorize/
Request¶
parameter | datatype | description |
---|---|---|
state | string | Random string generated by the consumer, e.g. portal |
code | string | Code used to fetch access token at the provider, by the OAuth2 standard |
Returns¶
Flask.redirect(https://consumer_url?payload=_base64_)
payload
parameter is encoded with base64 and contains
- Limeobject to log in
- State
Table and Field Definitions Lime CRM¶
Any limetype can be used with this package. Requirements are fields for idenitifying the user, which are configurable to each solution. Which fields are used is defined in the application config.