NAV Navigation
cURL HTTP JavaScript Node.js Ruby Python Java Go PHP

Welcome

This documentation was last updated on Wed Nov 17 19:27:27 UTC 2021 and covers Mambu Version v9.110.2

Welcome to the Mambu API v2 documentation. Here you can learn everything you need to know about our API and how to interact with Mambu!

We offer language bindings in cURL, HTTP, JavaScript, Node.js, Ruby, Python, Java, and Go. You can view code examples in the dark area to the right, and you can switch the programming language of the examples with the tabs at the top right.

About Mambu API v2

Scroll down for code samples, example requests, and responses. Select a language for code samples from the tabs above or the mobile navigation menu.

We recommend building all new integrations with API v2. For a comparison of API v2 and v1, see Introducing API v2.0 in our User Guide.

For more information about API v1, see our API 1.0 Reference in our User Guide.

Base URLs

The base URL for requests to the API is found below:

To make requests to your tenant's sandbox, use the following base URL:

For more information on your sandbox, see the Sandbox section below.

HTTP Verbs

Standard HTTP verbs are used to indicate the API request method.

Verb Function
GET To retrieve a resource or a collection of resources
POST To create a resource
PATCH To modify an existing resource
PUT To replace an existing resource
DELETE To delete a resource

Authentication

Mambu supports two methods for authenticating API requests:

Basic Authentication

curl --location --request GET 'https://YOUR_TENANT_NAME.mambu.com/api/users' \
--header 'Authorization: Basic U29tZVVzZXI6T3BlblNlc2FtZQ=='
GET /api/users HTTP/1.1
Host: YOUR_TENANT_NAME.mambu.com
Authorization: Basic U29tZVVzZXI6T3BlblNlc2FtZQ==
var settings = {
  "url": "https://YOUR_TENANT_NAME.mambu.com/api/users",
  "method": "GET",
  "timeout": 0,
  "headers": {
    "Authorization": "Basic U29tZVVzZXI6T3BlblNlc2FtZQ=="
  },
};

$.ajax(settings).done(function (response) {
  console.log(response);
});
var axios = require('axios');

var config = {
  method: 'get',
  url: 'https://YOUR_TENANT_NAME.mambu.com/api/users',
  headers: {
    'Authorization': 'Basic U29tZVVzZXI6T3BlblNlc2FtZQ=='
  }
};

axios(config)
.then(function (response) {
  console.log(JSON.stringify(response.data));
})
.catch(function (error) {
  console.log(error);
});
require "uri"
require "net/http"

url = URI("https://YOUR_TENANT_NAME.mambu.com/api/users")

https = Net::HTTP.new(url.host, url.port)
https.use_ssl = true

request = Net::HTTP::Get.new(url)
request["Authorization"] = "Basic U29tZVVzZXI6T3BlblNlc2FtZQ=="

response = https.request(request)
puts response.read_body
import requests

url = "https://YOUR_TENANT_NAME.mambu.com/api/users"

payload={}
headers = {
  'Authorization': 'Basic U29tZVVzZXI6T3BlblNlc2FtZQ=='
}

response = requests.request("GET", url, headers=headers, data=payload)

print(response.text)
OkHttpClient client = new OkHttpClient().newBuilder()
  .build();
Request request = new Request.Builder()
  .url("https://YOUR_TENANT_NAME.mambu.com/api/users")
  .method("GET", null)
  .addHeader("Authorization", "Basic U29tZVVzZXI6T3BlblNlc2FtZQ==")
  .build();
Response response = client.newCall(request).execute();
package main

import (
  "fmt"
  "net/http"
  "io/ioutil"
)

func main() {

  url := "https://YOUR_TENANT_NAME.mambu.com/api/users"
  method := "GET"

  client := &http.Client {
  }
  req, err := http.NewRequest(method, url, nil)

  if err != nil {
    fmt.Println(err)
    return
  }
  req.Header.Add("Authorization", "Basic U29tZVVzZXI6T3BlblNlc2FtZQ==")

  res, err := client.Do(req)
  if err != nil {
    fmt.Println(err)
    return
  }
  defer res.Body.Close()

  body, err := ioutil.ReadAll(res.Body)
  if err != nil {
    fmt.Println(err)
    return
  }
  fmt.Println(string(body))
}

For basic authorization, provide your username and password directly via the Authorization header in the format Basic {base64-encoded-string}, where base64-encoded-string is the base-64-encoded value of your username and password separated by a colon ':'.

For example, a user with the username SomeUser and the password OpenSesame would take the value SomeUser:OpenSesame and base-64 encode it, yielding U29tZVVzZXI6T3BlblNlc2FtZQ==. They would then provide an Authorization header for their request with the value Basic U29tZVVzZXI6T3BlblNlc2FtZQ==.

See the code samples for this section for sample GET requests to the /users endpoint using the above example.

Note that the login credentials must be for an account with API access permissions. See API & Apps Authentication in our User Guide for more information.

API Keys

API keys are tokens that you provide in an apiKey header to authenticate requests. They are generated by API consumers, which are an abstraction similar to an OAuth client.

API consumers are currently an Early Access Feature. If you would like to request access to this feature, please get in touch with your Mambu Customer Success Manager to discuss your requirements.

For more information on API consumers and keys, see API Consumers in our User Guide.

Versioning

# You can also use wget
curl -X {HTTP Verb} https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET https://YOUR_TENANT_NAME.mambu.com/api/Insert-Resource-URI-here HTTP/1.1
Host: YOUR_TENANT_NAME.mambu.com

Accept: application/vnd.mambu.v2+json
var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: 'YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}',
  method: '{HTTP Verb}',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})
const request = require('node-fetch');

const headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

