Config for mpesa
Jobs that use the mpesa
adaptor may require authentication. A
"credential" for the mpesa
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.
{
"short_code": "654321",
"pass_key": "bfb279f9aa9bdbcf158e97dd71a467cd2e0c893059b10f78e6b72ada1ed2c919",
"consumer_key": "GA2PNftcXvv2uC2VdgNjxXyvF8eZ4td6iBsL7N7N2ZFnXzf3",
"consumer_secret": "zKjr2j0jjihCtzIwzGtgnV0YgP82jZf1hY9RW6HygntWG6AGuf4tAUe3E5tPtiyA"
}
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#",
"properties": {
"baseUrl": {
"title": "Base URL",
"description": "The base URL (https://api.safaricom.co.ke)",
"format": "uri",
"minLength": 1,
"examples": [
"https://api.safaricom.co.ke"
]
},
"short_code": {
"title": "Short code",
"type": "string",
"description": "This is the organization's shortcode used to identify YOUR organization. Usually a 5 to 6-digit account number",
"examples": [
"654321"
]
},
"pass_key": {
"title": "Pass key",
"type": "string",
"description": "Your app's pass key sent to you via email once you go live",
"examples": [
"bfb279f9aa9bdbcf158e97dd71a467cd2e0c893059b10f78e6b72ada1ed2c919"
]
},
"consumer_key": {
"title": "Consumer key",
"type": "string",
"description": "Your app's consumer key sent to you via email once you go live",
"examples": [
"GA2PNftcXvv2uC2VdgNjxXyvF8eZ4td6iBsL7N7N2ZFnXzf3"
]
},
"consumer_secret": {
"title": "Consumer key",
"type": "string",
"description": "Your app's consumer secret sent to you via email once you go live",
"examples": [
"zKjr2j0jjihCtzIwzGtgnV0YgP82jZf1hY9RW6HygntWG6AGuf4tAUe3E5tPtiyA"
]
}
},
"type": "object",
"additionalProperties": true,
"required": [
"short_code",
"pass_key",
"consumer_key",
"consumer_secret"
]
}