Skip to main content

Config for fhir-eswatini

Jobs that use the fhir-eswatini adaptor may require authentication. A "credential" for the fhir-eswatini adaptor will follow the schema below. When using the CLI, you can set up your own state.configuration by using the sample below.

Sample Configuration​

Paste this into the configuration key of your state.json file and modify the values to run jobs locally.

{
"baseUrl": "https://hapi.fhir.org",
"apiPath": "baseR4"
}

Full Schema​

The full configuration schema describes each attribute of the credential and notes those that are required.

{
"$schema": "http://json-schema.org/draft-07/schema#",
"type": "object",
"properties": {
"baseUrl": {
"title": "Base Url",
"type": "string",
"description": "The baseUrl",
"examples": [
"https://hapi.fhir.org"
]
},
"apiPath": {
"title": "API Path",
"anyOf": [
{
"type": "string"
},
{
"type": "null"
}
],
"placeholder": "R4",
"description": "FHIR api path",
"minLength": 1,
"examples": [
"baseR4",
"R3",
"R4"
]
},
"username": {
"title": "Username",
"type": "string",
"description": "Username",
"examples": [
"openfn_test"
]
},
"password": {
"title": "Password",
"type": "string",
"description": "Password",
"writeOnly": true,
"examples": [
"@some(!)Str0ngp4ss0w0rd"
]
},
"access_token": {
"title": "Access Token",
"type": "string",
"description": "Your FHIR access token",
"writeOnly": true,
"minLength": 1,
"examples": [
"the-long-access-token-from-your-auth"
]
}
},
"required": [
"baseUrl",
"apiPath"
]
}