fetch('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}',
{
  method: '{HTTP Verb}',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.{HTTP Verb} 'https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}',
  params: {
  }, headers: headers

p JSON.parse(result)
import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.{HTTP Verb}('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}', params={

}, headers = headers)

print r.json()
URL obj = new URL("https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestProperty(“Accept”, “application/vnd.mambu.v2+json”);
con.setRequestMethod("{HTTP Verb}");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("{HTTP Verb}", "https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Mambu API v2 provides a versioning system to assist with backwards compatibility. Contract changes will result in a new version of each affected resource becoming available without the old version immediately becoming obsolete.

Versioning is supported in API requests via the Accept: header.

Template: application/vnd.mambu.{version}+json

To retrieve a specific version of an entity, fill a value into the template above. The highest currently supported version is v2.

Idempotency

Code samples

# You can also use wget
curl -X POST https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: 01234567-9abc-def0-1234-56789abcdef0'
POST https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions HTTP/1.1
Host: YOUR_TENANT_NAME.mambu.com
Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: 01234567-9abc-def0-1234-56789abcdef0
var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'01234567-9abc-def0-1234-56789abcdef0'

};

$.ajax({
  url: 'https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})
const request = require('node-fetch');
const inputBody = '{
  "migrationEventKey": "string",
  "transactionDetails": {
    "encodedKey": "string",
    "transactionChannelKey": "string",
    "transactionChannelId": "string"
  },
  "notes": "string",
  "affectedAmounts": {
    "feesAmount": 0,
    "overdraftInterestAmount": 0,
    "overdraftFeesAmount": 0,
    "fractionAmount": 0,
    "overdraftAmount": 0,
    "interestAmount": 0,
    "fundsAmount": 0
  },
  "cardTransaction": {
    "externalReferenceId": "string",
    "advice": false,
    "externalAuthorizationReferenceId": "string",
    "cardAcceptor": {
      "zip": "string",
      "country": "string",
      "city": "string",
      "name": "string",
      "state": "string",
      "mcc": 0
    },
    "userTransactionTime": "string",
    "currencyCode": "string",
    "transactionChannelId": "string"
  },
  "taxes": {
    "taxRate": 0
  },
  "tillKey": "string",
  "type": "IMPORT",
  "balances": {
    "totalBalance": 0
  },
  "terms": {
    "interestSettings": {
      "interestRate": 0
    },
    "overdraftSettings": {
      "overdraftLimit": 0
    },
    "overdraftInterestSettings": {
      "interestRate": 0,
      "indexInterestRate": 0
    }
  },
  "reversalTransactionKey": "string",
  "id": "string",
  "originalTransactionKey": "string",
  "amount": 0,
  "linkedDepositTransactionKey": "string",
  "entryDate": "2016-09-06T13:37:50+03:00",
  "externalId": "string",
  "userKey": "string",
  "parentAccountKey": "string",
  "linkedLoanTransactionKey": "string",
  "productTypeKey": "string",
  "currencyCode": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'01234567-9abc-def0-1234-56789abcdef0'

};

fetch('https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions',
{
  method: 'POST',
  body: inputBody,
  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});
require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => '01234567-9abc-def0-1234-56789abcdef0'
}

result = RestClient.post 'https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions',
  params: {
  }, headers: headers

p JSON.parse(result)
import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': '01234567-9abc-def0-1234-56789abcdef0'
}

r = requests.post('https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions', params={

}, headers = headers)

print r.json()
URL obj = new URL("https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
String idempotentKey = UUID.randomUUID().toString();
con.setRequestProperty(“Idempotency-Key”, idempotentKey);
con.setRequestProperty(“Accept”, “application/vnd.mambu.v2+json”);
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"01234567-9abc-def0-1234-56789abcdef0"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://YOUR_TENANT_NAME.mambu.com/api/deposits/{depositAccountId}/transactions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Idempotent requests to the Mambu UI are guaranteed to be executed no more than once.

Working with financial transactions, it is important to ensure some requests are not repeated for any reason, which may result in data loss or accidental duplication. You may configure requests to be idempotent by providing an Idempotency-Key header and providing a unique UUID token for the request. This will guard against the possibility of error if a request must be retried.

When an idempotent request is processed, the status code and body of the response is associated with the idempotency key and stored in a cache. If the request is duplicated for any reason, the duplicate request will not be processed, and the response will be re-sent to the client.

Idempotent requests that fail at the server level such validation failures are not stored in the cache. Subsequent requests with the same idempotency key will be processed as if they were new, receiving the same 400 BAD REQUEST error response.

For examples of idempotent requests, see the code samples for this section.

Idempotency Keys and Retry Mechanisms

Idempotency keys must use the v4 UUID format (32 hexadecimal digits, in a 8-4-4-4-12 arrangement, such as 01234567-9abc-def0-1234-56789abcdef0).

We recommend generating UUIDs programmatically or by using an online generator such as UUID Generator to ensure that all keys are valid V4 UUIDs.

Retry mechanisms must:

Sandbox

The sandbox environment is independent from the production tenant, and any changes you make in the sandbox will not affect the data in your production tenant.

To make requests to your tenant's sandbox, use the following path:

The sandbox is generally one version ahead of the production environment. As such, it may include changes that are currently in, or may soon be in, the production environment. Our release notes contain release dates for a given version for both sandbox and production.

Creating and configuring your sandbox

For instructions on how to create your sandbox in MyMambu, see Creating a Sandbox in our User Guide.

Note that you may copy the configuration of the production environment to your sandbox in MyMambu along with anonymised client data. Alternatively, you can create an empty sandbox and transfer your configuration using configuration as code, which allows you to migrate configuration data such as business processes, custom fields, roles, organisation settings, and internal controls between environments.

Tenant API Reference

We provide an interactive API Reference for each tenant at this location:

This reference documents all the endpoints available to you in the sandbox and allows you to generate an SDK. Additionally, if you authorize your session using your Mambu UI username and password you can autogenerate docs that include any Custom Fields you may have configured.

How to authorize

  1. Log into your sandbox instance at
    https://YOUR_TENANT_NAME.sandbox.mambu.com.
  2. Go to Administration > Access > Users.
  3. Find the user you want to use for authorization and click Actions in the far right column.
  4. Select Edit and in the modal that pops up enable API under the Access Rights section.

The Access Rights section of user admin

  1. Go to https://YOUR_TENANT_NAME.sandbox.mambu.com/apidocs and click the Authorize button.
  2. Enter the username and password of the user with API access rights.

Authorizing in the Sandbox Reference API

Interactive request testing

Once you are authorized, you can test any API by clicking the Try it out button. The reply you receive is generated from the interactive documentation and will not affect your sandbox or production data. Basic validation is performed on requests to ensure they are well-formed, and sample replies will be returned.

Testing an API in Sandbox

Pagination

Code samples

# You can also use wget
curl -X GET https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?offset=10&limit=10&paginationDetails=ON \
  -H 'Accept: application/vnd.mambu.v2+json'

GET https://YOUR_TENANT_NAME.mambu.com/api/Insert-Resource-URI-here?offset=10&limit=10&paginationDetails=ON HTTP/1.1
Host: YOUR_TENANT_NAME.mambu.com

Accept: application/vnd.mambu.v2+json
var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: 'https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?offset=10&limit=10&paginationDetails=ON',
  method: '{HTTP Verb}',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const request = require('node-fetch');

const headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

fetch('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}'?offset=10&limit=10&paginationDetails=ON,
{
  method: '{HTTP Verb}',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.{HTTP Verb} 'https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?offset=10&limit=10&paginationDetails=ON',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.{HTTP Verb}('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?offset=10&limit=10&paginationDetails=ON', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?offset=10&limit=10&paginationDetails=ON");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestProperty(“Accept”, “application/vnd.mambu.v2+json”);
con.setRequestMethod("{HTTP Verb}");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("{HTTP Verb}", "https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?offset=10&limit=10&paginationDetails=ON", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Response headers

(...) content-type: application/vnd.mambu.v2+json  date: Mon, 03 Sep 2018 10:56:15 GMT  items-limit: 10  items-offset: 10  items-total: 35  (...)

Mambu API v2 has customizable pagination capabilities, however this functionality is deactivated by default and must be specified in each request.

In order to view pagination details, append ?paginationDetails=ON to the end of the resource URI in your request. The pagination details (including total number of records) will be returned as headers in the response.

To further customize the response, the offset and limit parameters can be adjusted from their default values.

limit

The default limit for responses is 50. A value of up to 1,000 can be specified with limit.

offset

offset determines how many records will be skipped before being included in the returned results. The default offset value is 0.

Detail Level

Code samples

# You can also use wget
curl -X GET https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?detailsLevel=FULL \
  -H 'Accept: application/vnd.mambu.v2+json'

GET https://YOUR_TENANT_NAME.mambu.com/api/Insert-Resource-URI-here?detailsLevel=FULL HTTP/1.1
Host: YOUR_TENANT_NAME.mambu.com

Accept: application/vnd.mambu.v2+json
var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: 'https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?detailsLevel=FULL',
  method: '{HTTP Verb}',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const request = require('node-fetch');

const headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

fetch('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?detailsLevel=FULL',
{
  method: '{HTTP Verb}',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.{HTTP Verb} 'https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?detailsLevel=FULL',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.{HTTP Verb}('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?detailsLevel=FULL', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?detailsLevel=FULL");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestProperty(“Accept”, “application/vnd.mambu.v2+json”);
con.setRequestMethod("{HTTP Verb}");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("{HTTP Verb}", "https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}?detailsLevel=FULL", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Mambu API v2 supports two detail levels for responses:

To view a higher level of detail, include detailsLevel as a query parameter in your request and give it the value FULL.

Using the API

Requests

Code samples

# You can also use wget
curl -X {HTTP Verb} https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET https://YOUR_TENANT_NAME.mambu.com/api/Insert-Resource-URI-here HTTP/1.1
Host: YOUR_TENANT_NAME.mambu.com

Accept: application/vnd.mambu.v2+json
var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: 'https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}',
  method: '{HTTP Verb}',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

const request = require('node-fetch');

const headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

fetch('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}',
{
  method: '{HTTP Verb}',

  headers: headers
})
.then(function(res) {
    return res.json();
}).then(function(body) {
    console.log(body);
});

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.{HTTP Verb} 'https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.{HTTP Verb}('https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestProperty(“Accept”, “application/vnd.mambu.v2+json”);
con.setRequestMethod("{HTTP Verb}");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("{HTTP Verb}", "https://YOUR_TENANT_NAME.mambu.com/api/{Insert resource URI here}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

Also referred to as "calls", requests to the Mambu API identify who the requester is and exactly what information they wish to retrieve or which action they wish to perform.

To put together an API Request you will need to combine:

Responses

Error Response

{
  "errorCode":"4",
  "errorSource":"Property scheduleSettings.repaymentInstallments may not be null",
  "errorReason":"INVALID_PARAMETERS"
}

Single Resource - JSON object

{
  "field": "value"
}

Collection of Resources - JSON array

[
  {
    "field": "value"
  },
  {
    "field": "value"
  }
]

The response to a request will always be in JSON format and will contain either:

Field Type Availability Content
errorCode number Always present A unique error code. For a full list, please see Mambu Response Codes.
errorSource string Sometimes present A human-readable message capturing unsatisfied constraints.
errorReason string Always present A human-readable message stating the general category of the failure.

or

Generate an SDK

You can also generate a SDK Client for each resource in 50+ programming languages. To do so:

  1. Visit your instance's Swagger documentation page at https://{yourtenantname}.mambu.com/apidocs or visit the page for our demo tenant.

  2. Choose a resource from the drop-down menu in the upper right-hand corner.

  3. Scroll down to the "SDK Client" section at the bottom of the page.

  4. Choose from the available programming languages via the drop-down menu at the left.

  5. Click Generate SDK.

Audit Trail and the User-Agent Header

Error when User Agent header is not provided

{
  "errors": [
    {
      "errorCode": 4,
      "errorSource": "The user agent cannot be null when the Audit Trail feature is enabled",
      "errorReason": "INVALID_PARAMETERS"
    }
  ]
}

Audit trail tracks all activities performed in the Mambu Core Banking system via the UI or API v1 and v2. For more information, see Audit Trail in our User Guide.

When the audit trail feature is enabled, you must provide a User-Agent header for all requests to any endpoint, or the request will fail with the error message The user agent cannot be null when the Audit Trail feature is enabled.

Note that if you are using a REST client like Postman or Curl, this header is probably provided automatically. However, if you generate a request to the API, you must provide it yourself.

The User-Agent header provides information regarding the browser and operating system (such as the browser version), and information about the library or tool issuing the request (such as the client Java version). It is generally used to assist with debugging problems.

Timezone Offsets

Here is how we handle timezone offsets in API v2 calls:

Example JSON body showing an invalid date offset request

{
    "errors": [
        {
            "errorCode": 4,
            "errorSource": "Invalid date offset for value 2021-03-09T13:37:50 org offset is +02:00",
            "errorReason": "INVALID_PARAMETERS"
        }
    ]
}

Example

Each Mambu tenant has one timezone. Let’s take for example tenants in the East European time zone (UTC+02:00).

Date and time of request Error message or What is saved in the database
2021-03-09T13:37:50 “Invalid date offset for value 2021-03-09T13:37:50 org offset is +02:00”
2021-03-09T13:37:50+03:00 “Invalid date offset for value 2021-03-09T13:37:50 org offset is +02:00”
2021-03-09T13:37:50+02:00 2021-03-09 13:37:50

Using Custom Fields

Structure

Standard JSON structure for custom fields

{
  ...
  "_customFieldSet": {
    "customField1": "value",
    "customField2": "other value",
    "awesomeCustomField": "awesome value"
  }
  ...
}

Most Mambu resources (e.g., accounts, clients) can be extended with custom fields. These can be managed by your Mambu administrators. For more details please see our User Guide.

When working with API v2, custom fields are represented at the end of the JSON structure and are ALWAYS nested under their corresponding custom field set. Custom field sets are easily recognizable, since their names must begin with an underscore _.

Example JSON body showing a custom field set with custom fields nested below

{
  "id": "ABC001",
  "loanName": "Mortgage Loan",
  "loanState": "PARTIAL_APPLICATION",
  "_loanPerformanceScore": {    //custom field set
    "amountScore": "10",       //custom fields nested under the set
    "timeScore": "5"
  }
}

Example

If we have created a custom field set called _loanPerformanceScore containing custom fields called amountScore and timeScore, these would be represented in JSON as can be seen to the right.

PATCH operations

In API v2, custom fields are treated as regular JSON citizens. They can be patched the same way as native fields, except that the custom field set must always be specified in the operation path.

The denominator

In Mambu, custom fields are always nested under a custom field set. The type of custom field set dictates how custom fields must be handled in PATCH operations:

Standard - For this first category, all PATCH operations are treated similarly to native fields, except for adding new values, where the syntax differs slightly.

Grouped - Fields in this category can be instanced multiple times on the same record. Each instance will be considered an entry in a list, thus PATCHing fields in a grouped custom field set is the same as working with lists under the RFC6902 standard.

Standard custom field sets

Standard custom field set examples:

  • Using the add operation
[
  {
    "op": "add",
    "path": "/_OtherDetails",
    "value": {
      "Age": "48"
    }
  }
]
  • Using the replace operation
[
  {
    "op": "replace",
    "path": "/_OtherDetails/Age",
    "value": "51"
  }
]
  • Using the remove operation
[
  {
    "op": "remove",
    "path": "/_OtherDetails/Age"
  }
]

Custom fields created under a Standard custom field set are handled the same way across all operations.

For the following examples, let’s assume we want to capture the client’s age to be used for various scorings when applying for credits or other products. To set this up in Mambu we would first create a custom field set (in this example called "Other Details") and then create a custom field for "Age".

Adding data

Let’s assume that we want to add the age for a customer. The add operation must be used, as seen to the right.

Changing data

Let’s assume that we want to change the age for a customer. The replace operation must be used, as seen to the right.

Removing data

Let’s assume that we want to remove the age for a customer. The remove operation must be used, as seen to the right.










Grouped custom field sets

Grouped custom field set examples

Using the Add operation

[
  {
    "op": "add",
    "path": "/_Assets",
    "value": [
      {
        "ASSETYPE": "Land",
        "ASSETAGE": "10",
        "ASSETVALUE": "965000"
      },
      {
        "ASSETYPE": "Car",
        "ASSETAGE": "2",
        "ASSETVALUE": "25000"
      }
    ]
  }
]

For the following examples, let’s assume we want to capture the client assets that are to be used as guarantees for loans. To set this up in Mambu we would first create a custom field set (in this example called "Assets") and then create three fields, each capturing a different aspect of the asset:

Adding data

Let’s assume we want to add two assets as guarantees: a piece of land and a car. We would use the Add operation as seen to the right.







Changing data

Using the Replace operation

[
  {
    "op": "replace",
    "path": "/_Assets/1/ASSETAGE",
    "value": "2"
  }
  {
    "op": "replace",
    "path": "/_Assets/1/ASSETVALUE",
    "value": "35000"
  }
]

Let’s assume that we want to change the age or a recorded asset. To do so, we must use the Replace operation. Unlike with standard custom field sets however, the path must contain the index, which is how we state which asset we want to change.

Let’s assume I want to change the car’s age and value. Knowing that this was recorded as the second asset, and its index is 1, the API payload can be seen to the right.


Removing data

Using the Remove operation examples

  • Remove data from a single custom field (eg. remove the age of an asset, such as land, because it’s irrelevant).
[
  {
    "op": "remove",
    "path": "/_Assets/0/ASSETAGE"
  }
]
  • Remove an entire entry (eg. remove the entire asset such as the car)
[
  {
    "op": "remove",
    "path": "/_Assets/1"
  }
]
  • Remove all entries (eg. remove all the recorded assets)
[
  {
    "op": "remove",
    "path": "/_Assets"
  }
]

Removing grouped custom field data works with the Remove operation. This is largely the same as with standard custom fields sets, with one exception: here the path must contain the index, to be sure the desired record is being indicated.

Searching by Custom Fields

  • Search for entries where the given custom field has the value FALSE
{
  "filterCriteria": [
    {
      "field": "_marketing_opt_in.investor_newsletter",
      "operator": "EQUALS",
      "value": "FALSE"
    }
  ]
}
  • Search for entries where the given custom field has one of the given values
{
  "filterCriteria": [
    {
      "field": "_group_details.industry",
      "operator": "IN",
      "values": [
        "agriculture",
        "arboriculture"
      ]
    }
  ],
  "sortingCriteria": {
    "field": "id",
    "order": "ASC"
  }
}

For any endpoint offering search functionality by POST request custom fields must be provided nested inside their respective custom field set using dot notation in the form _custom_field_set_ID.custom_field_ID. You can see an example of the syntax to the right. The custom field set can belong to the same entity or to a parent entity.

Entities offering this kind of search functionality include: Clients, Groups, Loan Transactions, Loan Accounts, Deposit Accounts, Deposit Transactions, and Credit Arrangements.

For example, if you have a custom field set on the Client level for 'is married' and a custom field for 'has a teenager' you can filter for all Deposit Accounts that meet this requirement. Likewise if you have a custom field set on the Product level for 'is grandfathered' and a custom field for 'expire soon' you can filter for all Clients that have this product."

Accounting Interest Accrual

Allows search of interest accrual breakdown entries by various criteria.

searchInterestAccrual (Accounting Interest Accrual)

Code samples

# You can also use wget
curl -X POST /accounting/interestaccrual:search \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json'

POST /accounting/interestaccrual:search HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/accounting/interestaccrual:search',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.post '/accounting/interestaccrual:search',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.post('/accounting/interestaccrual:search', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/accounting/interestaccrual:search', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/accounting/interestaccrual:search");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/accounting/interestaccrual:search", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /accounting/interestaccrual:search

Allows search of interest accrual breakdown entries by various criteria

Body parameter

{
  "filterCriteria": [
    {
      "field": "entryId",
      "operator": "EQUALS",
      "secondValue": "string",
      "value": "string",
      "values": [
        "string"
      ]
    }
  ],
  "sortingCriteria": {
    "field": "entryId",
    "order": "ASC"
  }
}

Parameters

Name Type Description In Required
offset integer(int32) Pagination, index to start searching at when retrieving elements, used in combination with limit to paginate results query false
limit integer(int32) Pagination, the number of elements to retrieve, used in combination with offset to paginate results query false
paginationDetails string Flag specifying whether the pagination details should be provided in response headers. Please note that by default it is disabled (OFF), in order to improve the performance of the APIs query false
detailsLevel string The level of details to retrieve, FULL means the full details of the object will be retrieved (custom fields, address, contact info or any other related object), BASIC will return only the first level elements of the object query false
body InterestAccrualSearchCriteria Criteria to be used to search interest accrual breakdown body false

Enumerated Values

Parameter Value
paginationDetails ON
paginationDetails OFF
detailsLevel BASIC
detailsLevel FULL

Example responses

200 Response

[
  {
    "accountId": "string",
    "accountKey": "string",
    "amount": 0,
    "bookingDate": "string",
    "branchKey": "string",
    "branchName": "string",
    "creationDate": "string",
    "entryId": 0,
    "entryType": "string",
    "foreignAmount": {
      "accountingRate": {
        "encodedKey": "string",
        "endDate": "2016-09-06T13:37:50+03:00",
        "fromCurrencyCode": "string",
        "rate": 0,
        "startDate": "2016-09-06T13:37:50+03:00",
        "toCurrencyCode": "string"
      },
      "amount": 0,
      "currency": {
        "code": "AED"
      }
    },
    "glAccountId": "string",
    "glAccountKey": "string",
    "glAccountName": "string",
    "glAccountType": "string",
    "parentEntryId": 0,
    "productId": "string",
    "productKey": "string",
    "productType": "string",
    "transactionId": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK Interest accrual breakdown retrieved Inline
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

Response Schema

Status Code 200

Name Type Description Required Restrictions
anonymous [InterestAccrualBreakdown] [Represents an interest accrual breakdown entry] false none
» accountId string The loan/deposit account ID for which the interest accrued amount is retrieved false none
» accountKey string The encoded key of the loan/deposit account for which the interest accrual amount is retrieved false none
» amount number The interest accrued amount for the account referred in this entry false none
» bookingDate string The booking date, in Organization Time Zone false none
» branchKey string The encoded Key for branch of the account false none
» branchName string The name for branch of the account false none
» creationDate string The creation datetime of the entry, in UTC false none
» entryId integer(int64) Generated Id for the interest accrual per account entry false none
» entryType string Debit or Credit false none
» foreignAmount ForeignAmount Representation of details of GL Journal Entries posted in foreign currency. false none
»» accountingRate AccountingRate Represents the conversion rate used in accounting to convert amounts from one currency to organisation currency false none
»»» encodedKey string The encoded key of the accounting rate, auto generated, unique false read-only
»»» endDate string(date-time) Rate validity end date (as Organization Time) false none
»»» fromCurrencyCode string Organisation currency code false none
»»» rate number Value of rate to be used for accounting conversions false none
»»» startDate string(date-time) Rate validity start date (as Organization Time) false none
»»» toCurrencyCode string Foreign currency code false none
»» amount number Amount in foreign currency false none
»» currency Currency Represents a currency eg. USD, EUR. false none
»»» code string Code of the currency. false none
» glAccountId string The id of GL Account false none
» glAccountKey string The encoded key of the GL Account used for logging the interest accrual false none
» glAccountName string The name of GL Account false none
» glAccountType string The type of GL Account: ASSET / LIABILITY / EQUITY / INCOME / EXPENSE false none
» parentEntryId integer(int64) The Id of the GL Journal Entry that represents the interest accrual sum logged for all of the very same product false none
» productId string The id of the account's product false none
» productKey string The encoded key of the account's product false none
» productType string The type of Product (Loan or Deposit) false none
» transactionId string The Id of the Journal Entry transaction false none

Enumerated Values

Property Value
code AED
code AFN
code ALL
code AMD
code ANG
code AOA
code ARS
code AUD
code AWG
code AZN
code BAM
code BBD
code BDT
code BGN
code BHD
code BIF
code BMD
code BND
code BOB
code BOV
code BRL
code BSD
code BTC
code BTN
code BWP
code BYR
code BYN
code BZD
code CAD
code CDF
code CHF
code CLP
code CNY
code COP
code COU
code CRC
code CUC
code CUP
code CVE
code CZK
code DJF
code DKK
code DOP
code DZD
code EGP
code ERN
code ETB
code EUR
code FJD
code FKP
code GBP
code GEL
code GHS
code GIP
code GMD
code GNF
code GTQ
code GYD
code HKD
code HNL
code HRK
code HTG
code HUF
code IDR
code ILS
code INR
code IQD
code IRR
code ISK
code JMD
code JOD
code JPY
code KES
code KGS
code KHR
code KMF
code KPW
code KRW
code KWD
code KYD
code KZT
code LAK
code LBP
code LKR
code LRD
code LSL
code LTL
code LVL
code LYD
code MAD
code MDL
code MGA
code MKD
code MMK
code MNT
code MOP
code MRO
code MUR
code MVR
code MWK
code MXN
code MYR
code MZN
code NAD
code NGN
code NIO
code NOK
code NPR
code NZD
code OMR
code PAB
code PEN
code PGK
code PHP
code PKR
code PLN
code PYG
code QAR
code RON
code RSD
code RUB
code RWF
code SAR
code SBD
code SCR
code SDG
code SEK
code SGD
code SHP
code SLL
code SOS
code SRD
code STD
code SYP
code SZL
code THB
code TJS
code TMT
code TND
code TOP
code TRY
code TTD
code TWD
code TZS
code UAH
code UGX
code USD
code UYU
code UZS
code VEF
code VND
code VUV
code WST
code XAF
code XCD
code XOF
code XPF
code YER
code ZAR
code ZMK
code ZWL
code ZMW
code SSP

Accounting Rates

Create Accounting Rates.

getAll (Accounting Rates)

Code samples

# You can also use wget
curl -X GET /currencies/{currencyCode}/accountingRates \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /currencies/{currencyCode}/accountingRates HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/currencies/{currencyCode}/accountingRates',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/currencies/{currencyCode}/accountingRates',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/currencies/{currencyCode}/accountingRates', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/currencies/{currencyCode}/accountingRates', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/currencies/{currencyCode}/accountingRates");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/currencies/{currencyCode}/accountingRates", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /currencies/{currencyCode}/accountingRates

Allows retrieval of Accounting Rates using various query parameters

Parameters

Name Type Description In Required
currencyCode string The Code of Currency path true
offset integer(int32) Pagination, index to start searching at when retrieving elements, used in combination with limit to paginate results query false
limit integer(int32) Pagination, the number of elements to retrieve, used in combination with offset to paginate results query false
paginationDetails string Flag specifying whether the pagination details should be provided in response headers. Please note that by default it is disabled (OFF), in order to improve the performance of the APIs query false
from string(date-time) The date and time of the Accounting Rates to search from query false
to string(date-time) The date and time of the Accounting Rates to search to query false

Enumerated Values

Parameter Value
paginationDetails ON
paginationDetails OFF

Example responses

200 Response

[
  {
    "encodedKey": "string",
    "endDate": "2016-09-06T13:37:50+03:00",
    "fromCurrencyCode": "string",
    "rate": 0,
    "startDate": "2016-09-06T13:37:50+03:00",
    "toCurrencyCode": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK Accounting Rates list retrieved Inline
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Currency not found ErrorResponse

Response Schema

Status Code 200

Name Type Description Required Restrictions
anonymous [AccountingRate] [Represents the conversion rate used in accounting to convert amounts from one currency to organisation currency] false none
» encodedKey string The encoded key of the accounting rate, auto generated, unique false read-only
» endDate string(date-time) Rate validity end date (as Organization Time) false none
» fromCurrencyCode string Organisation currency code false none
» rate number Value of rate to be used for accounting conversions false none
» startDate string(date-time) Rate validity start date (as Organization Time) false none
» toCurrencyCode string Foreign currency code false none

Response Headers

Status Header Type Format Description
200 Items-Limit integer int32 Pagination details, the requested page size
200 Items-Offset integer int32 Pagination details, the index of the first returned item
200 Items-Total integer int32 Pagination details, the total available items

create (Accounting Rates)

Code samples

# You can also use wget
curl -X POST /currencies/{currencyCode}/accountingRates \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /currencies/{currencyCode}/accountingRates HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/currencies/{currencyCode}/accountingRates',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/currencies/{currencyCode}/accountingRates',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/currencies/{currencyCode}/accountingRates', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/currencies/{currencyCode}/accountingRates', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/currencies/{currencyCode}/accountingRates");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/currencies/{currencyCode}/accountingRates", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /currencies/{currencyCode}/accountingRates

Create Accounting Rates

Body parameter

{
  "rate": 0,
  "startDate": "2016-09-06T13:37:50+03:00"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
currencyCode string The Code of Currency path true
body PostAccountingRateDTO Accounting Rate to be created body true

Example responses

201 Response

{
  "encodedKey": "string",
  "endDate": "2016-09-06T13:37:50+03:00",
  "fromCurrencyCode": "string",
  "rate": 0,
  "startDate": "2016-09-06T13:37:50+03:00",
  "toCurrencyCode": "string"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
201 Created Accounting Rate Created AccountingRate
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Currency not found ErrorResponse

Accounting Reports

Allows you to generate and retrieve accounting reports. More information on the types of reports available can be found in our accounting reports user guide article.

Once generated using the POST request, your reports will be accessible for 24 hours using the unique reportKey.

get (Accounting Reports)

Code samples

# You can also use wget
curl -X GET /accounting/reports/{reportKey} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /accounting/reports/{reportKey} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/accounting/reports/{reportKey}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/accounting/reports/{reportKey}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/accounting/reports/{reportKey}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/accounting/reports/{reportKey}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/accounting/reports/{reportKey}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/accounting/reports/{reportKey}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /accounting/reports/{reportKey}

Retrieve accounting report

Parameters

Name Type Description In Required
reportKey string The encoded key of the report path true

Example responses

200 Response

{
  "items": [
    {
      "amounts": {
        "closingBalance": 0,
        "credits": 0,
        "debits": 0,
        "netChange": 0,
        "openingBalance": 0
      },
      "foreignAmounts": {
        "closingBalance": 0,
        "credits": 0,
        "debits": 0,
        "netChange": 0,
        "openingBalance": 0
      },
      "glAccount": {
        "activated": true,
        "allowManualJournalEntries": true,
        "balance": 0,
        "creationDate": "2016-09-06T13:37:50+03:00",
        "currency": {
          "code": "AED"
        },
        "description": "string",
        "encodedKey": "string",
        "glCode": "string",
        "lastModifiedDate": "2016-09-06T13:37:50+03:00",
        "migrationEventKey": "string",
        "name": "string",
        "stripTrailingZeros": true,
        "type": "ASSET",
        "usage": "DETAIL"
      }
    }
  ],
  "reportKey": "string",
  "status": "QUEUED"
}

Responses

Status Meaning Description Schema
200 OK Accounting report retrieved AccountingReport
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Report not found ErrorResponse

create (Accounting Reports)

Code samples

# You can also use wget
curl -X POST /accounting/reports \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /accounting/reports HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/accounting/reports',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/accounting/reports',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/accounting/reports', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/accounting/reports', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/accounting/reports");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/accounting/reports", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /accounting/reports

Generate accounting report

Body parameter

{
  "balanceTypes": [
    "OPENING_BALANCE"
  ],
  "branchId": "string",
  "currencyCode": "string",
  "endDate": "1987-04-26",
  "glTypes": [
    "ASSET"
  ],
  "startDate": "1987-04-26"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
body AccountingReportGenerationInput Input for accounting report generation to be started body true

Example responses

202 Response

{
  "reportKey": "string",
  "status": "QUEUED"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
202 Accepted Accounting report generation started AccountingReportGenerationResponse
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Currency not found ErrorResponse

Accounting Rules Configuration

Retrieve and update the configuration for accounting rules.

Accounting rules allows you to create general rules for your accounts such as setting automatic accounting closures that recur on a regular basis and defining rules for how to handle any transactions that affect GL balances in two different branches. For more information about this resource, see Accounting Rules Configuration in our User Guide.

get (Accounting Rules Configuration)

Code samples

# You can also use wget
curl -X GET /configuration/accountingrules.yaml \
  -H 'Accept: application/vnd.mambu.v2+yaml'

GET /configuration/accountingrules.yaml HTTP/1.1

Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/accountingrules.yaml',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.get '/configuration/accountingrules.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.get('/configuration/accountingrules.yaml', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/configuration/accountingrules.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/accountingrules.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/configuration/accountingrules.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /configuration/accountingrules.yaml

Retrieve current accounting rules configuration.

Example responses

An example of accounting rules

---
defaultGlCode: "defaultGlAccountCode"
automatedAccountingClosuresInterval: 7
customRules:
  - id: "ruleId1"
    leftBranchId: "branchId1"
    rightBranchId: "branchId2"
    glCode: "glCode1"
  - id: "ruleId2"
    leftBranchId: "branchId3"
    rightBranchId: "branchId1"
    glCode: "glCode2"

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Accounting rules configuration retrieved AccountingRulesConfiguration
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

update (Accounting Rules Configuration)

Code samples

# You can also use wget
curl -X PUT /configuration/accountingrules.yaml \
  -H 'Content-Type: application/yaml' \
  -H 'Accept: application/vnd.mambu.v2+yaml'

PUT /configuration/accountingrules.yaml HTTP/1.1

Content-Type: application/yaml
Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Content-Type':'application/yaml',
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/accountingrules.yaml',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/yaml',
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.put '/configuration/accountingrules.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/yaml',
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.put('/configuration/accountingrules.yaml', params={

}, headers = headers)

print r.json()

 'application/yaml',
    'Accept' => 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','/configuration/accountingrules.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/accountingrules.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/yaml"},
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "/configuration/accountingrules.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /configuration/accountingrules.yaml

Update the current accounting rules configuration

Body parameter

An example of accounting rules

---
defaultGlCode: "defaultGlAccountCode"
automatedAccountingClosuresInterval: 7
customRules:
  - id: "ruleId1"
    leftBranchId: "branchId1"
    rightBranchId: "branchId2"
    glCode: "glCode1"
  - id: "ruleId2"
    leftBranchId: "branchId3"
    rightBranchId: "branchId1"
    glCode: "glCode2"

Parameters

Name Type Description In Required
body AccountingRulesConfiguration Representation of the accounting rules configuration body false

Example responses

200 - Success Response

---
warnings: []

400 Invalid Syntax

{
    "errors": [
        {
            "errorCode": 10000,
            "errorSource": "customRules: while scanning a simple key",
            "errorReason": "INVALID_YAML_SYNTAX"
        }
    ]
}

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

404 not found

{
    "errors": [
        {
            "errorCode": 3,
            "errorSource": "server",
            "errorReason": "INVALID_API_OPERATION"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Accounting rules configuration updated. None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Accounting rules configuration not found. ErrorResponse

Response Schema

API Consumers

Allows you to manage API Consumers and their keys.

rotateKey (API Consumers)

Code samples

# You can also use wget
curl -X POST /apikey/rotation \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'secretkey: string'

POST /apikey/rotation HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
secretkey: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'secretkey':'string'

};

$.ajax({
  url: '/apikey/rotation',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'secretkey' => 'string'
}

result = RestClient.post '/apikey/rotation',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'secretkey': 'string'
}

r = requests.post('/apikey/rotation', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'secretkey' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/apikey/rotation', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/apikey/rotation");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "secretkey": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/apikey/rotation", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /apikey/rotation

Allows rotation of an existing apikey. The rotation operation invalidates the existing apikey and the secretkey used and returns a new apikey together with the new secretkey

Body parameter

{
  "apiKey": "string",
  "expirationTime": 100000000,
  "id": "string"
}

Parameters

Name Type Description In Required
secretkey string Secret key used to authenticate to this endpoint in order to perform a rotate key operation header true
body ApiKey Represents the action of rotating an existing apikey, by providing the apikey to be rotated and the TTL (time to live) of the newly created apikey. If a TTL is set in Preferences, it will have priority over the one provided in the API. If no TTL is set in Preferences and none is provided in the API, the generated key will have unlimited TTL by default. body false

Example responses

200 Response

{
  "apiKey": "string",
  "secretKey": "string"
}

Responses

Status Meaning Description Schema
200 OK Api key rotated successfully. ApiKeyRotationResult
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

getApiKeysByConsumerId (API Consumers)

Code samples

# You can also use wget
curl -X GET /consumers/{apiConsumerId}/apikeys \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /consumers/{apiConsumerId}/apikeys HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/consumers/{apiConsumerId}/apikeys',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/consumers/{apiConsumerId}/apikeys',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/consumers/{apiConsumerId}/apikeys', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/consumers/{apiConsumerId}/apikeys', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}/apikeys");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/consumers/{apiConsumerId}/apikeys", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /consumers/{apiConsumerId}/apikeys

Allows retrieval of the API Keys of an API Consumer

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer path true

Example responses

200 Response

[
  {
    "apiKey": "string",
    "expirationTime": 100000000,
    "id": "string"
  }
]

Responses

Status Meaning Description Schema
200 OK API Keys retrieved Inline
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer not found ErrorResponse

Response Schema

Status Code 200

Name Type Description Required Restrictions
anonymous [ApiKey] [Representation of an API Consumer's API Key] false none
» apiKey string The api key false none
» expirationTime integer(int32) The time to live for the rotated key false none
» id string The api key ID false none

createApiKeyForConsumer (API Consumers)

Code samples

# You can also use wget
curl -X POST /consumers/{apiConsumerId}/apikeys \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json'

POST /consumers/{apiConsumerId}/apikeys HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/consumers/{apiConsumerId}/apikeys',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.post '/consumers/{apiConsumerId}/apikeys',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.post('/consumers/{apiConsumerId}/apikeys', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/consumers/{apiConsumerId}/apikeys', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}/apikeys");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/consumers/{apiConsumerId}/apikeys", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /consumers/{apiConsumerId}/apikeys

Create a new API key for the API Consumer.

Body parameter

{
  "expirationTime": 100000000
}

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer path true
body ApiKeyInput API key expiration time in seconds. body false

Example responses

201 Response

{
  "apiKey": "string",
  "expirationTime": 100000000,
  "id": "string"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
201 Created API key created. ApiKey
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer not found ErrorResponse

getById (API Consumers)

Code samples

# You can also use wget
curl -X GET /consumers/{apiConsumerId} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /consumers/{apiConsumerId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/consumers/{apiConsumerId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/consumers/{apiConsumerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/consumers/{apiConsumerId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/consumers/{apiConsumerId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/consumers/{apiConsumerId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /consumers/{apiConsumerId}

Allows retrieval of a single API Consumer via id or encoded key

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer path true

Example responses

200 Response

{
  "access": {
    "administratorAccess": true,
    "apiAccess": true,
    "canManageAllBranches": true,
    "canManageEntitiesAssignedToOtherOfficers": true,
    "creditOfficerAccess": true,
    "managedBranches": [
      {
        "branchKey": "string"
      }
    ],
    "permissions": [
      "AUDIT_TRANSACTIONS"
    ]
  },
  "assignedBranchKey": "string",
  "creationDate": "2016-09-06T13:37:50+03:00",
  "encodedKey": "string",
  "id": "string",
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "name": "string",
  "role": {
    "encodedKey": "string",
    "id": "string"
  },
  "transactionLimits": {
    "property1": 0,
    "property2": 0
  },
  "type": "STREAMING_API"
}

Responses

Status Meaning Description Schema
200 OK API Consumer retrieved ApiConsumer
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer not found ErrorResponse

update (API Consumers)

Code samples

# You can also use wget
curl -X PUT /consumers/{apiConsumerId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

PUT /consumers/{apiConsumerId} HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/consumers/{apiConsumerId}',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.put '/consumers/{apiConsumerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.put('/consumers/{apiConsumerId}', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','/consumers/{apiConsumerId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "/consumers/{apiConsumerId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /consumers/{apiConsumerId}

Update an existing API Consumer

Body parameter

{
  "access": {
    "administratorAccess": true,
    "canManageAllBranches": true,
    "canManageEntitiesAssignedToOtherOfficers": true,
    "creditOfficerAccess": true,
    "managedBranches": [
      {}
    ],
    "permissions": [
      "AUDIT_TRANSACTIONS"
    ]
  },
  "assignedBranchKey": "string",
  "name": "string",
  "role": {
    "id": "string"
  },
  "transactionLimits": {
    "property1": 0,
    "property2": 0
  },
  "type": "STREAMING_API"
}

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer to be updated path true
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
body ApiConsumer API Consumer to be updated body true

Example responses

200 Response

{
  "access": {
    "administratorAccess": true,
    "apiAccess": true,
    "canManageAllBranches": true,
    "canManageEntitiesAssignedToOtherOfficers": true,
    "creditOfficerAccess": true,
    "managedBranches": [
      {
        "branchKey": "string"
      }
    ],
    "permissions": [
      "AUDIT_TRANSACTIONS"
    ]
  },
  "assignedBranchKey": "string",
  "creationDate": "2016-09-06T13:37:50+03:00",
  "encodedKey": "string",
  "id": "string",
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "name": "string",
  "role": {
    "encodedKey": "string",
    "id": "string"
  },
  "transactionLimits": {
    "property1": 0,
    "property2": 0
  },
  "type": "STREAMING_API"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
200 OK API Consumer updated ApiConsumer
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer not found ErrorResponse

delete (API Consumers)

Code samples

# You can also use wget
curl -X DELETE /consumers/{apiConsumerId} \
  -H 'Accept: application/vnd.mambu.v2+json'

DELETE /consumers/{apiConsumerId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/consumers/{apiConsumerId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.delete '/consumers/{apiConsumerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.delete('/consumers/{apiConsumerId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','/consumers/{apiConsumerId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "/consumers/{apiConsumerId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /consumers/{apiConsumerId}

Delete an existing API Consumer

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer to be deleted path true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
204 No Content API Consumer deleted None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer not found ErrorResponse

patch (API Consumers)

Code samples

# You can also use wget
curl -X PATCH /consumers/{apiConsumerId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

PATCH /consumers/{apiConsumerId} HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/consumers/{apiConsumerId}',
  method: 'patch',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.patch '/consumers/{apiConsumerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.patch('/consumers/{apiConsumerId}', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','/consumers/{apiConsumerId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "/consumers/{apiConsumerId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /consumers/{apiConsumerId}

Partially update an existing API Consumer

Body parameter

[
  {
    "from": "string",
    "op": "ADD",
    "path": "string",
    "value": {}
  }
]

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer to be updated path true
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
body PatchOperation Patch operations to be applied to a resource body true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
204 No Content API Consumer updated None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer not found ErrorResponse

deleteApiKeyForConsumer (API Consumers)

Code samples

# You can also use wget
curl -X DELETE /consumers/{apiConsumerId}/apikeys/{apiKeyId} \
  -H 'Accept: application/vnd.mambu.v2+json'

DELETE /consumers/{apiConsumerId}/apikeys/{apiKeyId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/consumers/{apiConsumerId}/apikeys/{apiKeyId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.delete '/consumers/{apiConsumerId}/apikeys/{apiKeyId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.delete('/consumers/{apiConsumerId}/apikeys/{apiKeyId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','/consumers/{apiConsumerId}/apikeys/{apiKeyId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}/apikeys/{apiKeyId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "/consumers/{apiConsumerId}/apikeys/{apiKeyId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /consumers/{apiConsumerId}/apikeys/{apiKeyId}

Delete an API key by it's id.

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer path true
apiKeyId string The id of the API key. path true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
204 No Content API key deleted. None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer or key not found ErrorResponse

getAll (API Consumers)

Code samples

# You can also use wget
curl -X GET /consumers \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /consumers HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/consumers',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/consumers',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/consumers', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/consumers', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/consumers", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /consumers

Allows retrieval of API Consumers and query them by type

Parameters

Name Type Description In Required
offset integer(int32) Pagination, index to start searching at when retrieving elements, used in combination with limit to paginate results query false
limit integer(int32) Pagination, the number of elements to retrieve, used in combination with offset to paginate results query false
paginationDetails string Flag specifying whether the pagination details should be provided in response headers. Please note that by default it is disabled (OFF), in order to improve the performance of the APIs query false
type string The type of API Consumer to search by query false

Enumerated Values

Parameter Value
paginationDetails ON
paginationDetails OFF
type STREAMING_API
type AUDIT_TRAIL
type PAYMENTS
type MAMBU_API

Example responses

200 Response

[
  {
    "access": {
      "administratorAccess": true,
      "apiAccess": true,
      "canManageAllBranches": true,
      "canManageEntitiesAssignedToOtherOfficers": true,
      "creditOfficerAccess": true,
      "managedBranches": [
        {
          "branchKey": "string"
        }
      ],
      "permissions": [
        "AUDIT_TRANSACTIONS"
      ]
    },
    "assignedBranchKey": "string",
    "creationDate": "2016-09-06T13:37:50+03:00",
    "encodedKey": "string",
    "id": "string",
    "lastModifiedDate": "2016-09-06T13:37:50+03:00",
    "name": "string",
    "role": {
      "encodedKey": "string",
      "id": "string"
    },
    "transactionLimits": {
      "property1": 0,
      "property2": 0
    },
    "type": "STREAMING_API"
  }
]

Responses

Status Meaning Description Schema
200 OK API Consumers list retrieved Inline
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

Response Schema

Status Code 200

Name Type Description Required Restrictions
anonymous [ApiConsumer] [Api Consumer containing keys that can be used to access mambu API] false none
» access ApiConsumerAccess Wrapper containing the available API Consumer permissions and access rights false none
»» administratorAccess boolean Whether the API Consumer is an administrator in Mambu. The administrators in mambu are having full permissions for all entities and for Mambu settings. false none
»» apiAccess boolean API access allows the API Consumer to authenticate and interact with Mambu using Mambu's APIs, this means that most of the time such an API Consumer is not an actual person, but a piece of software that is programmed to interact with Mambu. The API API Consumer would still require the right API Consumer permissions, depending on what it is required to do in the system, and transactions posted by that API Consumer are kept in the logs in the same way as API Consumer actions from regular users. false read-only
»» canManageAllBranches boolean Whether the API Consumer permissions apply to all branches or only for some branches false none
»» canManageEntitiesAssignedToOtherOfficers boolean Flag specific to Credit Officers determining the access to entities assigned to other Credit Officers (eg clients, accounts) false none
»» creditOfficerAccess boolean Whether the API Consumer is a credit officer or not. Credit Officers have the option of having clients and groups assigned to them, this relationship allows for better reporting and client management. false none
»» managedBranches [UserManagedBranch] The list of branches that can be managed by current API Consumer. If the API Consumer has the canManageAllBranches true, this list is not taken in consideration. false none
»»» branchKey string The encoded key of the branch, generated false read-only
»» permissions [string] Permissions for the API Consumer. The non-admin users are authorized to do actions based a set of permissions in order to access Mambu features. Note that not all this permissions are used for validating API calls, some are used only for UI validations false none
» assignedBranchKey string The encoded key of the branch this Api Consumer is assigned to. false none
» creationDate string(date-time) Date when the Api Consumer was created, as UTC false read-only
» encodedKey string The encoded key of the entity, generated, globally unique false read-only
» id string Id of the Api Consumer false read-only
» lastModifiedDate string(date-time) The last time Api Consumer was modified, as UTC false read-only
» name string Api Consumer name true none
» role RoleIdentifier The user role identifier false none
»» encodedKey string The encoded key of the entity, generated, globally unique false read-only
»» id string Id of the role, unique, can be generated and customized false none
» transactionLimits object Map of specifying Api Consumer transaction limits. false none
»» additionalProperties integer(int32) none false none
» type string The type of Api Consumer true none

Enumerated Values

Property Value
type STREAMING_API
type AUDIT_TRAIL
type PAYMENTS
type MAMBU_API

Response Headers

Status Header Type Format Description
200 Items-Limit integer int32 Pagination details, the requested page size
200 Items-Offset integer int32 Pagination details, the index of the first returned item
200 Items-Total integer int32 Pagination details, the total available items

create (API Consumers)

Code samples

# You can also use wget
curl -X POST /consumers \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /consumers HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/consumers',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/consumers',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/consumers', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/consumers', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/consumers", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /consumers

Create a new API Consumer

Body parameter

{
  "access": {
    "administratorAccess": true,
    "canManageAllBranches": true,
    "canManageEntitiesAssignedToOtherOfficers": true,
    "creditOfficerAccess": true,
    "managedBranches": [
      {}
    ],
    "permissions": [
      "AUDIT_TRANSACTIONS"
    ]
  },
  "assignedBranchKey": "string",
  "name": "string",
  "role": {
    "id": "string"
  },
  "transactionLimits": {
    "property1": 0,
    "property2": 0
  },
  "type": "STREAMING_API"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
body ApiConsumer API Consumer to be created body true

Example responses

201 Response

{
  "access": {
    "administratorAccess": true,
    "apiAccess": true,
    "canManageAllBranches": true,
    "canManageEntitiesAssignedToOtherOfficers": true,
    "creditOfficerAccess": true,
    "managedBranches": [
      {
        "branchKey": "string"
      }
    ],
    "permissions": [
      "AUDIT_TRANSACTIONS"
    ]
  },
  "assignedBranchKey": "string",
  "creationDate": "2016-09-06T13:37:50+03:00",
  "encodedKey": "string",
  "id": "string",
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "name": "string",
  "role": {
    "encodedKey": "string",
    "id": "string"
  },
  "transactionLimits": {
    "property1": 0,
    "property2": 0
  },
  "type": "STREAMING_API"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
201 Created API Consumer created ApiConsumer
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

createSecretKeyForConsumer (API Consumers)

Code samples

# You can also use wget
curl -X POST /consumers/{apiConsumerId}/secretkeys \
  -H 'Accept: application/vnd.mambu.v2+json'

POST /consumers/{apiConsumerId}/secretkeys HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/consumers/{apiConsumerId}/secretkeys',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.post '/consumers/{apiConsumerId}/secretkeys',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.post('/consumers/{apiConsumerId}/secretkeys', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/consumers/{apiConsumerId}/secretkeys', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/consumers/{apiConsumerId}/secretkeys");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/consumers/{apiConsumerId}/secretkeys", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /consumers/{apiConsumerId}/secretkeys

Create a new Secret key for the API Consumer.

Parameters

Name Type Description In Required
apiConsumerId string The id or encoded key of the API Consumer path true

Example responses

201 Response

{
  "secretKey": "string"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
201 Created Secret key created. SecretKey
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found API Consumer not found ErrorResponse

Authorization Holds Configuration

Retrieve and update the configuration for authorization holds.

An authorization hold is a standard practice with debit or a credit card transactions to hold a given balance as unavailable for the card holder until either the merchant settles the transaction, cancels the hold, or it expires. Using this endpoint you can configure the default authorization hold expiry for your organization as well as per merchant or merchant type using a Merchant Category Code (MCC). For more information about this resource, see Authorization Holds Configuration in our User Guide.

get (Authorization Holds Configuration)

Code samples

# You can also use wget
curl -X GET /configuration/authorizationholds.yaml \
  -H 'Accept: application/vnd.mambu.v2+yaml'

GET /configuration/authorizationholds.yaml HTTP/1.1

Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/authorizationholds.yaml',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.get '/configuration/authorizationholds.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.get('/configuration/authorizationholds.yaml', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/configuration/authorizationholds.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/authorizationholds.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/configuration/authorizationholds.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /configuration/authorizationholds.yaml

Retrieve authorization holds configuration

Example responses

Authorization Hold Settings

---
defaultAuthorizationHold:
  daysToExpiration: 7
authorizationHolds:
- mcc: 123
  daysToExpiration: 14
  description: "bullseye brand - contractually agreed expiration"
- mcc: 456
  daysToExpiration: 1
  description: "widgets'r'us - short expiration"

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Authorization holds configuration retrieved AuthorizationHoldsConfiguration
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

update (Authorization Holds Configuration)

Code samples

# You can also use wget
curl -X PUT /configuration/authorizationholds.yaml \
  -H 'Content-Type: application/yaml' \
  -H 'Accept: application/vnd.mambu.v2+yaml'

PUT /configuration/authorizationholds.yaml HTTP/1.1

Content-Type: application/yaml
Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Content-Type':'application/yaml',
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/authorizationholds.yaml',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/yaml',
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.put '/configuration/authorizationholds.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/yaml',
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.put('/configuration/authorizationholds.yaml', params={

}, headers = headers)

print r.json()

 'application/yaml',
    'Accept' => 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','/configuration/authorizationholds.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/authorizationholds.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/yaml"},
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "/configuration/authorizationholds.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /configuration/authorizationholds.yaml

Update the current authorization holds configuration

Body parameter

Authorization Hold Settings

---
defaultAuthorizationHold:
  daysToExpiration: 7
authorizationHolds:
- mcc: 123
  daysToExpiration: 14
  description: "bullseye brand - contractually agreed expiration"
- mcc: 456
  daysToExpiration: 1
  description: "widgets'r'us - short expiration"

Parameters

Name Type Description In Required
body AuthorizationHoldsConfiguration Represents the authorization holds body false

Example responses

200 - Success Response

---
warnings: []

400 - Example failure response

{
    "errors": [
        {
            "errorCode": 9957,
            "errorSource": "Days to expire value must be a positive number",
            "errorReason": "INVALID_DAYS_TO_EXPIRE_FOR_AUTHORIZATION_HOLD"
        }
    ]
}

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

404 not found

{
    "errors": [
        {
            "errorCode": 3,
            "errorSource": "server",
            "errorReason": "INVALID_API_OPERATION"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Authorization holds configuration updated. None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Authorization holds configuration not found. ErrorResponse

Response Schema

Branches

Allows you to retrieve branches which are being used by an organization.

getById (Branches)

Code samples

# You can also use wget
curl -X GET /branches/{branchId} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /branches/{branchId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/branches/{branchId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/branches/{branchId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/branches/{branchId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/branches/{branchId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/branches/{branchId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/branches/{branchId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /branches/{branchId}

Allows retrieval of a single the branch via id or encoded key

Parameters

Name Type Description In Required
branchId string The id or or encoded key of a branch path true
detailsLevel string The level of details to retrieve, FULL means the full details of the object will be retrieved (custom fields, address, contact info or any other related object), BASIC will return only the first level elements of the object query false

Enumerated Values

Parameter Value
detailsLevel BASIC
detailsLevel FULL

Example responses

200 Response

{
  "_Branch_Organization_Branches": {
    "Clients_Branches": "string",
    "Organization_Staff_Branches": "string"
  },
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Province_Branches": {
    "Outside_of_province_Branches": "TRUE",
    "Province_Branches": "Catamarca"
  },
  "_branches_grouped_cf_set": [
    {
      "cf_group_field_1": "string",
      "cf_group_field_2": "string"
    }
  ],
  "_example_branch_custom_field_set": {
    "cf_branch": "TRUE"
  },
  "addresses": [
    {
      "city": "string",
      "country": "string",
      "encodedKey": "string",
      "indexInList": 0,
      "latitude": 0,
      "line1": "string",
      "line2": "string",
      "longitude": 0,
      "parentKey": "string",
      "postcode": "string",
      "region": "string"
    }
  ],
  "branchHolidays": [
    {
      "creationDate": "2016-09-06T13:37:50+03:00",
      "date": "1987-04-26",
      "encodedKey": "string",
      "id": 0,
      "isAnnuallyRecurring": true,
      "name": "string"
    }
  ],
  "creationDate": "2016-09-06T13:37:50+03:00",
  "emailAddress": "string",
  "encodedKey": "string",
  "id": "string",
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "name": "string",
  "notes": "string",
  "phoneNumber": "string",
  "state": "ACTIVE"
}

Responses

Status Meaning Description Schema
200 OK Branch retrieved Branch
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Branch not found ErrorResponse

getAll (Branches)

Code samples

# You can also use wget
curl -X GET /branches \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /branches HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/branches',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/branches',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/branches', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/branches', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/branches");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/branches", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /branches

Allows retrieval of branches using various query parameters

Parameters

Name Type Description In Required
offset integer(int32) Pagination, index to start searching at when retrieving elements, used in combination with limit to paginate results query false
limit integer(int32) Pagination, the number of elements to retrieve, used in combination with offset to paginate results query false
paginationDetails string Flag specifying whether the pagination details should be provided in response headers. Please note that by default it is disabled (OFF), in order to improve the performance of the APIs query false
detailsLevel string The level of details to retrieve, FULL means the full details of the object will be retrieved (custom fields, address, contact info or any other related object), BASIC will return only the first level elements of the object query false
sortBy string The criteria based on which the records will be sorted. Expected format is , eg sortBy = field1:ASC,field2:DESC.
Only the following fields can be used: id,name, creationDate, lastModifiedDate
Default sorting is done by creationDate:DESC
query false

Enumerated Values

Parameter Value
paginationDetails ON
paginationDetails OFF
detailsLevel BASIC
detailsLevel FULL

Example responses

200 Response

[
  {
    "_Branch_Organization_Branches": {
      "Clients_Branches": "string",
      "Organization_Staff_Branches": "string"
    },
    "_Example_Custom_Fields": {
      "Example_Checkbox_Field": "TRUE",
      "Example_Free_Text_Field": "A free text field up to 255 characters in length",
      "Example_Number_Field": "46290",
      "Example_Select_Field": "Option 1"
    },
    "_Province_Branches": {
      "Outside_of_province_Branches": "TRUE",
      "Province_Branches": "Catamarca"
    },
    "_branches_grouped_cf_set": [
      {
        "cf_group_field_1": "string",
        "cf_group_field_2": "string"
      }
    ],
    "_example_branch_custom_field_set": {
      "cf_branch": "TRUE"
    },
    "addresses": [
      {
        "city": "string",
        "country": "string",
        "encodedKey": "string",
        "indexInList": 0,
        "latitude": 0,
        "line1": "string",
        "line2": "string",
        "longitude": 0,
        "parentKey": "string",
        "postcode": "string",
        "region": "string"
      }
    ],
    "branchHolidays": [
      {
        "creationDate": "2016-09-06T13:37:50+03:00",
        "date": "1987-04-26",
        "encodedKey": "string",
        "id": 0,
        "isAnnuallyRecurring": true,
        "name": "string"
      }
    ],
    "creationDate": "2016-09-06T13:37:50+03:00",
    "emailAddress": "string",
    "encodedKey": "string",
    "id": "string",
    "lastModifiedDate": "2016-09-06T13:37:50+03:00",
    "name": "string",
    "notes": "string",
    "phoneNumber": "string",
    "state": "ACTIVE"
  }
]

Responses

Status Meaning Description Schema
200 OK Branches list retrieved Inline
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

Response Schema

Status Code 200

Name Type Description Required Restrictions
anonymous [Branch] [Branch Date Transfer Object] false none
» _Branch_Organization_Branches object none false none
»» Clients_Branches string none false none
»» Organization_Staff_Branches string(number) none false none
» _Example_Custom_Fields object An Example of some custom fields, these should be configured for your instance using the Mambu UI. The examples in this object only represent a selection of the possible field types available. false none
»» Example_Checkbox_Field string A field that will appear as a checkbox in the UI. In the API value will be TRUE or FALSE as a string. Please note: the value must be provided as a string, not a boolean. false none
»» Example_Free_Text_Field string A field that can contain a string of text. Pay attention to proper JSON escaping if providing values for such fields via API. false none
»» Example_Number_Field string(number) A field supporting numbers only. Please note: the value is to be provided as a string. false none
»» Example_Select_Field string A custom field type supporting enumerated values. Requests will fail if the value provided for such a field is not one of the supported values. false none
» _Province_Branches object none false none
»» Outside_of_province_Branches string none false none
»» Province_Branches string none false none
» _branches_grouped_cf_set [_branches_grouped_cf_set] none false none
»» cf_group_field_1 string none false none
»» cf_group_field_2 string(number) none false none
» _example_branch_custom_field_set object example custom field set false none
»» cf_branch string an example custom field of the checkbox type false none
» addresses [Address] list of branch addresses false none
»» city string The city for this address false none
»» country string The country false none
»» encodedKey string Address encoded key, unique, generated false read-only
»» indexInList integer(int32) Index of this address in the list of addresses false none
»» latitude number The GPS latitude of this address in signed degrees format (DDD.dddd) with 6 decimal positions, ranging from -90 to +90 false none
»» line1 string The first line of the address false none
»» line2 string The second line for the address, in case the first one doesn't fit the information, this is completely optional false none
»» longitude number The GPS longitude of this address in signed degrees format (DDD.dddd) with 6 decimal positions, ranging from -180 to +180 false none
»» parentKey string Address parent key, the object owning this address, client, centre, branch false read-only
»» postcode string The post code false none
»» region string The region that is part of the address false none
» branchHolidays [Holiday] list of branch holidays false none
»» creationDate string(date-time) holiday creation date false none
»» date string(date) holiday date false none
»» encodedKey string The encoded key of the entity, generated, globally unique false read-only
»» id integer(int64) holiday id false none
»» isAnnuallyRecurring boolean if is annually recurring false none
»» name string holiday name false none
» creationDate string(date-time) creation date of the branch false none
» emailAddress string branch email address false none
» encodedKey string The encoded key of the entity, generated, globally unique false read-only
» id string branch ID, unique false none
» lastModifiedDate string(date-time) last date when the branch was modified false none
» name string branch name false none
» notes string notes about this branch false none
» phoneNumber string branch phone number, as a string false none
» state string branch state false none

Enumerated Values

Property Value
Example_Checkbox_Field TRUE
Example_Checkbox_Field FALSE
Example_Select_Field Option 1
Example_Select_Field Option 2
Example_Select_Field Option 3
Outside_of_province_Branches TRUE
Outside_of_province_Branches FALSE
Province_Branches Catamarca
Province_Branches Chaco
Province_Branches Jujuy
cf_branch TRUE
cf_branch FALSE
state ACTIVE
state INACTIVE

Response Headers

Status Header Type Format Description
200 Items-Limit integer int32 Pagination details, the requested page size
200 Items-Offset integer int32 Pagination details, the index of the first returned item
200 Items-Total integer int32 Pagination details, the total available items

Branches Configuration

Retrieve and update the configuration for branches.

A branch is the default label for an organization's subdivision. For more information about this resource, see Branches Configuration in our User Guide.

get (Branches Configuration)

Code samples

# You can also use wget
curl -X GET /configuration/branches.yaml \
  -H 'Accept: application/vnd.mambu.v2+yaml'

GET /configuration/branches.yaml HTTP/1.1

Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/branches.yaml',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.get '/configuration/branches.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.get('/configuration/branches.yaml', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/configuration/branches.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/branches.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/configuration/branches.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /configuration/branches.yaml

Retrieve branches configuration

Example responses

a single branch

---
- id: "demoBranchId"
  name: "Maputo Downtown"
  state: "ACTIVE"
  phoneNumber: "0049302345678"
  emailAddress: "petula.clark@downtown.com"
  notes: "Is located in the surroundings of the local market with a <i>lot of potential</i>\
    \ to reach new clients."
  holidays:
  - id: 12
    name: "only maputo holiday day"
    dayOfMonth: 30
    monthOfYear: 7
    year: 2020
    isAnnuallyRecurring: true
  customFieldValueSets:
  - id: "_branches_grouped_cf_set"
    groupedCustomFieldValues:
    - index: 0
      customFieldValues:
      - customFieldId: "cf_group_field_1"
        value: "group field 1"
      - customFieldId: "cf_group_field_2"
        value: "2"
    - index: 1
      customFieldValues:
      - customFieldId: "cf_group_field_2"
        value: "500"
  - id: "_example_branch_custom_field_set"
    standardCustomFieldValues:
    - customFieldId: "cf_branch"
      value: "TRUE"

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Branches configuration retrieved. BranchesConfiguration
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

update (Branches Configuration)

Code samples

# You can also use wget
curl -X PUT /configuration/branches.yaml \
  -H 'Content-Type: application/yaml' \
  -H 'Accept: application/vnd.mambu.v2+yaml'

PUT /configuration/branches.yaml HTTP/1.1

Content-Type: application/yaml
Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Content-Type':'application/yaml',
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/branches.yaml',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/yaml',
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.put '/configuration/branches.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/yaml',
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.put('/configuration/branches.yaml', params={

}, headers = headers)

print r.json()

 'application/yaml',
    'Accept' => 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','/configuration/branches.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/branches.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/yaml"},
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "/configuration/branches.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /configuration/branches.yaml

Update the current branch configuration

Body parameter

example array of branches

---
branches:
- id: "2"
  name: "Matola City"
  state: "ACTIVE"
  phoneNumber: "+7534987676"
  emailAddress: "matola@BofAlg.es"
  notes: "Is currently under construction to add an extra room that can be used for\
    \ the meetings.<p></p>Have <b>six new computers</b> for their staff."
  address:
    line1: "1 Bank Street"
    line2: "Old Town"
    city: "Matola City"
    region: "Matola"
    postcode: "10775"
    country: "Bankistan"
  holidays:
  - id: 13
    name: "joe matola only day"
    dayOfMonth: 26
    monthOfYear: 8
    year: 2020
    isAnnuallyRecurring: true
- id: "demoBranchId"
  name: "Maputo Downtown"
  state: "ACTIVE"
  phoneNumber: "0049302345678"
  emailAddress: "petula.clark@downtown.com"
  notes: "Is located in the surroundings of the local market with a <i>lot of potential</i>\
    \ to reach new clients."
  holidays:
  - id: 12
    name: "only maputo holiday day"
    dayOfMonth: 30
    monthOfYear: 7
    year: 2020
    isAnnuallyRecurring: true
  customFieldValueSets:
  - id: "_branches_grouped_cf_set"
    groupedCustomFieldValues:
    - index: 0
      customFieldValues:
      - customFieldId: "cf_group_field_1"
        value: "group field 1"
      - customFieldId: "cf_group_field_2"
        value: "2"
    - index: 1
      customFieldValues:
      - customFieldId: "cf_group_field_2"
        value: "500"
  - id: "_example_branch_custom_field_set"
    standardCustomFieldValues:
    - customFieldId: "cf_branch"
      value: "TRUE"

Parameters

Name Type Description In Required
body BranchesConfiguration Model representation of the branches configuration body false

Example responses

200 success response

---
warnings: []

400 error response

{
    "errors": [
        {
            "errorCode": 0,
            "errorSource": "human-readable description of the error",
            "errorReason": "SOURCE_OF_ERROR"
        }
    ]
}

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

404 not found

{
    "errors": [
        {
            "errorCode": 3,
            "errorSource": "server",
            "errorReason": "INVALID_API_OPERATION"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Branches configuration updated. None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Branches configuration not found. ErrorResponse

Response Schema

Bulk Transactions

Allows you to query the results of bulk operations/background process.

The scope of this API is to get the status of the entire bulk and also return the list of successful transactions and the list of the transactions resulting in error.

Since bulk operations work as independent transactions, it can happen that some of the operations were successful while others failed.

This API can be used for example to get the status of bulk deposit transactions (see /deposits/deposit-transactions:bulk).

getBulkStatus (Bulk Transactions)

Code samples

# You can also use wget
curl -X GET /bulks/{bulkProcessKey} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /bulks/{bulkProcessKey} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/bulks/{bulkProcessKey}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/bulks/{bulkProcessKey}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/bulks/{bulkProcessKey}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/bulks/{bulkProcessKey}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/bulks/{bulkProcessKey}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/bulks/{bulkProcessKey}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /bulks/{bulkProcessKey}

Allow retrieval the status of a bulk process via key

Parameters

Name Type Description In Required
bulkProcessKey string The identifier of the bulk process path true

Example responses

200 Response

{
  "errors": [
    {
      "errorCode": 400,
      "errorReason": "INVALID_SAVINGS_ACCOUNT_ID",
      "errorSource": "The supplied savings/deposit account ID does not exist",
      "externalId": "6789",
      "indexInRequest": 2
    }
  ],
  "processedItems": [
    {
      "externalId": "1234-abc",
      "id": "2873",
      "indexInRequest": 0
    },
    {
      "externalId": "5678-def",
      "id": "2874",
      "indexInRequest": 1
    }
  ],
  "status": "IN_PROGRESS"
}

Responses

Status Meaning Description Schema
200 OK Bulk process status retrieved BulkProcessStatus
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Bulk process key invalid ErrorResponse

Cards

Allows CRUD operations on card references and their associated items.

increaseAuthorizationHold (Cards)

Code samples

# You can also use wget
curl -X POST /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:increase

Increases the amount of an authorization hold.

Body parameter

{
  "advice": true,
  "amount": 0,
  "currencyCode": "string",
  "externalReferenceId": "string"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
cardReferenceToken string The token used to externally identify the card. path true
authorizationHoldExternalReferenceId string The ID used to reference the authorization hold. path true
body AuthorizationHoldAmountAdjustmentRequest The request containing the necessary fields to increase the amount of an authorization hold. body true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
204 No Content The authorization hold was successfully increased. None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Card or authorization hold not found. ErrorResponse

getAuthorizationHoldById (Cards)

Code samples

# You can also use wget
curl -X GET /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}

Allows retrieval of a single authorization hold via id or encoded key

Parameters

Name Type Description In Required
cardReferenceToken string The token used to externally identify the card. path true
authorizationHoldExternalReferenceId string The ID used to reference the authorization hold. path true

Example responses

200 Response

{
  "advice": true,
  "amount": 0,
  "cardAcceptor": {
    "city": "string",
    "country": "string",
    "mcc": 0,
    "name": "string",
    "state": "string",
    "street": "string",
    "zip": "string"
  },
  "cardToken": "string",
  "creditDebitIndicator": "DBIT",
  "currencyCode": "string",
  "encodedKey": "string",
  "exchangeRate": 0,
  "externalReferenceId": "string",
  "originalAmount": 0,
  "originalCurrency": "string",
  "status": "PENDING",
  "userTransactionTime": "string"
}

Responses

Status Meaning Description Schema
200 OK Authorization hold retrieved. GetAuthorizationHold
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Card not found. ErrorResponse

reverseAuthorizationHold (Cards)

Code samples

# You can also use wget
curl -X DELETE /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId} \
  -H 'Accept: application/vnd.mambu.v2+json'

DELETE /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.delete '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.delete('/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}

Reverses an authorization hold.

Parameters

Name Type Description In Required
cardReferenceToken string The token used to externally identify the card. path true
authorizationHoldExternalReferenceId string The ID used to reference the authorization hold. path true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
204 No Content The authorization hold was successfully reversed. None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Card or authorization hold not found. ErrorResponse

reverseCardTransaction (Cards)

Code samples

# You can also use wget
curl -X POST /cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /cards/{cardReferenceToken}/financialtransactions/{cardTransactionExternalReferenceId}:decrease

Reverses a card transaction.

Body parameter

{
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Transaction_Details_Transaction": {
    "ACCOUNT_NAME_TRANSACTION_CHANNEL": "string",
    "ACCOUNT_NUMBER_TRANSACTION_CHANN": "string",
    "BANK_NUMBER_TRANSACTION_CHANNEL_": "string",
    "IDENTIFIER_TRANSACTION_CHANNEL_I": "string",
    "RECEPIT_NUMBER_TRANSACTION_CHANN": "string",
    "ROUTING_NUMBER_TRANSACTION_CHANN": "string",
    "nonreq": "TRUE",
    "req": "string"
  },
  "amount": 0,
  "currencyCode": "string",
  "externalReferenceId": "string",
  "transactionChannelId": "string"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
cardReferenceToken string The token used to externally identify the card. path true
cardTransactionExternalReferenceId string The external reference of a card transaction used to identify the card transaction. path true
body CardTransactionReversal The card transaction to be reversed. body true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
204 No Content The card reversal was successfully completed None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Card not found. ErrorResponse

getAccountBalances (Cards)

Code samples

# You can also use wget
curl -X GET /cards/{cardReferenceToken}/balanceInquiry \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /cards/{cardReferenceToken}/balanceInquiry HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/balanceInquiry',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/cards/{cardReferenceToken}/balanceInquiry',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/cards/{cardReferenceToken}/balanceInquiry', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/cards/{cardReferenceToken}/balanceInquiry', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/balanceInquiry");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/cards/{cardReferenceToken}/balanceInquiry", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /cards/{cardReferenceToken}/balanceInquiry

Allows retrieval of account balances by its card token

Parameters

Name Type Description In Required
cardReferenceToken string The token used to externally identify the card. path true

Example responses

200 Response

{
  "accountId": "string",
  "availableBalance": 0,
  "cardType": "DEBIT",
  "creditLimit": 0,
  "currencyCode": "string",
  "totalBalance": 0
}

Responses

Status Meaning Description Schema
200 OK Card's account balances retrieved AccountBalances
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found CARD_REFERENCE_NOT_FOUND ErrorResponse

createCardTransaction (Cards)

Code samples

# You can also use wget
curl -X POST /cards/{cardReferenceToken}/financialtransactions \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /cards/{cardReferenceToken}/financialtransactions HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/financialtransactions',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/cards/{cardReferenceToken}/financialtransactions',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/cards/{cardReferenceToken}/financialtransactions', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/cards/{cardReferenceToken}/financialtransactions', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/financialtransactions");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/cards/{cardReferenceToken}/financialtransactions", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /cards/{cardReferenceToken}/financialtransactions

Creates a financial transaction corresponding to a given card.

Body parameter

{
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Transaction_Details_Transaction": {
    "ACCOUNT_NAME_TRANSACTION_CHANNEL": "string",
    "ACCOUNT_NUMBER_TRANSACTION_CHANN": "string",
    "BANK_NUMBER_TRANSACTION_CHANNEL_": "string",
    "IDENTIFIER_TRANSACTION_CHANNEL_I": "string",
    "RECEPIT_NUMBER_TRANSACTION_CHANN": "string",
    "ROUTING_NUMBER_TRANSACTION_CHANN": "string",
    "nonreq": "TRUE",
    "req": "string"
  },
  "advice": true,
  "amount": 0,
  "cardAcceptor": {
    "city": "string",
    "country": "string",
    "mcc": 0,
    "name": "string",
    "state": "string",
    "street": "string",
    "zip": "string"
  },
  "currencyCode": "string",
  "externalAuthorizationReferenceId": "string",
  "externalReferenceId": "string",
  "firstRepaymentDate": "2016-09-06T13:37:50+03:00",
  "increaseAmountIfNeeded": true,
  "transactionChannelId": "string",
  "userTransactionTime": "string"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
cardReferenceToken string The token used to externally identify the card. path true
body CardTransactionInput The financial transaction to be created. body true

Example responses

201 Response

{
  "advice": true,
  "amount": 0,
  "cardAcceptor": {
    "city": "string",
    "country": "string",
    "mcc": 0,
    "name": "string",
    "state": "string",
    "street": "string",
    "zip": "string"
  },
  "cardToken": "string",
  "currencyCode": "string",
  "encodedKey": "string",
  "externalAuthorizationReferenceId": "string",
  "externalReferenceId": "string",
  "firstRepaymentDate": "2016-09-06T13:37:50+03:00",
  "increaseAmountIfNeeded": true,
  "linkedTransaction": {
    "linkedTransactionKey": "string",
    "linkedTransactionType": "LOAN"
  },
  "transactionChannelId": "string",
  "userTransactionTime": "string"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
201 Created The financial transaction was successfully created. CardTransactionOutput
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Card not found. ErrorResponse

decreaseAuthorizationHold (Cards)

Code samples

# You can also use wget
curl -X POST /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /cards/{cardReferenceToken}/authorizationholds/{authorizationHoldExternalReferenceId}:decrease

Decreases the amount of an authorization hold. If the amount is greater or equal to the authorization hold amount, then the authorization hold is reversed.

Body parameter

{
  "advice": true,
  "amount": 0,
  "currencyCode": "string",
  "externalReferenceId": "string"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
cardReferenceToken string The token used to externally identify the card. path true
authorizationHoldExternalReferenceId string The ID used to reference the authorization hold. path true
body AuthorizationHoldAmountAdjustmentRequest The request containing the necessary fields to decrease the amount of an authorization hold. body true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
204 No Content The authorization hold was successfully decreased. None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Card or authorization hold not found. ErrorResponse

createAuthorizationHold (Cards)

Code samples

# You can also use wget
curl -X POST /cards/{cardReferenceToken}/authorizationholds \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /cards/{cardReferenceToken}/authorizationholds HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/cards/{cardReferenceToken}/authorizationholds',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/cards/{cardReferenceToken}/authorizationholds',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/cards/{cardReferenceToken}/authorizationholds', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/cards/{cardReferenceToken}/authorizationholds', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/cards/{cardReferenceToken}/authorizationholds");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/cards/{cardReferenceToken}/authorizationholds", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /cards/{cardReferenceToken}/authorizationholds

Creates an authorization hold corresponding to a given card.

Body parameter

{
  "advice": true,
  "amount": 0,
  "cardAcceptor": {
    "city": "string",
    "country": "string",
    "mcc": 0,
    "name": "string",
    "state": "string",
    "street": "string",
    "zip": "string"
  },
  "creditDebitIndicator": "DBIT",
  "currencyCode": "string",
  "exchangeRate": 0,
  "externalReferenceId": "string",
  "originalAmount": 0,
  "originalCurrency": "string",
  "userTransactionTime": "string"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
cardReferenceToken string The token used to externally identify the card. path true
body AuthorizationHold The authorization hold to be created. body true

Example responses

201 Response

{
  "advice": true,
  "amount": 0,
  "cardAcceptor": {
    "city": "string",
    "country": "string",
    "mcc": 0,
    "name": "string",
    "state": "string",
    "street": "string",
    "zip": "string"
  },
  "cardToken": "string",
  "creditDebitIndicator": "DBIT",
  "currencyCode": "string",
  "exchangeRate": 0,
  "externalReferenceId": "string",
  "originalAmount": 0,
  "originalCurrency": "string",
  "status": "PENDING",
  "userTransactionTime": "string"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
201 Created The authorization hold was successfully created. AuthorizationHold
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Card not found. ErrorResponse

Centres

Allows retrieving centres which are being used by an organization. A branch in Mambu is the default label for an organization's subdivision. A centre is the default label for a subdivision of a branch. It can be considered a sub-branch. Each branch can have multiple centres assigned to it.

getById (Centres)

Code samples

# You can also use wget
curl -X GET /centres/{centreId} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /centres/{centreId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/centres/{centreId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/centres/{centreId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/centres/{centreId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/centres/{centreId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/centres/{centreId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/centres/{centreId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /centres/{centreId}

Allows retrieval of a single centre via id or encoded key

Parameters

Name Type Description In Required
centreId string The id or encoded key of the centre to be retrieved path true
detailsLevel string The level of details to retrieve, FULL means the full details of the object will be retrieved (custom fields, address, contact info or any other related object), BASIC will return only the first level elements of the object query false

Enumerated Values

Parameter Value
detailsLevel BASIC
detailsLevel FULL

Example responses

200 Response

{
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_centres_custom_field_set": {
    "centre_cf_1": "string",
    "cntr_cf_2": "TRUE",
    "cntr_cf_usr_lnk": "string"
  },
  "_cntr_cf_grp": [
    {
      "cntr_cf_Grp_1": "string",
      "cntr_cf_grp_2": "option 1",
      "cntr_cf_slct_2": "dep 1 a"
    }
  ],
  "addresses": [
    {
      "city": "string",
      "country": "string",
      "encodedKey": "string",
      "indexInList": 0,
      "latitude": 0,
      "line1": "string",
      "line2": "string",
      "longitude": 0,
      "parentKey": "string",
      "postcode": "string",
      "region": "string"
    }
  ],
  "assignedBranchKey": "string",
  "creationDate": "2016-09-06T13:37:50+03:00",
  "encodedKey": "string",
  "id": "string",
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "meetingDay": "string",
  "name": "string",
  "notes": "string",
  "state": "ACTIVE"
}

Responses

Status Meaning Description Schema
200 OK Centre retrieved Centre
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Centre not found ErrorResponse

getAll (Centres)

Code samples

# You can also use wget
curl -X GET /centres \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /centres HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/centres',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/centres',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/centres', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/centres', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/centres");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/centres", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /centres

Allows retrieval of centres using various query parameters

Parameters

Name Type Description In Required
offset integer(int32) Pagination, index to start searching at when retrieving elements, used in combination with limit to paginate results query false
limit integer(int32) Pagination, the number of elements to retrieve, used in combination with offset to paginate results query false
paginationDetails string Flag specifying whether the pagination details should be provided in response headers. Please note that by default it is disabled (OFF), in order to improve the performance of the APIs query false
detailsLevel string The level of details to retrieve, FULL means the full details of the object will be retrieved (custom fields, address, contact info or any other related object), BASIC will return only the first level elements of the object query false
branchId string The branch id the centre belongs to query false
sortBy string The criteria based on which the records will be sorted. Expected format is , eg sortBy = field1:ASC,field2:DESC.
Only the following fields can be used: id,name, creationDate, lastModifiedDate
Default sorting is done by creationDate:DESC
query false

Enumerated Values

Parameter Value
paginationDetails ON
paginationDetails OFF
detailsLevel BASIC
detailsLevel FULL

Example responses

200 Response

[
  {
    "_Example_Custom_Fields": {
      "Example_Checkbox_Field": "TRUE",
      "Example_Free_Text_Field": "A free text field up to 255 characters in length",
      "Example_Number_Field": "46290",
      "Example_Select_Field": "Option 1"
    },
    "_centres_custom_field_set": {
      "centre_cf_1": "string",
      "cntr_cf_2": "TRUE",
      "cntr_cf_usr_lnk": "string"
    },
    "_cntr_cf_grp": [
      {
        "cntr_cf_Grp_1": "string",
        "cntr_cf_grp_2": "option 1",
        "cntr_cf_slct_2": "dep 1 a"
      }
    ],
    "addresses": [
      {
        "city": "string",
        "country": "string",
        "encodedKey": "string",
        "indexInList": 0,
        "latitude": 0,
        "line1": "string",
        "line2": "string",
        "longitude": 0,
        "parentKey": "string",
        "postcode": "string",
        "region": "string"
      }
    ],
    "assignedBranchKey": "string",
    "creationDate": "2016-09-06T13:37:50+03:00",
    "encodedKey": "string",
    "id": "string",
    "lastModifiedDate": "2016-09-06T13:37:50+03:00",
    "meetingDay": "string",
    "name": "string",
    "notes": "string",
    "state": "ACTIVE"
  }
]

Responses

Status Meaning Description Schema
200 OK Centres list retrieved Inline
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

Response Schema

Status Code 200

Name Type Description Required Restrictions
anonymous [Centre] [A Centre is a common meeting area that credit officers and the individual and group clients go to. Each centre is assigned to a branch (a branch can have multiple centres) and might have a specific meeting day and location.] false none
» _Example_Custom_Fields object An Example of some custom fields, these should be configured for your instance using the Mambu UI. The examples in this object only represent a selection of the possible field types available. false none
»» Example_Checkbox_Field string A field that will appear as a checkbox in the UI. In the API value will be TRUE or FALSE as a string. Please note: the value must be provided as a string, not a boolean. false none
»» Example_Free_Text_Field string A field that can contain a string of text. Pay attention to proper JSON escaping if providing values for such fields via API. false none
»» Example_Number_Field string(number) A field supporting numbers only. Please note: the value is to be provided as a string. false none
»» Example_Select_Field string A custom field type supporting enumerated values. Requests will fail if the value provided for such a field is not one of the supported values. false none
» _centres_custom_field_set object custom fields for centre false none
»» centre_cf_1 string a text custom field for a centre false none
»» cntr_cf_2 string a checkbox custom field for a centre false none
»» cntr_cf_usr_lnk string a custom field linking to a specific user false none
» _cntr_cf_grp [_cntr_cf_grp] [grouped centre custom fields] false none
»» cntr_cf_Grp_1 string(number) a number custom field false none
»» cntr_cf_grp_2 string a selection custom field for centres false none
»» cntr_cf_slct_2 string a custom field in which the options available are dependent on another field false none
» addresses [Address] The addresses of this centre false none
»» city string The city for this address false none
»» country string The country false none
»» encodedKey string Address encoded key, unique, generated false read-only
»» indexInList integer(int32) Index of this address in the list of addresses false none
»» latitude number The GPS latitude of this address in signed degrees format (DDD.dddd) with 6 decimal positions, ranging from -90 to +90 false none
»» line1 string The first line of the address false none
»» line2 string The second line for the address, in case the first one doesn't fit the information, this is completely optional false none
»» longitude number The GPS longitude of this address in signed degrees format (DDD.dddd) with 6 decimal positions, ranging from -180 to +180 false none
»» parentKey string Address parent key, the object owning this address, client, centre, branch false read-only
»» postcode string The post code false none
»» region string The region that is part of the address false none
» assignedBranchKey string Encoded key of the branch this centre is assigned to false none
» creationDate string(date-time) Date the centre was created false none
» encodedKey string The encoded key of the entity, generated, globally unique false read-only
» id string Id of the centre, unique, can be generated and customized false none
» lastModifiedDate string(date-time) The last time the centre was modified false none
» meetingDay string Day of the week when repayments are collected, influences repayments schedule, upon update all repayments are update to this day of the week false none
» name string Name of the centre false none
» notes string Extra notes about this centre false none
» state string The state of the centre false none

Enumerated Values

Property Value
Example_Checkbox_Field TRUE
Example_Checkbox_Field FALSE
Example_Select_Field Option 1
Example_Select_Field Option 2
Example_Select_Field Option 3
cntr_cf_2 TRUE
cntr_cf_2 FALSE
cntr_cf_grp_2 option 1
cntr_cf_grp_2 option 2
cntr_cf_slct_2 dep 1 a
cntr_cf_slct_2 dep 1 b
cntr_cf_slct_2 dep 2 a
cntr_cf_slct_2 dep 2 b
state ACTIVE
state INACTIVE

Response Headers

Status Header Type Format Description
200 Items-Limit integer int32 Pagination details, the requested page size
200 Items-Offset integer int32 Pagination details, the index of the first returned item
200 Items-Total integer int32 Pagination details, the total available items

Centres Configuration

Retrieve and update the configuration for centres.

A branch in Mambu is the default label for an organization's subdivision. A centre is the default label for a subdivision of a branch. It can be considered a sub-branch. Each branch can have multiple centres assigned to it. For more information about this resource, see Centres Configuration in our User Guide.

get (Centres Configuration)

Code samples

# You can also use wget
curl -X GET /configuration/centres.yaml \
  -H 'Accept: application/vnd.mambu.v2+yaml'

GET /configuration/centres.yaml HTTP/1.1

Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/centres.yaml',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.get '/configuration/centres.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.get('/configuration/centres.yaml', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/configuration/centres.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/centres.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/configuration/centres.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /configuration/centres.yaml

Retrieve the centres configuration.

Example responses

a single centre

---
centres:
- id: "DT1"
  name: "Down Town"
  state: "ACTIVE"
  notes: "some rich text notes about this centre"
  meetingDay: "FRIDAY"
  assignedBranchId: "demoBranchId"
  address:
    line1: "Chuffington House"
    line2: "123 Main High Road"
    city: "Big Town"
    region: "Big Conglomeration"
    postcode: "123 456"
    country: "Countrystan"
  customFieldValueSets:
  - id: "_centres_custom_field_set"
    standardCustomFieldValues:
    - customFieldId: "centre_cf_1"
      value: "custom field value for cf 1"
    - customFieldId: "cntr_cf_2"
      value: "FALSE"
    - customFieldId: "cntr_cf_usr_lnk"
      value: "jonnyt"
  - id: "_cntr_cf_grp"
    groupedCustomFieldValues:
    - index: 0
      customFieldValues:
      - customFieldId: "cntr_cf_Grp_1"
        value: "12"
      - customFieldId: "cntr_cf_grp_2"
        value: "414828471"
      - customFieldId: "cntr_cf_slct_2"
        value: "745255722"

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Centres configuration retrieved. CentresConfiguration
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

update (Centres Configuration)

Code samples

# You can also use wget
curl -X PUT /configuration/centres.yaml \
  -H 'Content-Type: application/yaml' \
  -H 'Accept: application/vnd.mambu.v2+yaml'

PUT /configuration/centres.yaml HTTP/1.1

Content-Type: application/yaml
Accept: application/vnd.mambu.v2+yaml

var headers = {
  'Content-Type':'application/yaml',
  'Accept':'application/vnd.mambu.v2+yaml'

};

$.ajax({
  url: '/configuration/centres.yaml',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/yaml',
  'Accept' => 'application/vnd.mambu.v2+yaml'
}

result = RestClient.put '/configuration/centres.yaml',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/yaml',
  'Accept': 'application/vnd.mambu.v2+yaml'
}

r = requests.put('/configuration/centres.yaml', params={

}, headers = headers)

print r.json()

 'application/yaml',
    'Accept' => 'application/vnd.mambu.v2+yaml',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','/configuration/centres.yaml', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/configuration/centres.yaml");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/yaml"},
        "Accept": []string{"application/vnd.mambu.v2+yaml"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "/configuration/centres.yaml", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /configuration/centres.yaml

Update the current centres configuration

Body parameter

an array of centres

---
centres:
- id: "DT1"
  name: "Down Town"
  state: "ACTIVE"
  notes: "some rich text notes about this centre"
  meetingDay: "FRIDAY"
  assignedBranchId: "demoBranchId"
  address:
    line1: "Chuffington House"
    line2: "123 Main High Road"
    city: "Big Town"
    region: "Big Conglomeration"
    postcode: "123 456"
    country: "Countrystan"
  customFieldValueSets:
  - id: "_centres_custom_field_set"
    standardCustomFieldValues:
    - customFieldId: "centre_cf_1"
      value: "custom field value for cf 1"
    - customFieldId: "cntr_cf_2"
      value: "FALSE"
    - customFieldId: "cntr_cf_usr_lnk"
      value: "jonnyt"
  - id: "_cntr_cf_grp"
    groupedCustomFieldValues:
    - index: 0
      customFieldValues:
      - customFieldId: "cntr_cf_Grp_1"
        value: "12"
      - customFieldId: "cntr_cf_grp_2"
        value: "414828471"
      - customFieldId: "cntr_cf_slct_2"
        value: "745255722"
- id: "MP1"
  name: "Market Place"
  state: "ACTIVE"
  notes: "All clients and officers gather in the market to discuss loans and savings\
    \ situation."
  assignedBranchId: "2"
  address:
    line1: "Hegyalja út 95."
    city: "Debrecen"
    postcode: "4032"

Parameters

Name Type Description In Required
body CentresConfiguration Model representation of the centres configuration. body false

Example responses

200 success response

---
warnings: []

200 response with warnings

---
warnings:
- "Centre [id = DT1] could not be deleted and was deactivated"

400 error response

{
    "errors": [
        {
            "errorCode": 0,
            "errorSource": "human-readable description of the error",
            "errorReason": "SOURCE_OF_ERROR"
        }
    ]
}

401 invalid credentials

{
    "errors": [
        {
            "errorCode": 2,
            "errorSource": "credentials",
            "errorReason": "INVALID_CREDENTIALS"
        }
    ]
}

403 forbidden

{
    "errors": [
        {
            "errorCode": 15,
            "errorSource": "not authorized",
            "errorReason": "INVALID_PERMISSIONS"
        }
    ]
}

404 not found

{
    "errors": [
        {
            "errorCode": 3,
            "errorSource": "server",
            "errorReason": "INVALID_API_OPERATION"
        }
    ]
}

Responses

Status Meaning Description Schema
200 OK Centres configuration updated None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Centres configuration not found ErrorResponse

Response Schema

Clients

Allows you to retrieve, create, update or delete clients. Clients may have associated information such as their address, identification documents or custom fields.

getById (Clients)

Code samples

# You can also use wget
curl -X GET /clients/{clientId} \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /clients/{clientId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/clients/{clientId}',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/clients/{clientId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/clients/{clientId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/clients/{clientId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/clients/{clientId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/clients/{clientId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /clients/{clientId}

Allows retrieval of a single client via id or encoded key

Parameters

Name Type Description In Required
clientId string The id or encoded key of the client to be retrieved path true
detailsLevel string The level of details to retrieve, FULL means the full details of the object will be retrieved (custom fields, address, contact info or any other related object), BASIC will return only the first level elements of the object query false

Enumerated Values

Parameter Value
detailsLevel BASIC
detailsLevel FULL

Example responses

200 Response

{
  "_Custom_Fields_Clients": {
    "Position_Clients": "string",
    "score_2": "adfsgd"
  },
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Family_Clients": {
    "Family_Members_Clients": "string",
    "Has_children_Clients": "TRUE"
  },
  "_Others_Clients": {
    "Location_Clients": "Catamarca",
    "Studies_Clients": "string",
    "delete_me": "labe",
    "vrfy_lnk": "string",
    "vrfy_param": "string"
  },
  "_client_group_set": [
    {
      "_grp_set_1": "string",
      "_grp_set_clt_2": "string",
      "_grp_set_fld_3": "TRUE"
    }
  ],
  "activationDate": "2016-09-06T13:37:50+03:00",
  "addresses": [
    {
      "city": "string",
      "country": "string",
      "encodedKey": "string",
      "indexInList": 0,
      "latitude": 0,
      "line1": "string",
      "line2": "string",
      "longitude": 0,
      "parentKey": "string",
      "postcode": "string",
      "region": "string"
    }
  ],
  "approvedDate": "2016-09-06T13:37:50+03:00",
  "assignedBranchKey": "string",
  "assignedCentreKey": "string",
  "assignedUserKey": "string",
  "birthDate": "1987-04-26",
  "clientRoleKey": "string",
  "closedDate": "2016-09-06T13:37:50+03:00",
  "creationDate": "2016-09-06T13:37:50+03:00",
  "emailAddress": "string",
  "encodedKey": "string",
  "firstName": "string",
  "gender": "MALE",
  "groupKeys": [
    "string"
  ],
  "groupLoanCycle": 0,
  "homePhone": "string",
  "id": "string",
  "idDocuments": [
    {
      "attachments": [
        {
          "creationDate": "2016-09-06T13:37:50+03:00",
          "encodedKey": "string",
          "fileName": "string",
          "fileSize": 0,
          "id": 0,
          "lastModifiedDate": "2016-09-06T13:37:50+03:00",
          "location": "string",
          "name": "string",
          "notes": "string",
          "ownerKey": "string",
          "ownerType": "CLIENT",
          "type": "string"
        }
      ],
      "clientKey": "string",
      "documentId": "string",
      "documentType": "string",
      "encodedKey": "string",
      "identificationDocumentTemplateKey": "string",
      "indexInList": 0,
      "issuingAuthority": "string",
      "validUntil": "1987-04-26"
    }
  ],
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "lastName": "string",
  "loanCycle": 0,
  "middleName": "string",
  "migrationEventKey": "string",
  "mobilePhone": "string",
  "mobilePhone2": "string",
  "notes": "string",
  "portalSettings": {
    "encodedKey": "string",
    "lastLoggedInDate": "2016-09-06T13:37:50+03:00",
    "portalState": "ENABLED"
  },
  "preferredLanguage": "ENGLISH",
  "profilePictureKey": "string",
  "profileSignatureKey": "string",
  "state": "PENDING_APPROVAL"
}

Responses

Status Meaning Description Schema
200 OK Client retrieved Client
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Client not found ErrorResponse

update (Clients)

Code samples

# You can also use wget
curl -X PUT /clients/{clientId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json'

PUT /clients/{clientId} HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/clients/{clientId}',
  method: 'put',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.put '/clients/{clientId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.put('/clients/{clientId}', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PUT','/clients/{clientId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/clients/{clientId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "/clients/{clientId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PUT /clients/{clientId}

Update an existing client

Body parameter

{
  "_Custom_Fields_Clients": {
    "Position_Clients": "string",
    "score_2": "adfsgd"
  },
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Family_Clients": {
    "Family_Members_Clients": "string",
    "Has_children_Clients": "TRUE"
  },
  "_Others_Clients": {
    "Location_Clients": "Catamarca",
    "Studies_Clients": "string",
    "delete_me": "labe",
    "vrfy_lnk": "string",
    "vrfy_param": "string"
  },
  "_client_group_set": [
    {
      "_grp_set_1": "string",
      "_grp_set_clt_2": "string",
      "_grp_set_fld_3": "TRUE"
    }
  ],
  "addresses": [
    {
      "city": "string",
      "country": "string",
      "indexInList": 0,
      "latitude": 0,
      "line1": "string",
      "line2": "string",
      "longitude": 0,
      "postcode": "string",
      "region": "string"
    }
  ],
  "assignedBranchKey": "string",
  "assignedCentreKey": "string",
  "assignedUserKey": "string",
  "birthDate": "1987-04-26",
  "clientRoleKey": "string",
  "emailAddress": "string",
  "firstName": "string",
  "gender": "MALE",
  "groupKeys": [
    "string"
  ],
  "homePhone": "string",
  "id": "string",
  "idDocuments": [
    {
      "attachments": [
        {
          "fileName": "string",
          "fileSize": 0,
          "id": 0,
          "location": "string",
          "name": "string",
          "notes": "string",
          "type": "string"
        }
      ],
      "documentId": "string",
      "documentType": "string",
      "identificationDocumentTemplateKey": "string",
      "indexInList": 0,
      "issuingAuthority": "string",
      "validUntil": "1987-04-26"
    }
  ],
  "lastName": "string",
  "middleName": "string",
  "mobilePhone": "string",
  "mobilePhone2": "string",
  "notes": "string",
  "portalSettings": {
    "lastLoggedInDate": "2016-09-06T13:37:50+03:00",
    "portalState": "ENABLED"
  },
  "preferredLanguage": "ENGLISH",
  "state": "PENDING_APPROVAL"
}

Parameters

Name Type Description In Required
clientId string The id or encoded key of the client to be updated path true
body Client Client to be updated body true

Example responses

200 Response

{
  "_Custom_Fields_Clients": {
    "Position_Clients": "string",
    "score_2": "adfsgd"
  },
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Family_Clients": {
    "Family_Members_Clients": "string",
    "Has_children_Clients": "TRUE"
  },
  "_Others_Clients": {
    "Location_Clients": "Catamarca",
    "Studies_Clients": "string",
    "delete_me": "labe",
    "vrfy_lnk": "string",
    "vrfy_param": "string"
  },
  "_client_group_set": [
    {
      "_grp_set_1": "string",
      "_grp_set_clt_2": "string",
      "_grp_set_fld_3": "TRUE"
    }
  ],
  "activationDate": "2016-09-06T13:37:50+03:00",
  "addresses": [
    {
      "city": "string",
      "country": "string",
      "encodedKey": "string",
      "indexInList": 0,
      "latitude": 0,
      "line1": "string",
      "line2": "string",
      "longitude": 0,
      "parentKey": "string",
      "postcode": "string",
      "region": "string"
    }
  ],
  "approvedDate": "2016-09-06T13:37:50+03:00",
  "assignedBranchKey": "string",
  "assignedCentreKey": "string",
  "assignedUserKey": "string",
  "birthDate": "1987-04-26",
  "clientRoleKey": "string",
  "closedDate": "2016-09-06T13:37:50+03:00",
  "creationDate": "2016-09-06T13:37:50+03:00",
  "emailAddress": "string",
  "encodedKey": "string",
  "firstName": "string",
  "gender": "MALE",
  "groupKeys": [
    "string"
  ],
  "groupLoanCycle": 0,
  "homePhone": "string",
  "id": "string",
  "idDocuments": [
    {
      "attachments": [
        {
          "creationDate": "2016-09-06T13:37:50+03:00",
          "encodedKey": "string",
          "fileName": "string",
          "fileSize": 0,
          "id": 0,
          "lastModifiedDate": "2016-09-06T13:37:50+03:00",
          "location": "string",
          "name": "string",
          "notes": "string",
          "ownerKey": "string",
          "ownerType": "CLIENT",
          "type": "string"
        }
      ],
      "clientKey": "string",
      "documentId": "string",
      "documentType": "string",
      "encodedKey": "string",
      "identificationDocumentTemplateKey": "string",
      "indexInList": 0,
      "issuingAuthority": "string",
      "validUntil": "1987-04-26"
    }
  ],
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "lastName": "string",
  "loanCycle": 0,
  "middleName": "string",
  "migrationEventKey": "string",
  "mobilePhone": "string",
  "mobilePhone2": "string",
  "notes": "string",
  "portalSettings": {
    "encodedKey": "string",
    "lastLoggedInDate": "2016-09-06T13:37:50+03:00",
    "portalState": "ENABLED"
  },
  "preferredLanguage": "ENGLISH",
  "profilePictureKey": "string",
  "profileSignatureKey": "string",
  "state": "PENDING_APPROVAL"
}

Responses

Status Meaning Description Schema
200 OK Client updated Client
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Client not found ErrorResponse

delete (Clients)

Code samples

# You can also use wget
curl -X DELETE /clients/{clientId} \
  -H 'Accept: application/vnd.mambu.v2+json'

DELETE /clients/{clientId} HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/clients/{clientId}',
  method: 'delete',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.delete '/clients/{clientId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.delete('/clients/{clientId}', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('DELETE','/clients/{clientId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/clients/{clientId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("DELETE");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("DELETE", "/clients/{clientId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

DELETE /clients/{clientId}

Delete a client

Parameters

Name Type Description In Required
clientId string The id or encoded key of the client to be deleted path true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
204 No Content Client deleted None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Client not found ErrorResponse

patch (Clients)

Code samples

# You can also use wget
curl -X PATCH /clients/{clientId} \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json'

PATCH /clients/{clientId} HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/clients/{clientId}',
  method: 'patch',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.patch '/clients/{clientId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.patch('/clients/{clientId}', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('PATCH','/clients/{clientId}', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/clients/{clientId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "/clients/{clientId}", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

PATCH /clients/{clientId}

Partially update an existing client

Body parameter

[
  {
    "from": "string",
    "op": "ADD",
    "path": "string",
    "value": {}
  }
]

Parameters

Name Type Description In Required
clientId string The id or encoded key of the client to be updated path true
body PatchOperation Patch operations to be applied to a resource body true

Example responses

400 Response

{
  "errors": [
    {
      "errorCode": 0,
      "errorReason": "SUCCESS",
      "errorSource": "string"
    }
  ]
}

Responses

Status Meaning Description Schema
204 No Content Client updated None
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found Client not found ErrorResponse

getAll (Clients)

Code samples

# You can also use wget
curl -X GET /clients \
  -H 'Accept: application/vnd.mambu.v2+json'

GET /clients HTTP/1.1

Accept: application/vnd.mambu.v2+json

var headers = {
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '/clients',
  method: 'get',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/vnd.mambu.v2+json'
}

result = RestClient.get '/clients',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/vnd.mambu.v2+json'
}

r = requests.get('/clients', params={

}, headers = headers)

print r.json()

 'application/vnd.mambu.v2+json',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('GET','/clients', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/clients");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Accept": []string{"application/vnd.mambu.v2+json"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "/clients", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

GET /clients

Allows retrieval of clients using various query parameters

Parameters

Name Type Description In Required
offset integer(int32) Pagination, index to start searching at when retrieving elements, used in combination with limit to paginate results query false
limit integer(int32) Pagination, the number of elements to retrieve, used in combination with offset to paginate results query false
paginationDetails string Flag specifying whether the pagination details should be provided in response headers. Please note that by default it is disabled (OFF), in order to improve the performance of the APIs query false
detailsLevel string The level of details to retrieve, FULL means the full details of the object will be retrieved (custom fields, address, contact info or any other related object), BASIC will return only the first level elements of the object query false
creditOfficerUsername string The username of the credit officer to whom the entities are assigned to query false
branchId string The id/encodedKey of the branch to which the entities are assigned to query false
centreId string The id/encodedKey of the centre to which the entities are assigned to query false
firstName string The first name, personal name, given name or forename of the client query false
lastName string The last name, surname or family name of the client query false
idNumber string The id number of the client's identification document query false
state string The state of the client to search for query false
birthDate string(date) The birth date of the client to search for query false
sortBy string The criteria based on which the records will be sorted. Expected format is , eg sortBy = field1:ASC,field2:DESC.
Only the following fields can be used: firstName, lastName, creationDate, lastModifiedDate
Default sorting is done by creationDate:ASC
query false

Enumerated Values

Parameter Value
paginationDetails ON
paginationDetails OFF
detailsLevel BASIC
detailsLevel FULL
state PENDING_APPROVAL
state INACTIVE
state ACTIVE
state EXITED
state BLACKLISTED
state REJECTED

Example responses

200 Response

[
  {
    "_Custom_Fields_Clients": {
      "Position_Clients": "string",
      "score_2": "adfsgd"
    },
    "_Example_Custom_Fields": {
      "Example_Checkbox_Field": "TRUE",
      "Example_Free_Text_Field": "A free text field up to 255 characters in length",
      "Example_Number_Field": "46290",
      "Example_Select_Field": "Option 1"
    },
    "_Family_Clients": {
      "Family_Members_Clients": "string",
      "Has_children_Clients": "TRUE"
    },
    "_Others_Clients": {
      "Location_Clients": "Catamarca",
      "Studies_Clients": "string",
      "delete_me": "labe",
      "vrfy_lnk": "string",
      "vrfy_param": "string"
    },
    "_client_group_set": [
      {
        "_grp_set_1": "string",
        "_grp_set_clt_2": "string",
        "_grp_set_fld_3": "TRUE"
      }
    ],
    "activationDate": "2016-09-06T13:37:50+03:00",
    "addresses": [
      {
        "city": "string",
        "country": "string",
        "encodedKey": "string",
        "indexInList": 0,
        "latitude": 0,
        "line1": "string",
        "line2": "string",
        "longitude": 0,
        "parentKey": "string",
        "postcode": "string",
        "region": "string"
      }
    ],
    "approvedDate": "2016-09-06T13:37:50+03:00",
    "assignedBranchKey": "string",
    "assignedCentreKey": "string",
    "assignedUserKey": "string",
    "birthDate": "1987-04-26",
    "clientRoleKey": "string",
    "closedDate": "2016-09-06T13:37:50+03:00",
    "creationDate": "2016-09-06T13:37:50+03:00",
    "emailAddress": "string",
    "encodedKey": "string",
    "firstName": "string",
    "gender": "MALE",
    "groupKeys": [
      "string"
    ],
    "groupLoanCycle": 0,
    "homePhone": "string",
    "id": "string",
    "idDocuments": [
      {
        "attachments": [
          {
            "creationDate": "2016-09-06T13:37:50+03:00",
            "encodedKey": "string",
            "fileName": "string",
            "fileSize": 0,
            "id": 0,
            "lastModifiedDate": "2016-09-06T13:37:50+03:00",
            "location": "string",
            "name": "string",
            "notes": "string",
            "ownerKey": "string",
            "ownerType": "CLIENT",
            "type": "string"
          }
        ],
        "clientKey": "string",
        "documentId": "string",
        "documentType": "string",
        "encodedKey": "string",
        "identificationDocumentTemplateKey": "string",
        "indexInList": 0,
        "issuingAuthority": "string",
        "validUntil": "1987-04-26"
      }
    ],
    "lastModifiedDate": "2016-09-06T13:37:50+03:00",
    "lastName": "string",
    "loanCycle": 0,
    "middleName": "string",
    "migrationEventKey": "string",
    "mobilePhone": "string",
    "mobilePhone2": "string",
    "notes": "string",
    "portalSettings": {
      "encodedKey": "string",
      "lastLoggedInDate": "2016-09-06T13:37:50+03:00",
      "portalState": "ENABLED"
    },
    "preferredLanguage": "ENGLISH",
    "profilePictureKey": "string",
    "profileSignatureKey": "string",
    "state": "PENDING_APPROVAL"
  }
]

Responses

Status Meaning Description Schema
200 OK Clients list retrieved Inline
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

Response Schema

Status Code 200

Name Type Description Required Restrictions
anonymous [Client] [A person that uses the services of the bank. Clients may have associated information such as their address, custom fields or identification documents] false none
» _Custom_Fields_Clients object none false none
»» Position_Clients string none false none
»» score_2 string none false none
» _Example_Custom_Fields object An Example of some custom fields, these should be configured for your instance using the Mambu UI. The examples in this object only represent a selection of the possible field types available. false none
»» Example_Checkbox_Field string A field that will appear as a checkbox in the UI. In the API value will be TRUE or FALSE as a string. Please note: the value must be provided as a string, not a boolean. false none
»» Example_Free_Text_Field string A field that can contain a string of text. Pay attention to proper JSON escaping if providing values for such fields via API. false none
»» Example_Number_Field string(number) A field supporting numbers only. Please note: the value is to be provided as a string. false none
»» Example_Select_Field string A custom field type supporting enumerated values. Requests will fail if the value provided for such a field is not one of the supported values. false none
» _Family_Clients object none false none
»» Family_Members_Clients string(number) none false none
»» Has_children_Clients string none false none
» _Others_Clients object none false none
»» Location_Clients string none false none
»» Studies_Clients string none false none
»» delete_me string none false none
»» vrfy_lnk string link to account verification false none
»» vrfy_param string a param false none
» _client_group_set [_client_group_set] [a set of custom fields which can be added multiple times to the same entity] false none
»» _grp_set_1 string none false none
»» _grp_set_clt_2 string(number) none false none
»» _grp_set_fld_3 string none false none
» activationDate string(date-time) The date when client was set as active for the first time false read-only
» addresses [Address] The addresses associated with this client information like street, city etc. false none
»» city string The city for this address false none
»» country string The country false none
»» encodedKey string Address encoded key, unique, generated false read-only
»» indexInList integer(int32) Index of this address in the list of addresses false none
»» latitude number The GPS latitude of this address in signed degrees format (DDD.dddd) with 6 decimal positions, ranging from -90 to +90 false none
»» line1 string The first line of the address false none
»» line2 string The second line for the address, in case the first one doesn't fit the information, this is completely optional false none
»» longitude number The GPS longitude of this address in signed degrees format (DDD.dddd) with 6 decimal positions, ranging from -180 to +180 false none
»» parentKey string Address parent key, the object owning this address, client, centre, branch false read-only
»» postcode string The post code false none
»» region string The region that is part of the address false none
» approvedDate string(date-time) date when client was approved false read-only
» assignedBranchKey string Encoded key of the branch this client is assigned to false none
» assignedCentreKey string Encoded key of the centre this client is assigned to false none
» assignedUserKey string Encoded key of the user this client is assigned to false none
» birthDate string(date) The date when this client was born false none
» clientRoleKey string A role which describes the intended use of a client in the system false none
» closedDate string(date-time) date when client was closed false read-only
» creationDate string(date-time) The date this client was created false read-only
» emailAddress string The client's email address false none
» encodedKey string The encoded key of the client, auto generated, unique false read-only
» firstName string The first name, personal name, given name or forename of the client true none
» gender string Gender of the person, male or female false none
» groupKeys [string] The groups to which this client belongs false none
» groupLoanCycle integer(int32) Number of paid and closed (with 'obligations met') accounts for this client's group, when the closing operation is reverted, this is reduced false read-only
» homePhone string The client's home phone number false none
» id string The id of the client, can be generated and customized, unique false none
» idDocuments [IdentificationDocument] The identification documents of this person false none
»» attachments [Document] A list containing information about the attached files for this document false none
»»» creationDate string(date-time) The creation date of the document, stored as UTC false read-only
»»» encodedKey string The document encodedKey false read-only
»»» fileName string The original file name of the document false none
»»» fileSize integer(int64) The file size of the document false none
»»» id integer(int64) The document id true none
»»» lastModifiedDate string(date-time) The last modified date of the document, stored as UTC false read-only
»»» location string Location where the document can be found, eg /myfiles/mypicture.jpeg false none
»»» name string The name of the document true none
»»» notes string Detailed notes about the document false none
»»» ownerKey string Represents the holder of this document. If null, means nobody is the owner of this document false read-only
»»» ownerType string Determines the owner type of the document false read-only
»»» type string The extension of the document true none
»» clientKey string The encoded key of the client that owns this document false read-only
»» documentId string The id of the document true none
»» documentType string The type of the document, Passport, Id card Drivers license, etc. true none
»» encodedKey string The encoded key of the document, generated, unique false read-only
»» identificationDocumentTemplateKey string Encoded key of the template used for this document false none
»» indexInList integer(int32) This document's index in the list of documents false none
»» issuingAuthority string Authority that issued the document, eg. Police false none
»» validUntil string(date) Date when the validity of the document ends false none
» lastModifiedDate string(date-time) The last date this client was modified false read-only
» lastName string The last name, surname or family name of the client true none
» loanCycle integer(int32) Number of paid and closed (with 'obligations met') accounts for this client, when the closing operation is reverted, this is reduced false read-only
» middleName string The middle name of the client, if she/he has one false none
» migrationEventKey string The migration event encoded key associated with this client. false read-only
» mobilePhone string The client's mobile phone number false none
» mobilePhone2 string The client's second mobile phone number false none
» notes string Extra notes about this client false none
» portalSettings PortalSettings Portal settings for an individual client false none
»» encodedKey string The encoded key of the entity, generated, globally unique false read-only
»» lastLoggedInDate string(date-time) The last date the client logged in to the portal false none
»» portalState string State of the client's portal preferences false none
» preferredLanguage string The client's language of use in Mambu false none
» profilePictureKey string Encoded key of this clients profile picture false read-only
» profileSignatureKey string Encoded key of the users profile signature false read-only
» state string The state of a client shows his workflow status, if he is waiting approval or is rejected or blacklisted false none

Enumerated Values

Property Value
score_2 adfsgd
score_2 wefqas
Example_Checkbox_Field TRUE
Example_Checkbox_Field FALSE
Example_Select_Field Option 1
Example_Select_Field Option 2
Example_Select_Field Option 3
Has_children_Clients TRUE
Has_children_Clients FALSE
Location_Clients Catamarca
Location_Clients Chaco
Location_Clients Jujuy
delete_me labe
delete_me label 2
_grp_set_fld_3 TRUE
_grp_set_fld_3 FALSE
gender MALE
gender FEMALE
ownerType CLIENT
ownerType GROUP
ownerType LOAN_PRODUCT
ownerType SAVINGS_PRODUCT
ownerType CENTRE
ownerType BRANCH
ownerType USER
ownerType LOAN_ACCOUNT
ownerType DEPOSIT_ACCOUNT
ownerType ID_DOCUMENT
ownerType LINE_OF_CREDIT
ownerType GL_JOURNAL_ENTRY
portalState ENABLED
portalState DISABLED
preferredLanguage ENGLISH
preferredLanguage PORTUGESE
preferredLanguage SPANISH
preferredLanguage RUSSIAN
preferredLanguage FRENCH
preferredLanguage GEORGIAN
preferredLanguage CHINESE
preferredLanguage INDONESIAN
preferredLanguage ROMANIAN
preferredLanguage BURMESE
preferredLanguage GERMAN
preferredLanguage PORTUGUESE_BRAZIL
preferredLanguage VIETNAMESE
preferredLanguage PHRASE
state PENDING_APPROVAL
state INACTIVE
state ACTIVE
state EXITED
state BLACKLISTED
state REJECTED

Response Headers

Status Header Type Format Description
200 Items-Limit integer int32 Pagination details, the requested page size
200 Items-Offset integer int32 Pagination details, the index of the first returned item
200 Items-Total integer int32 Pagination details, the total available items

create (Clients)

Code samples

# You can also use wget
curl -X POST /clients \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json' \
  -H 'Idempotency-Key: string'

POST /clients HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json
Idempotency-Key: string

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json',
  'Idempotency-Key':'string'

};

$.ajax({
  url: '/clients',
  method: 'post',

  headers: headers,
  success: function(data) {
    console.log(JSON.stringify(data));
  }
})

require 'rest-client'
require 'json'

headers = {
  'Content-Type' => 'application/json',
  'Accept' => 'application/vnd.mambu.v2+json',
  'Idempotency-Key' => 'string'
}

result = RestClient.post '/clients',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/vnd.mambu.v2+json',
  'Idempotency-Key': 'string'
}

r = requests.post('/clients', params={

}, headers = headers)

print r.json()

 'application/json',
    'Accept' => 'application/vnd.mambu.v2+json',
    'Idempotency-Key' => 'string',
    
    );

$client = new \GuzzleHttp\Client();

// Define array of request body.
$request_body = array();

try {
    $response = $client->request('POST','/clients', array(
        'headers' => $headers,
        'json' => $request_body,
       )
    );
    print_r($response->getBody()->getContents());
 }
 catch (\GuzzleHttp\Exception\BadResponseException $e) {
    // handle exception or api errors.
    print_r($e->getMessage());
 }

 // ...

URL obj = new URL("/clients");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
    new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
    response.append(inputLine);
}
in.close();
System.out.println(response.toString());

package main

import (
       "bytes"
       "net/http"
)

func main() {

    headers := map[string][]string{
        "Content-Type": []string{"application/json"},
        "Accept": []string{"application/vnd.mambu.v2+json"},
        "Idempotency-Key": []string{"string"},
        
    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "/clients", data)
    req.Header = headers

    client := &http.Client{}
    resp, err := client.Do(req)
    // ...
}

POST /clients

Create a new client

Body parameter

{
  "_Custom_Fields_Clients": {
    "Position_Clients": "string",
    "score_2": "adfsgd"
  },
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Family_Clients": {
    "Family_Members_Clients": "string",
    "Has_children_Clients": "TRUE"
  },
  "_Others_Clients": {
    "Location_Clients": "Catamarca",
    "Studies_Clients": "string",
    "delete_me": "labe",
    "vrfy_lnk": "string",
    "vrfy_param": "string"
  },
  "_client_group_set": [
    {
      "_grp_set_1": "string",
      "_grp_set_clt_2": "string",
      "_grp_set_fld_3": "TRUE"
    }
  ],
  "addresses": [
    {
      "city": "string",
      "country": "string",
      "indexInList": 0,
      "latitude": 0,
      "line1": "string",
      "line2": "string",
      "longitude": 0,
      "postcode": "string",
      "region": "string"
    }
  ],
  "assignedBranchKey": "string",
  "assignedCentreKey": "string",
  "assignedUserKey": "string",
  "birthDate": "1987-04-26",
  "clientRoleKey": "string",
  "emailAddress": "string",
  "firstName": "string",
  "gender": "MALE",
  "groupKeys": [
    "string"
  ],
  "homePhone": "string",
  "id": "string",
  "idDocuments": [
    {
      "attachments": [
        {
          "fileName": "string",
          "fileSize": 0,
          "id": 0,
          "location": "string",
          "name": "string",
          "notes": "string",
          "type": "string"
        }
      ],
      "documentId": "string",
      "documentType": "string",
      "identificationDocumentTemplateKey": "string",
      "indexInList": 0,
      "issuingAuthority": "string",
      "validUntil": "1987-04-26"
    }
  ],
  "lastName": "string",
  "middleName": "string",
  "mobilePhone": "string",
  "mobilePhone2": "string",
  "notes": "string",
  "portalSettings": {
    "lastLoggedInDate": "2016-09-06T13:37:50+03:00",
    "portalState": "ENABLED"
  },
  "preferredLanguage": "ENGLISH",
  "state": "PENDING_APPROVAL"
}

Parameters

Name Type Description In Required
Idempotency-Key string Key that can be used to support idempotency on this POST. Must be a valid UUID(version 4 is recommended) string and can only be used with the exact same request. Can be used in retry mechanisms to prevent double posting. header false
body Client Client to be created body true

Example responses

201 Response

{
  "_Custom_Fields_Clients": {
    "Position_Clients": "string",
    "score_2": "adfsgd"
  },
  "_Example_Custom_Fields": {
    "Example_Checkbox_Field": "TRUE",
    "Example_Free_Text_Field": "A free text field up to 255 characters in length",
    "Example_Number_Field": "46290",
    "Example_Select_Field": "Option 1"
  },
  "_Family_Clients": {
    "Family_Members_Clients": "string",
    "Has_children_Clients": "TRUE"
  },
  "_Others_Clients": {
    "Location_Clients": "Catamarca",
    "Studies_Clients": "string",
    "delete_me": "labe",
    "vrfy_lnk": "string",
    "vrfy_param": "string"
  },
  "_client_group_set": [
    {
      "_grp_set_1": "string",
      "_grp_set_clt_2": "string",
      "_grp_set_fld_3": "TRUE"
    }
  ],
  "activationDate": "2016-09-06T13:37:50+03:00",
  "addresses": [
    {
      "city": "string",
      "country": "string",
      "encodedKey": "string",
      "indexInList": 0,
      "latitude": 0,
      "line1": "string",
      "line2": "string",
      "longitude": 0,
      "parentKey": "string",
      "postcode": "string",
      "region": "string"
    }
  ],
  "approvedDate": "2016-09-06T13:37:50+03:00",
  "assignedBranchKey": "string",
  "assignedCentreKey": "string",
  "assignedUserKey": "string",
  "birthDate": "1987-04-26",
  "clientRoleKey": "string",
  "closedDate": "2016-09-06T13:37:50+03:00",
  "creationDate": "2016-09-06T13:37:50+03:00",
  "emailAddress": "string",
  "encodedKey": "string",
  "firstName": "string",
  "gender": "MALE",
  "groupKeys": [
    "string"
  ],
  "groupLoanCycle": 0,
  "homePhone": "string",
  "id": "string",
  "idDocuments": [
    {
      "attachments": [
        {
          "creationDate": "2016-09-06T13:37:50+03:00",
          "encodedKey": "string",
          "fileName": "string",
          "fileSize": 0,
          "id": 0,
          "lastModifiedDate": "2016-09-06T13:37:50+03:00",
          "location": "string",
          "name": "string",
          "notes": "string",
          "ownerKey": "string",
          "ownerType": "CLIENT",
          "type": "string"
        }
      ],
      "clientKey": "string",
      "documentId": "string",
      "documentType": "string",
      "encodedKey": "string",
      "identificationDocumentTemplateKey": "string",
      "indexInList": 0,
      "issuingAuthority": "string",
      "validUntil": "1987-04-26"
    }
  ],
  "lastModifiedDate": "2016-09-06T13:37:50+03:00",
  "lastName": "string",
  "loanCycle": 0,
  "middleName": "string",
  "migrationEventKey": "string",
  "mobilePhone": "string",
  "mobilePhone2": "string",
  "notes": "string",
  "portalSettings": {
    "encodedKey": "string",
    "lastLoggedInDate": "2016-09-06T13:37:50+03:00",
    "portalState": "ENABLED"
  },
  "preferredLanguage": "ENGLISH",
  "profilePictureKey": "string",
  "profileSignatureKey": "string",
  "state": "PENDING_APPROVAL"
}

Responses

Status Meaning Description Schema
102 Processing Your idempotent request was already submitted and is currently being processed, try again later. None
201 Created Client created Client
400 Bad Request A Validation error occurred ErrorResponse
401 Unauthorized UNAUTHORIZED ErrorResponse
403 Forbidden Forbidden ErrorResponse

Code samples

# You can also use wget
curl -X POST /clients:search \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/vnd.mambu.v2+json'

POST /clients:search HTTP/1.1

Content-Type: application/json
Accept: application/vnd.mambu.v2+json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/vnd.mambu.v2+json'

};

$.ajax({
  url: '