The MX Platform API is a powerful, fully-featured API designed to make aggregating and enhancing financial data easy and reliable. It can seamlessly connect your app or website to tens of thousands of financial institutions.
The MX API is built around a standard REST architecture, uses predictable, resource-oriented URLs, and returns all data in JSON format. Requests are made with HTTP methods and HTTP response codes indicate the success or failure of those requests.
The MX Platform API has many different resources and features, but once you break it down, it is centered around five major resource types. Virtually all the others are connected in one way or another with the resources described here.
Resource | Description |
---|---|
institution |
An institution represents a financial institution (FI) like Chase or Wells Fargo. It’s important to point out that many real-world FI will actually have several different institution objects within the MX Platform API. This is because, for example, the mortgage division of Wells Fargo might use a separate system than its everyday banking division, which is different from its credit card division, etc. |
user |
A user represents an end-user accessing the MX Platform API via your application, be it a mobile app, web app, desktop app, etc. |
member |
A member represents the relationship between a user and an institution . A user may have multiple members, one each for their bank, their mortgage broker, their credit card provider, etc. Aggregation, verification, and many other processes are centered around a member , meaning this is probably the most important type of object you’ll be working with. |
account |
An account represents a financial account held by an FI, e.g., a user’s checking or savings account. A member may have more than one account associated with it. For instance, a user may have both a checking and savings account associated with one Chase login and would therefore have two accounts associated with that member . |
transaction |
A transaction represents any instance in which money moves into or out of an account , such as a purchase at a business, a payroll deposit, a transfer from one account to another, an ATM withdrawal, etc. Each transaction belongs to only one account . |
MX Platform API requests must use HTTPS with TLSv1.2 encryption or higher or else they will fail.
Requests also require basic access authentication where your client_id
is the username and your api_key
is the password. These values are available on the client dashboard.
Technically, basic access authorization requires the Base64 encoding of these values separated by a colon, but many HTTP clients will handle the encoding for you. For instance, all cURL example requests in this documentation use the -u
option, e.g., -u 'client_id:api_key'
. Nevertheless, there is an example of Base64 encoding to the right.
Because the values described above may grant access to some or all of your data, you must keep them secret and keep them safe. Do not share them in public areas, use them in client-side code, or otherwise use them in a way that may compromise their security.
All requests must come from a whitelisted IP address, which is configured via the client dashboard. Any request from a non-whitelisted IP address will return a 403 Forbidden error
. IP addresses outside of the United States are normally not permissible, so any requests for non-US IPs will require additional scrutiny and will be manually investigated and approved. Should we have any questions or need further details, MX will contact you via email.
In some instances, requests that require authentication will return 404 Not Found
, instead of 401 Unauthorized
. This is to prevent leaking private information.
Basic authorization value
Base64 encoding of:
client_id:api_key
Example
CLIENT-1234:API-KEY-4567 -> Q0xJRU5ULTEyMzQ6QVBJLUtFWS00NTY3
MX uses separate base URLs for its development and production environments. All examples given in this reference use the development base URL.
Development URL
https://int-api.mx.com
Production URL
https://api.mx.com
Certain API resources are subject to change at any time; for instance, institutions. For this reason, we discourage you from caching lists of resources. If caching is necessary, we recommend refreshing a cached list at least daily.
Requests to the API must use characters encoded with the UTF-8 standard.
JSON structured data is expected in all requests and returned in all responses, including some errors.
Dates and times are always given in ISO 8601 format.
Fields which end in _on
are given without a timestamp: 2018-07-18
Fields which end in _at
are given with a timestamp: 2015-04-13T12:01:23Z
.
When deleting an object on the MX platform, all objects belonging to that object are also deleted in a cascading fashion. For example, deleting a member
deletes not just the member
, but all associated accounts, transactions, holdings, etc. Deleting a user
also deletes all members associated with it, and so on.
Objects are “soft-deleted” first, meaning they are inaccessible for two weeks, but remain on the MX platform. This helps us accommodate end users who delete and then re-create a member with identical credentials, as well as facilitate support requests and possible fraud investigations. Soft-deleted objects are permanently deleted after this this period.
The MX Platform API uses conventional HTTP response codes to indicate the success or failure of a request, with supplementary error messaging as needed within response bodies.
Status | Explanation |
---|---|
2xx Success | |
200 OK |
Everything worked as expected with content returned. |
202 Accepted |
|
204 No Content |
Everything worked as expected without content returned. |
4xx Requester error | |
400 Bad Request |
Often, this means a required parameter was missing. |
401 Unauthorized |
Invalid MX-API-Key or MX-Client-ID provided. |
403 Forbidden |
The request was made from a non-whitelisted address or the feature is not available to the client. |
404 Not Found |
Invalid item/id/URL requested. |
405 Method Not Allowed |
A constraint on the requested endpoint wasn’t met. |
406 Not Acceptable |
The request didn’t specify a valid API version. |
409 Conflict |
1. An object with the given attributes already exists. 2. When attempting an aggregation on a member , the member already has an an aggregation of a different type running; e.g., calling the verify endpoint while a standard aggregation is already running, or calling fetch statements while an identification aggregation is already running. |
422 Unprocessable Entity |
The data provided cannot be processed. |
5xx Responder error — which are rare | |
500, 502, 504 Server errors |
Something went wrong with MX’s servers. |
503 Service Unavailable |
The MX Platform is being updated. |
Example error message
1
2
3
4
5
{
"error": {
"message": "Unrecognized institution.",
}
}
In addition to the required Authorization
header, each request also requires an Accept
header. POST and PUT requests also require a Content-Type
header.
'Content-Type: application/json'
'Accept: application/vnd.mx.api.v1+json'
All updateable resources created with the API support an optional metadata
field. You can use the metadata
field to store structured (key-value) data about a resource. For example, you could store a user’s username for your system, their sign-up date, the date and time of their last logon in your system, or all of these. Metadata is not used by MX.
Do not store sensitive information as metadata.
Updateable resources also contain an id
field. For instance, you may need to make certain that some resources are created only once or may need to sync data on the MX platform with data on your own platform. In these situations, you can give a unique id
to resources created with the MX Platform API. The API will return a 409 Conflict
error if a resource is created with an id
that already exists.
Standard aggregations are throttled after any type of job is attempted for a specific member (including verification, balance, history, identity, statements, and standard agg). The default throttle period is three hours (10,800 seconds), though this limit can vary from one institution to another. In other words, you generally cannot re-aggregate a member within three hours of any kind of job on a member. Members that have experienced credential-related errors won’t be throttled (connection_status
: REJECTED
, PREVENTED
, UPDATED
).
Throttled aggregations will not return an error; the response will have a status of 202 Accepted
and contain the current state of the member
, including the latest connection_status
.
Premium jobs are never throttled. That is, you can run an account verification right after another verification has finished (or balance request, or agg, etc.). However, because standard aggs are throttled after premium jobs, you should generally use the include_transactions
parameter to prevent any delays if standard data is needed at the same time as premium data.
There is no throttling of any kind when using the MX Bank test institution.
Be aware that aggregation is not guaranteed to return all relevant information or even every data point on a given resource. For instance, aggregation may return the balance
of an account, but return a null
value for the apr
and apy
fields. This is to be expected in all resources and all aggregations.
For startup partners, requests to the API are limited to 100 per minute in total, with a total of 100 records allowed per request. Startup partners are granted an additional one request per minute for every 100 users on the MX platform.
However, partners can also be allotted far larger rates. If you require a larger volume, reach out to your MX client strategy consultant.
Given these limitations, partners should not perform load testing on the API.
The development environment limits developers to 100 users and access to only some of the top financial institutions.
No user
may have more than 25 members in either the development or production environments.
MX encourages partners to use OAuth for authenticating with financial institutions. However, some institutions support OAuth, while others don’t. And some institutions only support OAuth and no other forms of authentication.
Furthermore, using OAuth requires you to register with institutions that support OAuth to ensure security and trustworthiness. This registration can only be done after MX has granted you production access; MX will handle this registration on your behalf. You can request production access and OAuth registration on the dashboard.
If you have production access but have not yet been registered with the institutions that support OAuth, these institutions will not be returned in any institution-related endpoints.
This also means that there is only one OAuth institution available in the integration environment: mx_bank_oauth
. You’ll have to use this for all OAuth development and testing in the integration environment.
All endpoints which return lists are paginated. These endpoints also support two query parameters which specify the number of records per page and the page to be returned.
Each response will include a pagination
object specifying information on the total number of entries and the current page.
Parameter | Definition |
---|---|
page |
This specifies the page to be returned. Defaults to 1 . |
records_per_page |
This specifies the number of records to be returned on each page. Defaults to 25 . The valid range is from 10 to 100 . |
Field | Definition |
---|---|
current_page |
The page delivered by the current response. |
per_page |
The number of records delivered with each page. |
total_entries |
The total number of records available. |
total_pages |
The total number of pages available. |
Example pagination object
1
2
3
4
5
6
"pagination": {
"current_page": 1,
"per_page": 25,
"total_entries": 2,
"total_pages": 1
}
PUT
request bodies cannot be empty. Therefore, at least one parameter must be given in a rooted body when making PUT
requests, even when no specific parameter is required. If no parameter is given, a 400 Bad Request
error will be returned.
We always try to make API changes backwards-compatible. However, when we make breaking changes to the MX Platform API, we’ll increment the version number. The current version is v1
. Versions are specified in a request’s Accept
header. All requests will access the current version unless a different version is specified with the request, so it’s best to always specify the API version. The current Accept header is application/vnd.mx.api.v1+json
.
Connect is a ready-made and embeddable application that allows you to quickly add members to the MX platform and navigate the complex aggregation process. It searches for institutions, creates new members, gathers credentials, prompts for MF, resolves errors, and can start verification and aggregation jobs.
You can use Connect by embedding it in a website with an iframe or a mobile application with a WebView. Both iframe and WebView implementations require their own specific configurations and handling of message events.
This endpoint allows partners to get a URL by passing the widget_type
in the request body, as well as configuring it in several different ways. In the case of Connect, that means setting the widget_type
to connect_widget
.
Partners may also pass an optional Accept-Language
header as well as a number of configuration options.
Note that this is a POST
request.
Configuration option | Description | Type |
---|---|---|
client_redirect_url |
Used as a redirect destination at the end of OAuth, if used with is_mobile_webview: true or oauth_referral_source: "APP" . |
String |
color_scheme |
Load the Connect widget in the specified color_scheme ; options are light and dark . Defaults to light . |
String |
current_institution_code |
Load the widget into the credential view for the specified institution. | String |
current_institution_guid |
Load the widget into the credential view for the specified institution. | String |
current_member_guid |
Load to a specific member that contains an error or requires MFA from the most recent job. current_member_guid takes precedence over current_institution_code . |
String |
disable_background_agg |
Set to true or false to explicitly set the value of background_aggregation_is_disabled for new members created through the Connect widget |
Boolean |
disable_institution_search |
When set to true , the institution search feature will be disabled and end users will not be able to navigate to it. Must be used with current_institution_code , current_instituion_guid , or current_member_guid . |
Boolean |
include_transactions |
When set to false while creating or updating a member, transaction data will not be automatically aggregated. Future manual or background aggregations will not be affected. Defaults to true . |
Boolean |
is_mobile_webview |
Renders the widget in a mobile WebView. Executes URL updates in place of the JavaScript event postMessages. | Boolean |
mode |
Loads the Connect widget into a specified mode; options are verification and aggregation . Defaults to aggregation . |
String |
oauth_referral_source |
This determines how MX will respond to the result of an OAuth flow. When set to APP , MX will redirect to the URI specified in the ui_message_webview_url_scheme .When set to BROWSER , MX will send a postMessage but not redirect.If is_mobile_webview is true , this defaults to APP . If false , it defaults to BROWSER . |
String |
ui_message_version |
Use this to specify which version of postMessage events are triggered. All new implementations must use version 4. Prior versions are deprecated. | Integer |
ui_message_webview_url_scheme |
Used in postMessages and OAuth redirects in WebViews. Defaults to mx . |
String |
update_credentials |
Loads widget to the update credential view of a current member. Optionally used with current_member_guid . This option should be used sparingly. The best practice is to use current_member_guid and let the widget resolve the issue. |
Boolean |
wait_for_full_aggregation |
Loads Connect, but forces the widget to wait until any aggregation-type process is complete in order to fire a member connected postMessage. This allows clients to have transactional data by the time the widget is closed. | Boolean |
widget_type |
Use this to specify which widget you would like to load. | String |
Endpoint:
POST /users/{user_guid}/widget_urls
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new WidgetRequestBody(
widgetUrl: new WidgetRequest(
colorScheme: "light",
currentInstitutionCode: "chase",
currentInstitutionGuid: "INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9",
currentMemberGuid: "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b",
disableInstitutionSearch: false,
includeTransactions: true,
isMobileWebview: true,
mode: "aggregation",
uiMessageVersion: 4,
uiMessageWebviewUrlScheme: "mx",
updateCredentials: false,
waitForFullAggregation: false,
widgetType: "connect_widget"
)
);
var acceptLanguage = "en-US";
try
{
WidgetResponseBody result = apiInstance.RequestWidgetURL(userGuid, requestBody, acceptLanguage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
widgetRequestBody := *mxplatformgo.NewWidgetRequestBodyWithDefaults()
widgetRequest := *mxplatformgo.NewWidgetRequestWithDefaults()
widgetRequest.SetColorScheme("light")
widgetRequest.SetCurrentInstitutionCode("chase")
widgetRequest.SetCurrentInstitutionGuid("INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9")
widgetRequest.SetCurrentMemberGuid("MBR-7c6f361b-e582-15b6-60c0-358f12466b4b")
widgetRequest.SetDisableInstitutionSearch(false)
widgetRequest.SetIncludeTransactions(true)
widgetRequest.SetIsMobileWebview(true)
widgetRequest.SetMode("aggregation")
widgetRequest.SetUiMessageVersion(int32(4))
widgetRequest.SetUiMessageWebviewUrlScheme("mx")
widgetRequest.SetUpdateCredentials(false)
widgetRequest.SetWaitForFullAggregation(false)
widgetRequest.SetWidgetType("connect_widget")
widgetRequestBody.SetWidgetUrl(widgetRequest)
acceptLanguage := "en-US"
resp, r, err := api_client.MxPlatformApi.RequestWidgetURL(ctx, userGuid).WidgetRequestBody(widgetRequestBody).AcceptLanguage(acceptLanguage).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestWidgetURL`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
WidgetRequestBody widgetRequestBody = new WidgetRequestBody();
WidgetRequest widgetRequest = new WidgetRequest();
widgetRequest.setColorScheme("light");
widgetRequest.setCurrentInstitutionCode("chase");
widgetRequest.setCurrentInstitutionGuid("INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9");
widgetRequest.setCurrentMemberGuid("MBR-7c6f361b-e582-15b6-60c0-358f12466b4b");
widgetRequest.setDisableInstitutionSearch(false);
widgetRequest.setIncludeTransactions(true);
widgetRequest.setIsMobileWebview(true);
widgetRequest.setMode("aggregation");
widgetRequest.setUiMessageVersion(4);
widgetRequest.setUiMessageWebviewUrlScheme("mx");
widgetRequest.setUpdateCredentials(false);
widgetRequest.setWaitForFullAggregation(false);
widgetRequest.setWidgetType("connect_widget");
widgetRequestBody.setWidgetUrl(widgetRequest);
String acceptLanguage = "en-US";
try {
WidgetResponseBody response = apiInstance.requestWidgetURL(userGuid, widgetRequestBody, acceptLanguage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54';
const requestBody = {
widget_url: {
color_scheme: 'light',
current_institution_code: 'chase',
current_institution_guid: 'INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9',
current_member_guid: 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
disable_institution_search: false,
include_transactions: true,
is_mobile_webview: true,
mode: 'aggregation',
ui_message_version: 4,
ui_message_webview_url_scheme: 'mx',
update_credentials: false,
wait_for_full_aggregation: false,
widget_type: 'connect_widget'
}
};
const acceptLanguage = 'en-US';
const response = await client.requestWidgetURL(userGuid, requestBody, acceptLanguage);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = WidgetRequestBody(
widget_url = WidgetRequest(
color_scheme = 'light',
current_institution_code = 'chase',
current_institution_guid = 'INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9',
current_member_guid = 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
disable_institution_search = False,
include_transactions = True,
is_mobile_webview = True,
mode = 'aggregation',
ui_message_version = 4,
ui_message_webview_url_scheme = 'mx',
update_credentials = False,
wait_for_full_aggregation = False,
widget_type = 'connect_widget'
)
)
accept_language = 'en-US'
try:
api_response = api_instance.request_widget_url(user_guid, request_body, accept_language=accept_language)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_widget_url: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
opts = {
accept_language: 'en-US'
}
request_body = ::MxPlatformRuby::WidgetRequestBody.new(
widget_url: ::MxPlatformRuby::WidgetRequest.new(
color_scheme: 'light',
current_institution_code: 'chase',
current_institution_guid: 'INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9',
current_member_guid: 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
disable_institution_search: false,
include_transactions: true,
is_mobile_webview: true,
mode: 'aggregation',
ui_message_version: 4,
ui_message_webview_url_scheme: 'mx',
update_credentials: false,
wait_for_full_aggregation: false,
widget_type: 'connect_widget'
)
)
begin
response = mx_platform_api.request_widget_url(user_guid, request_body, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_widget_url: #{e}"
end
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
curl -i -X POST 'https://int-api.mx.com/users/USR-fa7537f3-48aa-a683-a02a-b18940482f54/widget_urls' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-H 'Content-Type: application/json' \
-H 'Accept-Language: en-US' \
-u 'client_id:api_key' \
-d '{
"widget_url": {
"color_scheme": "light",
"current_institution_code": "chase",
"current_institution_guid": "INS-f1a3285d-e855-b61f-6aa7-8ae575c0e0e9",
"current_member_guid": "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b",
"disable_institution_search": false,
"include_transactions": true,
"is_mobile_webview": true,
"mode": "aggregation",
"ui_message_version": 4,
"ui_message_webview_url_scheme": "mx",
"update_credentials": false,
"wait_for_full_aggregation": false,
"widget_type": "connect_widget"
}
}'
1
2
3
4
5
6
7
class WidgetResponseBody {
WidgetUrl: class WidgetResponse {
Type: connect_widget,
Url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5,
UserId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
mxplatformgo.WidgetResponseBody{
WidgetUrl: mxplatformgo.WidgetResponse{
Type: "connect_widget"
Url: "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
UserId: "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
class WidgetResponseBody {
widgetUrl: class WidgetResponse {
type: connect_widget
url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5
userId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
widget_url: {
type: 'connect_widget',
url: 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
user_id: 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
{
'widget_url': {
'type': 'connect_widget',
'url': 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
'user_id': 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
#<::MxPlatformRuby::WidgetResponseBody
@widget_url=#<::MxPlatformRuby::WidgetResponse
@type='connect_widget',
@url='https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
@user_id='U-jeff-201709221210'
>
>
1
2
3
4
5
6
7
{
"widget_url": {
"type": "connect_widget",
"url": "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5",
"user_id": "U-jeff-201709221210"
}
}
This legacy endpoint allows partners to request a URL specifically for the Connect widget. While we continue to support this endpoint for existing partners, it should not be used in new integrations. Instead, use the request widget URL endpoint documented both above and under the heading on widgets below.
This endpoint accepts any configuration option relevant to the Connect widget.
Endpoint:
POST /users/{user_guid}/connect_widget_url
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new ConnectWidgetRequestBody(
config: new ConnectWidgetRequest(
colorScheme: "light",
currentInstitutionCode: "chase",
currentMemberGuid: "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b",
disableInstitutionSearch: false,
includeTransactions: true,
isMobileWebview: true,
mode: "aggregation",
uiMessageVersion: 4,
uiMessageWebviewUrlScheme: "mx",
updateCredentials: false,
waitForFullAggregation: false
)
);
try
{
ConnectWidgetResponseBody result = apiInstance.RequestConnectWidgetURL(userGuid, requestBody);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestConnectWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
connectWidgetRequestBody := *mxplatformgo.NewConnectWidgetRequestBodyWithDefaults()
connectWidgetRequest := *mxplatformgo.NewConnectWidgetRequestWithDefaults()
connectWidgetRequest.SetColorScheme("light")
connectWidgetRequest.SetCurrentInstitutionCode("chase")
connectWidgetRequest.SetCurrentMemberGuid("MBR-7c6f361b-e582-15b6-60c0-358f12466b4b")
connectWidgetRequest.SetDisableInstitutionSearch(false)
connectWidgetRequest.SetIncludeTransactions(true)
connectWidgetRequest.SetIsMobileWebview(true)
connectWidgetRequest.SetMode("aggregation")
connectWidgetRequest.SetUiMessageVersion(int32(4))
connectWidgetRequest.SetUiMessageWebviewUrlScheme("mx")
connectWidgetRequest.SetUpdateCredentials(false)
connectWidgetRequest.SetWaitForFullAggregation(false)
connectWidgetRequestBody.SetConfig(connectWidgetRequest)
resp, r, err := api_client.MxPlatformApi.RequestConnectWidgetURL(ctx, userGuid).ConnectWidgetRequestBody(connectWidgetRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestConnectWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestConnectWidgetURL`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
ConnectWidgetRequestBody connectWidgetRequestBody = new ConnectWidgetRequestBody();
ConnectWidgetRequest connectWidgetRequest = new ConnectWidgetRequest();
connectWidgetRequest.setColorScheme("light");
connectWidgetRequest.setCurrentInstitutionCode("chase");
connectWidgetRequest.setCurrentMemberGuid("MBR-7c6f361b-e582-15b6-60c0-358f12466b4b");
connectWidgetRequest.setDisableInstitutionSearch(false);
connectWidgetRequest.setIncludeTransactions(true);
connectWidgetRequest.setIsMobileWebview(true);
connectWidgetRequest.setMode("aggregation");
connectWidgetRequest.setUiMessageVersion(4);
connectWidgetRequest.setUiMessageWebviewUrlScheme("mx");
connectWidgetRequest.setUpdateCredentials(false);
connectWidgetRequest.setWaitForFullAggregation(false);
connectWidgetRequestBody.setConfig(connectWidgetRequest);
try {
ConnectWidgetResponseBody response = apiInstance.requestConnectWidgetURL(userGuid, connectWidgetRequestBody);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestConnectWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54';
const requestBody = {
config: {
color_scheme: 'light',
current_institution_code: 'chase',
current_member_guid: 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
disable_institution_search: false,
include_transactions: true,
is_mobile_webview: true,
mode: 'aggregation',
ui_message_version: 4,
ui_message_webview_url_scheme: 'mx',
update_credentials: false,
wait_for_full_aggregation: false
}
};
const response = await client.requestConnectWidgetURL(userGuid, requestBody);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = ConnectWidgetRequestBody(
config = ConnectWidgetRequest(
color_scheme = 'light',
current_institution_code = 'chase',
current_member_guid = 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
disable_institution_search = False,
include_transactions = True,
is_mobile_webview = True,
mode = 'aggregation',
ui_message_version = 4,
ui_message_webview_url_scheme = 'mx',
update_credentials = False,
wait_for_full_aggregation = False
)
)
try:
api_response = api_instance.request_connect_widget_url(user_guid, request_body)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_connect_widget_url: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = ::MxPlatformRuby::ConnectWidgetRequestBody.new(
config: ::MxPlatformRuby::ConnectWidgetRequest.new(
color_scheme: 'light',
current_institution_code: 'chase',
current_member_guid: 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
disable_institution_search: false,
include_transactions: true,
is_mobile_webview: true,
mode: 'aggregation',
ui_message_version: 4,
ui_message_webview_url_scheme: 'mx',
update_credentials: false,
wait_for_full_aggregation: false
)
)
begin
response = mx_platform_api.request_connect_widget_url(user_guid, request_body)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_connect_widget_url: #{e}"
end
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
curl -i -X POST 'https://int-api.mx.com/users/USR-fa7537f3-48aa-a683-a02a-b18940482f54/connect_widget_url' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-H 'Content-Type: application/json' \
-u 'client_id:api_key' \
-d '{
"config": {
"color_scheme": "light",
"current_institution_code": "chase",
"current_member_guid": "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b",
"disable_institution_search": false,
"include_transactions": true,
"is_mobile_webview": true,
"mode": "aggregation",
"ui_message_version": 4,
"ui_message_webview_url_scheme": "mx",
"update_credentials": false,
"wait_for_full_aggregation": false
}
}'
1
2
3
4
5
6
class ConnectWidgetResponseBody {
User: class ConnectWidgetResponse {
ConnectWidgetUrl: https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8,
Guid: USR-fa7537f3-48aa-a683-a02a-b18940482f54
}
}
1
2
3
4
5
6
mxplatformgo.ConnectWidgetResponseBody{
User: mxplatformgo.ConnectWidgetResponse{
ConnectWidgetUrl: "https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8"
Guid: "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
}
}
1
2
3
4
5
6
class ConnectWidgetResponseBody {
user: class ConnectWidgetResponse {
connectWidgetUrl: https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8
guid: USR-fa7537f3-48aa-a683-a02a-b18940482f54
}
}
1
2
3
4
5
6
{
user: {
connect_widget_url: 'https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8',
guid: 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
}
}
1
2
3
4
5
6
{
'user': {
'connect_widget_url': 'https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8',
'guid': 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
}
}
1
2
3
4
5
6
#<::MxPlatformRuby::ConnectWidgetResponseBody
@user=#<::MxPlatformRuby::ConnectWidgetResponse
@connect_widget_url='https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8',
@guid='USR-fa7537f3-48aa-a683-a02a-b18940482f54'
>
>
1
2
3
4
5
6
{
"user": {
"connect_widget_url": "https://int-widgets.moneydesktop.com/md/connect/jb1rA14m85tw2lyvpgfx4gc6d3Z8z8Ayb8",
"guid": "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
}
}
Connect uses a responsive design. Page styles and layout are subject to change, and elements may become hidden or visible at different widths.
The following are the minimum dimensions supported for mobile and desktop platforms.
Below are the width breakpoints at which the design may change. These are based on typical industry device resolutions. These are subject to change in the future.
Configuring the MX Connect widget really unlocks the potential and power of the widget. Configuration will help you with tasks like loading the widget for a specific institution, answering MFA, fixing a member in bad state, and more. You’ll find a list of configuration scenarios and example requests below.
Getting a widget in a specific language requires passing the desired language as a parameter in the Accept-Language
header with requests to the get widget URL endpoint.
If no header is provided, widgets will default to en-US
.
Only some widgets are currently available in multiple languages.
Supported languages and widgets
Language | Widget |
---|---|
en-CA |
All |
en-US |
All |
es |
connect_widget |
fr |
accounts_widget, connect_widget, pulse_widget, mini_pulse_carousel_widget |
fr-CA |
accounts_widget, connect_widget, pulse_widget, mini_pulse_carousel_widget |
Scenario | Settings |
---|---|
Answer MFA for a specific member | Set the current_member_guid to a member whose connection_status is CHALLENGED . Connect will load the MFA view so the end user can respond to the MFA challenge. |
Resolve a member’s error(s) | Set the current_member_guid option to a member in an error state. Connect will load in the error view so the end user can resolve the error. |
Run verification with a specific institution | Set the current_institution_code option to the desired institution’s code, and set the mode option to verification . Connect will load the login view for that institution. |
Run aggregation with a specific institution | Set the current_institution_code option to the desired institution’s code, but do not set the mode option. Connect will load the login view for that institution. |
Run aggregation but exclude transactions | Set the include_transactions option to false when creating or updating a member. Connect will not automatically aggregate transaction data. Future manual or background aggregations will not be affected. |
Disable search when loading a specific institution | Set disable_institution_search option to true and set the current_institution_code or current_member_guid option. Connect will load the login view for the specified institution, but will not allow the end user to navigate to the search view. |
Update a member’s credentials | Set the current_member_guid to the desired member’s GUID, and set the update_credentials option to true . Connect will load the update credentials view for the member. This option should be used sparingly. It is best practice to only use current_member_guid and let the widget take care of things. |
Get the member connected postMessage after aggregation is complete | Set wait_for_full_aggregation option to true and load Connect normally. Connect will wait for the aggregation job to complete before sending the member connected postMessage. This ensures that transaction data is available before moving on. |
Sometimes you don’t need transaction data right away, or you may be concerned that gathering transaction data may take some time and delay your preferred flow. For those who don’t need the transaction data up front, you can use set the include_transactions
option to false
to potentially speed up a first-time aggregation.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
// Configure with your Client ID/API Key from https://dashboard.mx.com
Configuration config = new Configuration();
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new WidgetRequestBody(
widgetUrl: new WidgetRequest(
includeTransactions: false,
widgetType: "connect_widget"
)
);
try
{
WidgetResponseBody result = apiInstance.RequestWidgetURL(userGuid, requestBody, acceptLanguage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
curl -i -X POST https://int-api.mx.com/users/USR-29eab3cf-6a87-fe97-6279-563b63e75a53/widget_urls \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key' \
-H 'Content-type: application/json' \
-d '{
"widget_url": {
"widget_type": "connect_widget",
"include_transactions": false
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
widgetRequestBody := *mxplatformgo.NewWidgetRequestBodyWithDefaults()
widgetRequest := *mxplatformgo.NewWidgetRequestWithDefaults()
widgetRequest.SetIncludeTransactions(false)
widgetRequest.SetWidgetType("connect_widget")
widgetRequestBody.SetWidgetURL(widgetRequest)
resp, r, err := api_client.MxPlatformApi.RequestWidgetURL(ctx, userGuid).WidgetRequestBody(widgetRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestWidgetURL`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
WidgetRequestBody widgetRequestBody = new WidgetRequestBody();
WidgetRequest widgetRequest = new WidgetRequest();
widgetRequest.setIncludeTransactions(false);
widgetRequest.setWidgetType("connect_widget");
widgetRequestBody.setWidgetUrl(widgetRequest);
String acceptLanguage = "en-US";
try {
WidgetResponseBody response = apiInstance.requestWidgetURL(userGuid, widgetRequestBody, acceptLanguage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
basePath: 'https://int-api.mx.com',
username: 'Client ID',
password: 'API Key',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53';
const requestBody = {
widget_url: {
include_transactions: false,
widget_type: 'connect_widget'
}
};
const response = await client.requestWidgetURL(userGuid, requestBody);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration) as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = WidgetRequestBody(
widget_url = WidgetRequest(
include_transactions = False,
widget_type = 'connect_widget'
)
)
try:
api_response = api_instance.request_widget_url(user_guid, request_body, accept_language=accept_language)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_widget_url: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
config.username = 'Your Client ID from https://dashboard.mx.com'
config.password = 'Your API Key from https://dashboard.mx.com'
config.server_index = 1 # Configure server. 0 for production, 1 for development
end
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new
user_guid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53'
opts = {}
request_body = ::MxPlatformRuby::WidgetRequestBody.new(
widget_url: ::MxPlatformRuby::WidgetRequest.new(
include_transactions: false,
widget_type: 'connect_widget'
)
)
begin
response = mx_platform_api.request_widget_url(user_guid, request_body, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_widget_url: #{e}"
end
1
2
3
4
5
6
7
class WidgetResponseBody {
WidgetUrl: class WidgetResponse {
Type: connect_widget,
Url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5,
UserId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
"widget_url": {
"type": "connect_widget",
"url": "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5",
"user_id": "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
mxplatformgo.WidgetResponseBody{
WidgetURL: mxplatformgo.WidgetResponse{
Type: "connect_widget"
URL: "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
UserId: "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
class WidgetResponseBody {
widgetURL: class WidgetResponse {
type: connect_widget
url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5
userId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
widget_url: {
type: 'connect_widget',
url: 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
user_id: 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
{
'widget_url': {
'type': 'connect_widget',
'url': 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
'user_id': 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
#<::MxPlatformRuby::WidgetResponseBody
@widget_url=#<::MxPlatformRuby::WidgetResponse
@type='connect_widget',
@url='https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
@user_id='U-jeff-201709221210'
>
>
MX Connect can be loaded directly into a specific institution for gathering credentials.
You should consider using this configuration with the disable_institution_search
option to prevent the end user from going back to the search and loading a separate institution manually.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
// Configure with your Client ID/API Key from https://dashboard.mx.com
Configuration config = new Configuration();
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new WidgetRequestBody(
widgetUrl: new WidgetRequest(
currentInstitutionCode: "{bank code}",
widgetType: "connect_widget"
)
);
try
{
WidgetResponseBody result = apiInstance.RequestWidgetURL(userGuid, requestBody, acceptLanguage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
curl -i -X POST https://int-api.mx.com/users/USR-29eab3cf-6a87-fe97-6279-563b63e75a53/widget_urls \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key' \
-H 'Content-type: application/json' \
-d '{
"widget_url": {
"widget_type": "connect_widget",
"current_institution_code": {bank code}
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
widgetRequestBody := *mxplatformgo.NewWidgetRequestBodyWithDefaults()
widgetRequest := *mxplatformgo.NewWidgetRequestWithDefaults()
widgetRequest.SetCurrentInstitutionCode("{bank code}")
widgetRequest.SetWidgetType("connect_widget")
widgetRequestBody.SetWidgetURL(widgetRequest)
resp, r, err := api_client.MxPlatformApi.RequestWidgetURL(ctx, userGuid).WidgetRequestBody(widgetRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestWidgetURL`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
WidgetRequestBody widgetRequestBody = new WidgetRequestBody();
WidgetRequest widgetRequest = new WidgetRequest();
widgetRequest.setCurrentInstitutionGuid("{bank code}");
widgetRequest.setWidgetType("connect_widget");
widgetRequestBody.setWidgetUrl(widgetRequest);
String acceptLanguage = "en-US";
try {
WidgetResponseBody response = apiInstance.requestWidgetURL(userGuid, widgetRequestBody, acceptLanguage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
basePath: 'https://int-api.mx.com',
username: 'Client ID',
password: 'API Key',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53';
const requestBody = {
widget_url: {
current_institution_code: '{bank code}',
widget_type: 'connect_widget'
}
};
const response = await client.requestWidgetURL(userGuid, requestBody);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration) as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = WidgetRequestBody(
widget_url = WidgetRequest(
current_institution_code = '{bank code}',
widget_type = 'connect_widget'
)
)
try:
api_response = api_instance.request_widget_url(user_guid, request_body, accept_language=accept_language)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_widget_url: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
config.username = 'Your Client ID from https://dashboard.mx.com'
config.password = 'Your API Key from https://dashboard.mx.com'
config.server_index = 1 # Configure server. 0 for production, 1 for development
end
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new
user_guid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53'
opts = {}
request_body = ::MxPlatformRuby::WidgetRequestBody.new(
widget_url: ::MxPlatformRuby::WidgetRequest.new(
current_institution_code: '{bank code}',
widget_type: 'connect_widget'
)
)
begin
response = mx_platform_api.request_widget_url(user_guid, request_body, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_widget_url: #{e}"
end
1
2
3
4
5
6
7
class WidgetResponseBody {
WidgetUrl: class WidgetResponse {
Type: connect_widget,
Url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5,
UserId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
"widget_url": {
"type": "connect_widget",
"url": "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5",
"user_id": "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
mxplatformgo.WidgetResponseBody{
WidgetURL: mxplatformgo.WidgetResponse{
Type: "connect_widget"
URL: "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
UserId: "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
class WidgetResponseBody {
widgetURL: class WidgetResponse {
type: connect_widget
url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5
userId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
widget_url: {
type: 'connect_widget',
url: 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
user_id: 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
{
'widget_url': {
'type': 'connect_widget',
'url': 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
'user_id': 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
#<::MxPlatformRuby::WidgetResponseBody
@widget_url=#<::MxPlatformRuby::WidgetResponse
@type='connect_widget',
@url='https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
@user_id='U-jeff-201709221210'
>
>
MX Connect can prompt for MFA, updating old credentials, or “repair” members that are in a bad state. This is done by loading Connect directly into a specific member.
Rather than trying to figure out what do with with each and every connection_status
, it is often best to simply load Connect with the member_guid
in question and allow it to automatically determine the best course of action for the end user.
You should consider using this configuration with the disable_institution_search
option to prevent the end user from going back to the search to create a new member.
MX does not recommend using this configuration with the update_credentials
option.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
// Configure with your Client ID/API Key from https://dashboard.mx.com
Configuration config = new Configuration();
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new WidgetRequestBody(
widgetUrl: new WidgetRequest(
currentMemberGuid: "{member_guid}",
widgetType: "connect_widget"
)
);
try
{
WidgetResponseBody result = apiInstance.RequestWidgetURL(userGuid, requestBody, acceptLanguage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
curl -i -X POST https://int-api.mx.com/users/USR-29eab3cf-6a87-fe97-6279-563b63e75a53/widget_urls \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key' \
-H 'Content-type: application/json' \
-d '{
"widget_url": {
"widget_type": "connect_widget",
"current_member_guid": {member_guid}
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
widgetRequestBody := *mxplatformgo.NewWidgetRequestBodyWithDefaults()
widgetRequest := *mxplatformgo.NewWidgetRequestWithDefaults()
widgetRequest.SetCurrentMemberGuid("{member_guid}")
widgetRequest.SetWidgetType("connect_widget")
widgetRequestBody.SetWidgetURL(widgetRequest)
resp, r, err := api_client.MxPlatformApi.RequestWidgetURL(ctx, userGuid).WidgetRequestBody(widgetRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestWidgetURL`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
WidgetRequestBody widgetRequestBody = new WidgetRequestBody();
WidgetRequest widgetRequest = new WidgetRequest();
widgetRequest.setCurrentMemberGuid("{member_guid}");
widgetRequest.setWidgetType("connect_widget");
widgetRequestBody.setWidgetUrl(widgetRequest);
String acceptLanguage = "en-US";
try {
WidgetResponseBody response = apiInstance.requestWidgetURL(userGuid, widgetRequestBody, acceptLanguage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
basePath: 'https://int-api.mx.com',
username: 'Client ID',
password: 'API Key',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53';
const requestBody = {
widget_url: {
current_member_guid: '{member_guid}',
widget_type: 'connect_widget'
}
};
const response = await client.requestWidgetURL(userGuid, requestBody);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration) as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = WidgetRequestBody(
widget_url = WidgetRequest(
current_member_guid = '{member_guid}',
widget_type = 'connect_widget'
)
)
try:
api_response = api_instance.request_widget_url(user_guid, request_body, accept_language=accept_language)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_widget_url: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
config.username = 'Your Client ID from https://dashboard.mx.com'
config.password = 'Your API Key from https://dashboard.mx.com'
config.server_index = 1 # Configure server. 0 for production, 1 for development
end
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new
user_guid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53'
opts = {}
request_body = ::MxPlatformRuby::WidgetRequestBody.new(
widget_url: ::MxPlatformRuby::WidgetRequest.new(
current_member_guid: '{member_guid}',
widget_type: 'connect_widget'
)
)
begin
response = mx_platform_api.request_widget_url(user_guid, request_body, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_widget_url: #{e}"
end
1
2
3
4
5
6
7
class WidgetResponseBody {
WidgetUrl: class WidgetResponse {
Type: connect_widget,
Url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5,
UserId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
"widget_url": {
"type": "connect_widget",
"url": "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5",
"user_id": "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
mxplatformgo.WidgetResponseBody{
WidgetURL: mxplatformgo.WidgetResponse{
Type: "connect_widget"
URL: "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
UserId: "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
class WidgetResponseBody {
widgetURL: class WidgetResponse {
type: connect_widget
url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5
userId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
widget_url: {
type: 'connect_widget',
url: 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
user_id: 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
{
'widget_url': {
'type': 'connect_widget',
'url': 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
'user_id': 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
#<::MxPlatformRuby::WidgetResponseBody
@widget_url=#<::MxPlatformRuby::WidgetResponse
@type='connect_widget',
@url='https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
@user_id='U-jeff-201709221210'
>
>
It is imperative that you correctly configure Connect when embedding in a WebView. See the WebView section for more information.
Setting the mode
to verification
will change several behaviors in Connect:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
// Configure with your Client ID/API Key from https://dashboard.mx.com
Configuration config = new Configuration();
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new WidgetRequestBody(
widgetUrl: new WidgetRequest(
mode: "verification",
widgetType: "connect_widget"
)
);
try
{
WidgetResponseBody result = apiInstance.RequestWidgetURL(userGuid, requestBody, acceptLanguage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
curl -i -X POST https://int-api.mx.com/users/USR-29eab3cf-6a87-fe97-6279-563b63e75a53/widget_urls \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key' \
-H 'Content-type: application/json' \
-d '{
"widget_url": {
"widget_type": "connect_widget",
"mode": "verification"
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
widgetRequestBody := *mxplatformgo.NewWidgetRequestBodyWithDefaults()
widgetRequest := *mxplatformgo.NewWidgetRequestWithDefaults()
widgetRequest.SetMode("verification")
widgetRequest.SetWidgetType("connect_widget")
widgetRequestBody.SetWidgetURL(widgetRequest)
resp, r, err := api_client.MxPlatformApi.RequestWidgetURL(ctx, userGuid).WidgetRequestBody(widgetRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestWidgetURL`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
WidgetRequestBody widgetRequestBody = new WidgetRequestBody();
WidgetRequest widgetRequest = new WidgetRequest();
widgetRequest.setMode("verification");
widgetRequest.setWidgetType("connect_widget");
widgetRequestBody.setWidgetUrl(widgetRequest);
String acceptLanguage = "en-US";
try {
WidgetResponseBody response = apiInstance.requestWidgetURL(userGuid, widgetRequestBody, acceptLanguage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
basePath: 'https://int-api.mx.com',
username: 'Client ID',
password: 'API Key',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53';
const requestBody = {
widget_url: {
mode: 'verification',
widget_type: 'connect_widget'
}
};
const response = await client.requestWidgetURL(userGuid, requestBody);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration) as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = WidgetRequestBody(
widget_url = WidgetRequest(
mode = 'verification',
widget_type = 'connect_widget'
)
)
try:
api_response = api_instance.request_widget_url(user_guid, request_body, accept_language=accept_language)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_widget_url: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
config.username = 'Your Client ID from https://dashboard.mx.com'
config.password = 'Your API Key from https://dashboard.mx.com'
config.server_index = 1 # Configure server. 0 for production, 1 for development
end
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new
user_guid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53'
opts = {}
request_body = ::MxPlatformRuby::WidgetRequestBody.new(
widget_url: ::MxPlatformRuby::WidgetRequest.new(
mode: 'verification',
widget_type: 'connect_widget'
)
)
begin
response = mx_platform_api.request_widget_url(user_guid, request_body, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_widget_url: #{e}"
end
1
2
3
4
5
6
7
class WidgetResponseBody {
WidgetUrl: class WidgetResponse {
Type: connect_widget,
Url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5,
UserId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
"widget_url": {
"type": "connect_widget",
"url": "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5",
"user_id": "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
mxplatformgo.WidgetResponseBody{
WidgetURL: mxplatformgo.WidgetResponse{
Type: "connect_widget"
URL: "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
UserId: "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
class WidgetResponseBody {
widgetURL: class WidgetResponse {
type: connect_widget
url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5
userId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
widget_url: {
type: 'connect_widget',
url: 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
user_id: 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
{
'widget_url': {
'type': 'connect_widget',
'url': 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
'user_id': 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
#<::MxPlatformRuby::WidgetResponseBody
@widget_url=#<::MxPlatformRuby::WidgetResponse
@type='connect_widget',
@url='https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
@user_id='U-jeff-201709221210'
>
>
By default, Connect will complete its flow once the member has a connection_status
of CONNECTED
. At this point, the member is connected to the financial institution, but account and transaction data may not be gathered yet.
If you would like Connect to wait for account, transaction, or verification data before finishing its flow, use the wait_for_full_aggregation
option.
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
// Configure with your Client ID/API Key from https://dashboard.mx.com
Configuration config = new Configuration();
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new WidgetRequestBody(
widgetUrl: new WidgetRequest(
waitForFullAggregation: true,
widgetType: "connect_widget"
)
);
try
{
WidgetResponseBody result = apiInstance.RequestWidgetURL(userGuid, requestBody, acceptLanguage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
curl -i -X POST https://int-api.mx.com/users/USR-29eab3cf-6a87-fe97-6279-563b63e75a53/widget_urls \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key' \
-H 'Content-type: application/json' \
-d '{
"widget_url": {
"widget_type": "connect_widget",
"wait_for_full_aggregation": true
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
widgetRequestBody := *mxplatformgo.NewWidgetRequestBodyWithDefaults()
widgetRequest := *mxplatformgo.NewWidgetRequestWithDefaults()
widgetRequest.SetWaitForFullAggregation(true)
widgetRequest.SetWidgetType("connect_widget")
widgetRequestBody.SetWidgetURL(widgetRequest)
resp, r, err := api_client.MxPlatformApi.RequestWidgetURL(ctx, userGuid).WidgetRequestBody(widgetRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestWidgetURL`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
WidgetRequestBody widgetRequestBody = new WidgetRequestBody();
WidgetRequest widgetRequest = new WidgetRequest();
widgetRequest.setWaitForFullAggregation(true);
widgetRequest.setWidgetType("connect_widget");
widgetRequestBody.setWidgetUrl(widgetRequest);
String acceptLanguage = "en-US";
try {
WidgetResponseBody response = apiInstance.requestWidgetURL(userGuid, widgetRequestBody, acceptLanguage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
basePath: 'https://int-api.mx.com',
username: 'Client ID',
password: 'API Key',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53';
const requestBody = {
widget_url: {
wait_for_full_aggregation: true,
widget_type: 'connect_widget'
}
};
const response = await client.requestWidgetURL(userGuid, requestBody);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration) as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = WidgetRequestBody(
widget_url = WidgetRequest(
wait_for_full_aggregation = True,
widget_type = 'connect_widget'
)
)
try:
api_response = api_instance.request_widget_url(user_guid, request_body, accept_language=accept_language)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_widget_url: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
config.username = 'Your Client ID from https://dashboard.mx.com'
config.password = 'Your API Key from https://dashboard.mx.com'
config.server_index = 1 # Configure server. 0 for production, 1 for development
end
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new
user_guid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53'
opts = {}
request_body = ::MxPlatformRuby::WidgetRequestBody.new(
widget_url: ::MxPlatformRuby::WidgetRequest.new(
wait_for_full_aggregation: true,
widget_type: 'connect_widget'
)
)
begin
response = mx_platform_api.request_widget_url(user_guid, request_body, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_widget_url: #{e}"
end
1
2
3
4
5
6
7
class WidgetResponseBody {
WidgetUrl: class WidgetResponse {
Type: connect_widget,
Url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5,
UserId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
"widget_url": {
"type": "connect_widget",
"url": "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5",
"user_id": "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
mxplatformgo.WidgetResponseBody{
WidgetURL: mxplatformgo.WidgetResponse{
Type: "connect_widget"
URL: "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
UserId: "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
class WidgetResponseBody {
widgetURL: class WidgetResponse {
type: connect_widget
url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5
userId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
widget_url: {
type: 'connect_widget',
url: 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
user_id: 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
{
'widget_url': {
'type': 'connect_widget',
'url': 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
'user_id': 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
#<::MxPlatformRuby::WidgetResponseBody
@widget_url=#<::MxPlatformRuby::WidgetResponse
@type='connect_widget',
@url='https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
@user_id='U-jeff-201709221210'
>
>
Once you’ve generated a URL, you can pass that information on to a JavaScript loader provided by MX. This loader allows you to further configure your Connect widget, including the size as well as all the supported configuration options, inside the config
object.
It also allows you to listen for event messages that indicate loading or a successful member creation.
Parameter | Data Type | Description | Required? |
---|---|---|---|
config |
Object | This object allows you to set additional parameters to load the MX Connect widget in a specific state. | No |
height |
String | Desired height of the iframe. Defaults to 600 pixels. | No |
id |
String | The id of the DOM element you’ll load the widget into. |
Yes |
onEvent |
Function | A general event handler. Only available with ui_message_version: 4 or higher, which is the required version for the MX Platform API. |
No |
width |
String | Desired width of the iframe. Defaults to 100% of the parent. | No |
url |
String | A URL for the widget provided as a response to the POST request above. |
Yes |
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
<script src="https://atrium.mx.com/connect.js"></script>
/**
* The reference to "atrium" is a holdover from a legacy API.
* Nevertheless, this is still the correct source for the widget loader
* even in the context of the Platform API.
*/
<script>
var mxConnect = new window.MXConnect({
id: "connect-widget",
iframeTitle: "Connect",
/**
* Callback that for handling all events within Connect.
* Only called in ui_message_version 4 or higher.
*
* The events called here are the same events that come through post
* messages.
*/
onEvent: function (type, payload) {
console.log("onEvent", type, payload);
},
config: {
ui_message_version: 4
},
targetOrigin: "*",
})
</script>
Because of the technical limitations of WebView-based implementations, an alternative to standard postMessages is required. If Connect is configured with is_mobile_webview
set to true
, we will use navigation events with window.location = url
instead of window.postMessage(message)
ui_message_webview_url_scheme
will be mx://
by default.
Example navigation event schema
{ui_message_webview_url_scheme}://{some/path}?metadata={jsonString}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
// Configure with your Client ID/API Key from https://dashboard.mx.com
Configuration config = new Configuration();
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new WidgetRequestBody(
widgetUrl: new WidgetRequest(
isMobileWebview: true,
uiMessageVersion: 4,
uiMessageWebviewUrlScheme: "{app_scheme}",
widgetType: "connect_widget"
)
);
try
{
WidgetResponseBody result = apiInstance.RequestWidgetURL(userGuid, requestBody, acceptLanguage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.RequestWidgetURL: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
// Possible navigation events based on the config above:
// `mx://load`
// `yourAppScheme://connect/institutionSearch?metadata={...json...}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
curl -i -X POST https://int-api.mx.com/users/USR-29eab3cf-6a87-fe97-6279-563b63e75a53/widget_urls \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key' \
-H 'Content-type: application/json' \
-d '{
"widget_url": {
"widget_type": "connect_widget",
"is_mobile_webview": true,
"ui_message_version": 4,
"ui_message_webview_url_scheme": "{app_scheme}"
}
}'
# Possible navigation events based on the config above:
# `mx://load`
# `yourAppScheme://connect/institutionSearch?metadata={...json...}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
widgetRequestBody := *mxplatformgo.NewWidgetRequestBodyWithDefaults()
widgetRequest := *mxplatformgo.NewWidgetRequestWithDefaults()
widgetRequest.SetIsMobileWebview(true)
widgetRequest.SetUiMessageVersion(int32(4))
widgetRequest.SetUiMessageWebviewURLScheme("{app_scheme}")
widgetRequest.SetWidgetType("connect_widget")
widgetRequestBody.SetWidgetURL(widgetRequest)
resp, r, err := api_client.MxPlatformApi.RequestWidgetURL(ctx, userGuid).WidgetRequestBody(widgetRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.RequestWidgetURL``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.RequestWidgetURL`: %#v\n", resp)
}
// Possible navigation events based on the config above:
// `mx://load`
// `yourAppScheme://connect/institutionSearch?metadata={...json...}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
WidgetRequestBody widgetRequestBody = new WidgetRequestBody();
WidgetRequest widgetRequest = new WidgetRequest();
widgetRequest.setIsMobileWebview(true);
widgetRequest.setUiMessageVersion(4);
widgetRequest.setUiMessageWebviewURLScheme("{app_scheme}");
widgetRequest.setWidgetType("connect_widget");
widgetRequestBody.setWidgetUrl(widgetRequest);
String acceptLanguage = "en-US";
try {
WidgetResponseBody response = apiInstance.requestWidgetURL(userGuid, widgetRequestBody, acceptLanguage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#requestWidgetURL");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
// Possible navigation events based on the config above:
// `mx://load`
// `yourAppScheme://connect/institutionSearch?metadata={...json...}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
basePath: 'https://int-api.mx.com',
username: 'Client ID',
password: 'API Key',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53';
const requestBody = {
widget_url: {
is_mobile_webview: true,
ui_message_version: 4,
ui_message_webview_url_scheme: '{app_scheme}',
widget_type: 'connect_widget'
}
};
const response = await client.requestWidgetURL(userGuid, requestBody);
console.log(response.data);
// Possible navigation events based on the config above:
// `mx://load`
// `yourAppScheme://connect/institutionSearch?metadata={...json...}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration) as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = WidgetRequestBody(
widget_url = WidgetRequest(
is_mobile_webview = True,
ui_message_version = 4,
ui_message_webview_url_scheme = '{app_scheme}',
widget_type = 'connect_widget'
)
)
accept_language = 'en-US'
try:
api_response = api_instance.request_widget_url(user_guid, request_body, accept_language=accept_language)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->request_widget_url: %s\n" % e)
# Possible navigation events based on the config above:
# `mx://load`
# `yourAppScheme://connect/institutionSearch?metadata={...json...}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
config.username = 'Your Client ID from https://dashboard.mx.com'
config.password = 'Your API Key from https://dashboard.mx.com'
config.server_index = 1 # Configure server. 0 for production, 1 for development
end
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new
user_guid = 'USR-29eab3cf-6a87-fe97-6279-563b63e75a53'
opts = {}
request_body = ::MxPlatformRuby::WidgetRequestBody.new(
widget_url: ::MxPlatformRuby::WidgetRequest.new(
is_mobile_webview: true,
ui_message_version: 4,
ui_message_webview_url_scheme: '{app_scheme}',
widget_type: 'connect_widget'
)
)
begin
response = mx_platform_api.request_widget_url(user_guid, request_body, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->request_widget_url: #{e}"
end
# Possible navigation events based on the config above:
# `mx://load`
# `yourAppScheme://connect/institutionSearch?metadata={...json...}
1
2
3
4
5
6
7
class WidgetResponseBody {
WidgetUrl: class WidgetResponse {
Type: connect_widget,
Url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5,
UserId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
"widget_url": {
"type": "connect_widget",
"url": "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5",
"user_id": "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
mxplatformgo.WidgetResponseBody{
WidgetURL: mxplatformgo.WidgetResponse{
Type: "connect_widget"
URL: "https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5"
UserId: "U-jeff-201709221210"
}
}
1
2
3
4
5
6
7
class WidgetResponseBody {
widgetURL: class WidgetResponse {
type: connect_widget
url: https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5
userId: U-jeff-201709221210
}
}
1
2
3
4
5
6
7
{
widget_url: {
type: 'connect_widget',
url: 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
user_id: 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
{
'widget_url': {
'type': 'connect_widget',
'url': 'https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
'user_id': 'U-jeff-201709221210'
}
}
1
2
3
4
5
6
7
#<::MxPlatformRuby::WidgetResponseBody
@widget_url=#<::MxPlatformRuby::WidgetResponse
@type='connect_widget',
@url='https://int-widgets.moneydesktop.com/md/connect/yxcdk7f1nb99jwApp34lA24m0AZ8rzprgmw17gm8z8h2AzjyAnd1rj42qfv42r3xnn07Amfwlg3j09hwp8bkq8tc5z21j33xjggmp2qtlpkz2v4gywfhfn31l44tx2w91bfc2thc58j4syqp0hgxcyvA4g7754hk7gjc56kt7tc36s45mmkdz2jqqqydspytmtr3dAb9jh6fkb24f3zkfpdjj0v77f0vmrtzvzxkmxz7dklsq8gd0gstkbhlw5bgpgc3m9mAtpAcr2w15gwy5xc4blgxppl42Avnm63291z3cyp0wm3lqgmvgzdAddct423gAdqxdlfx5d4mvc0ck2gt7ktqgks4vxq1pAy5',
@user_id='U-jeff-201709221210'
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
public class MainActivity extends AppCompatActivity {
private WebView webView = null;
@Override
protected void onCreate(Bundle savedInstanceState) {
webView = (WebView) findViewById(R.id.webview);
webView.setWebViewClient(new ConnectWebviewClient());
webView.getSettings().setDomStorageEnabled(true);
webView.getSettings().setJavaScriptEnabled(true);
}
private class ConnectWebviewClient extends WebViewClient {
@Override
public boolean shouldOverrideUrlLoading(WebView view, String url) {
if (url.startsWith("mx://")) {
return true;
}
return false;
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
class ViewController: UIViewController, WKUIDelegate {
override func viewDidLoad() {
super.viewDidLoad()
webView.delegate = self
...
}
func webView(_ webView: WKWebView, decidePolicyFor
navigationAction: WKNavigationAction,
decisionHandler: @escaping (WKNavigationActionPolicy) -> Swift.Void) {
// Intercept custom URI
let surl = navigationAction.url?.absoluteString
if (surl?.hasPrefix("mx://"))! {
// Take action here
// Cancel request
decisionHandler(.cancel)
return
}
// Allow request
decisionHandler(.allow)
}
}
There are several configuration options that influence how OAuth works in WebViews, described in detail below.
If you are looking for a more guided approach to integrating Connect into iOS, Android, or as a hybrid app, see the guide
This setting influences how the widget acts in WebView contexts. If set to true
, the widget will:
window.location = {scheme}://{event path}?metadata={json encoded metadata}
instead of window.postMessage(eventObject)
;oauth_referral_source
to APP
so the OAuth flow will redirect back to a native application instead of sending a postMessage to the opening window;This setting influences which postMessages are sent from the widget. It defaults to version 4
, which is the most recent version of postMessages. All other versions are deprecated and should not be used.
The OAuth requested postMessage in particular is a key event for WebView implementations. You’ll need to capture this message and redirect the user to the provided URL.
This setting is used as the redirect destination at the end of OAuth. MX will append query string parameters to the supplied URL that describe what happened during OAuth.
Query parameters added to the URL:
Name | Values | Type | Description |
---|---|---|---|
status |
success error |
String | This indicates whether the OAuth process was successful or errored. |
member_guid |
MBR-XXX |
String | The unique identifier for the member that was created or updated during the OAuth process. |
Example
client_redirect_url: "https://mx.com"
https://mx.com?status=success&member_guid={MBR-XXX}
Example
client_redirect_url: "https://mx.com?state=mystate"
https://mx.com?state=mystate&status=success&member_guid={MBR-XXX}
This setting is used alongside either is_mobile_webview: true
or oauth_referral_source: "APP"
. It’s value is used as the scheme for WebView event messages. It is also the destination scheme for the redirect at the end of OAuth. MX Recommends using client_redirect_url
rather than ui_message_webview_url_scheme
, if possible.
The same query parameters described in the client_redirect_url
section are appended to the scheme.
Example redirect
appscheme://oauth_complete?status=success&member_guid={MBR-XXX}
This setting is meant for hybrid webapps that:
is_mobile_webview: true
;It influences what MX does at the end of OAuth. The default BROWSER
tells the widget to send a postMessage to window.opener
. If APP
is set instead, the widget will redirect the user to either the client_redirect_url
or the ui_message_webview_url_scheme
.
PostMessage with default value of
BROWSER
:
{
mx: true,
type: "oauthComplete/{success|error}",
metadata: {
member_guid: "{member_guid}"
}
}
Redirect with value of
APP
// `client_redirect_url: "https://mx.com"`
https://mx.com?status=success&member_guid={MBR-XXX}
Redirect with value of
APP
// `ui_message_webview_url_scheme`: "appscheme"
appscheme://oauth_complete?status=success&member_guid={MBR-XXX}
A postMessage is an event-based protocol that allows partners to take action in their own codebase in response to events triggered within a widget’s user interface. They are intended specifically to allow a partner’s code and a widget user interface to work in concert, not to give a full picture of events happening on MX servers. PostMessage events should not be used for keeping data in sync between platforms.
Webhooks are a more reliable way of coordinating events between partner servers and MX servers, rather than the UI-oriented postMessages.
Events from MX will have mx
, type
, and metadata
properties.
The mx
field is provided as an easy way for partners to filter out postMessage events coming from MX.
The type
field has the following schemea: mx/<entity|widget>/<event>
. For example:
mx/account/created
mx/connect/institutionSelected
mx/transaction/updated
The type
field identifies what the event represents at a high level. It is also useful for matching events for a given entity or widget, e.g, all account events will be prefixed with mx/account/*
.
The metadata
field is an object that has information related to the type
that may be important, such as the account or transaction that was updated, the institution that was selected, etc. metadata
objects will also have the user_guid
and session_guid
fields.
Example integration
1
2
3
4
5
6
7
function handleEvent(event) {
if (event.data.mx) {
// handle the mx post message using event.data.type and event.data.metadata.
}
}
window.addEventListener('message', handleEvent)
Example event
1
2
3
4
5
6
7
8
9
const mxEvent = {
mx: true,
type: 'mx/account/created',
metadata: {
user_guid: 'USR-123',
session_guid: 'ANS-123'
// relevant data for the given type
}
}
Triggers when the Connect widget loads. It is often useful to know what “step” or view the user started on. The initial_step
can be:
Value | Definition |
---|---|
search |
The default initial step. |
selectMember |
The initial step when configured with mode set to verification . |
enterCreds |
The initial step when configured with current_institution_guid or current_member_guid , and updated_credentials set to true . |
mfa |
The initial step when configured with current_member_guid and the member has encountered multi-factor authentication. |
connected |
The initial step when configured with current_member_guid and the member is in a connected state. |
loginError |
The initial step when configured with current_member_guid and the member is in an error state. |
Connect loaded
1
2
3
4
5
6
7
8
9
{
"type": "mx/connect/loaded",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"initial_step": "search"
}
}
Triggered when a user submits credentials for a given institution for the first time.
Enter credentials
1
2
3
4
5
6
7
8
9
10
11
12
{
"type": "mx/connect/enterCredentials",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"institution": {
"code": "mxbank",
"guid": "INS-123"
}
}
}
Triggered when the end user searches for an institution. This is useful in determining what users are searching for.
Institution search
1
2
3
4
5
6
7
8
9
{
"type": "mx/connect/institutionSearch",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"query": "MX Bank"
}
}
Triggered when an end user selects an institution from the institution list.
Institution selected
1
2
3
4
5
6
7
8
9
10
11
12
{
"type": "mx/connect/selectedInstitution",
"mx": true,
"metadata": {
"code": "mxbank",
"guid": "INS-123",
"name": "MX Bank",
"session_guid": "ANS-123",
"url": "www.example.com",
"user_guid": "USR-123"
}
}
Triggered when a member has successfully connected the account.
Member connected
1
2
3
4
5
6
7
8
9
{
"type": "mx/connect/memberConnected",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"member_guid": "MBR-123"
}
}
Triggered when the user selects the primary button on the connected step.
Member connected
1
2
3
4
5
6
7
8
{
"type": "mx/connect/connected/primaryAction",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123"
}
}
Triggered when a member has been deleted in the widget.
Member deleted
1
2
3
4
5
6
7
8
9
{
"type": "mx/connect/memberDeleted",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"member_guid": "MBR-123"
}
}
Triggered when a member failed to get created when credentials were entered.
Member create error
1
2
3
4
5
6
7
8
9
10
{
"type": "mx/connect/createMemberError",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"institution_guid": "INS-123",
"institution_code": "mxbank"
}
}
Triggered when a member’s connection status has changed while connecting. This is useful in determining the current connection status of the member.
Member status update
1
2
3
4
5
6
7
8
9
10
{
"type": "mx/connect/memberStatusUpdate",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"member_guid": "MBR-123",
"connection_status": 6
}
}
Triggered when the user lands on the OAuth error page. This is a general error message and could represent a problem with the OAuth provider or MX.
OAuth error
1
2
3
4
5
6
7
8
9
{
"type": "mx/connect/oauthError",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"member_guid": "MBR-123"
}
}
Triggered when the user navigates to the OAuth provider’s site. Note that the redirect does not happen in WebViews. The native app will need to use this postMessage to send the user to the URL contained in the metadata.
OAuth requested:
1
2
3
4
5
6
7
8
9
10
{
"type": "mx/connect/oauthRequested",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"url": "https://something.com",
"member_guid": "MBR-123"
}
}
Triggered when the end user changes from one “step” to another. This is useful for determining what transitions users are making. Possible step values can be:
Value | Definition |
---|---|
search |
Where the users search for institutions. |
selectMember |
Where the users can verify existing members when mode set to verification. |
enterCreds |
Where the users enter credentials for a particular institution. |
oauth |
Where the users go instead of enter credentials if the institution and client supports oauth. |
mfa |
Where the users enter in MFA responses. |
connecting |
Where the users go while the connection is being attempted. |
existingMember |
Where the users land if they are trying to add a member they have previously added. |
timeOut |
When the users have been connecting for more than 30 seconds without any updates to the member. |
connected |
Where the user lands when they have successfully connected. |
loginError |
Where the user lands when they have unsuccessfully connected due to user or system error. |
error |
Where the user lands when the member create was unsuccessful due to user or system error. |
verifyError |
Where the user lands when a verification job fails to start. |
addManualAccount |
Where the users create manual accounts. Manual accounts are not currently offered in the Platform API, so partners should not expect to see this value. |
Connect step change
1
2
3
4
5
6
7
8
9
10
{
"type": "mx/connect/stepChange",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"previous": "search",
"current": "enterCreds"
}
}
Triggered when a user submits an MFA answer.
Submit MFA
1
2
3
4
5
6
7
8
9
{
"type": "mx/connect/submitMFA",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"member_guid": "MBR-123"
}
}
Triggered when a user submits credentials while trying to update their existing credentials.
Update credentials
1
2
3
4
5
6
7
8
9
10
11
12
13
{
"type": "mx/connect/updateCredentials",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123",
"member_guid": "MBR-123",
"institution": {
"code": "mxbank",
"guid": "INS-123"
}
}
}
Triggered when the app is loaded.
Widget load event
1
2
3
4
{
"type": "mx/load",
"mx": true
}
Used to keep the widget session alive.
Widget ping event
1
2
3
4
5
6
7
8
{
"type": "mx/ping",
"mx": true,
"metadata": {
"user_guid": "USR-123",
"session_guid": "ANS-123"
}
}
An account
represents a financial account held by a financial institution, e.g., a user’s checking or savings account. An account
belongs to a member
, which represents the user’s overall relationship with a particular financial institution. A checking account may be just one part of a larger relationship that could also include a car loan and a savings account.
Field | Data type | Description |
---|---|---|
account_number |
String | The account number associated with the account . This will typically be a masked or partial account number. |
apr |
Decimal | The annual percentage rate associated with the account . |
apy |
Decimal | The annual percentage yield associated with the account . |
available_balance |
Decimal | The balance that is available for use in asset accounts like checking and savings. PENDING transactions are typically taken into account with the available balance, but this may not always be the case.available_balance will usually be a positive value for all account types, determined in the same way as the balance field. |
available_credit |
Decimal | The amount of credit available for use in liability accounts like credit cards and lines of credit. PENDING transactions are typically taken into account with available credit, but this may not always be the case.available_credit will usually be a positive value for all account types, determined in the same way as the balance field. |
balance |
Decimal | The current balance of the account. PENDING transactions are typically not taken into account with the current balance, but this may not always be the case. This is the value used for the account balance displayed in MX UIs.The balance will usually be a positive value for all account types. Asset-type accounts ( CHECKING , SAVINGS , INVESTMENT ) may have a negative balance if they are in overdraft. Debt-type accounts (CREDIT_CARD , LOAN , LINE_OF_CREDIT , MORTGAGE ) may have a negative balance if they are overpaid. |
cash_balance |
Decimal | The cash balance of the account . |
cash_surrender_value |
Decimal | The sum of money paid to the policyholder or annuity holder in the event the policy is voluntarily terminated before it matures, or the insured event occurs. |
created_at |
String | The date and time at which the account was created on the MX Platform. |
credit_limit |
Decimal | The credit limit associated with the account . |
currency_code |
String | The three-character ISO 4217 currency code. |
day_payment_is_due |
Integer | The day of the month the payment is due. For example, the 14th is passed as 14 . |
death_benefit |
Integer | The amount paid to the beneficiary of the account upon death of the account owner. |
guid |
String | The unique identifier for the account . Defined by MX. |
holdings_value |
Decimal | The sum of all long holdings within this account, not including any that are shorted and not including cash. |
id |
String | The unique partner-defined identifier for the account |
imported_at |
String | The date and time at which the account was last successfully aggregated and received data. |
institution_code |
String | A unique identifier for the institution associated with this account . Defined by MX. |
insured_name |
String | The name of the insured individual. |
interest_rate |
Decimal | The interest rate associated with the account . |
is_closed |
Boolean | This indicates whether an account has been closed. |
is_hidden |
Boolean | This indicates whether the account is hidden. Defaults to false . |
last_payment_at |
String | The date and time of the most recent payment on the account . |
last_payment |
Decimal | The amount of the most recent payment on the account . |
loan_amount |
Decimal | The amount of the loan associated with the account . |
matures_on |
String | The date on which the account matures. |
member_guid |
String | The unique identifier for the member associated with the account . Defined by MX. |
member_id |
String | The unique, partner-defined, identifier for the member associated with this account . |
member_is_managed_by_user |
Boolean | This indicates whether the associated member is managed by the user or the MX partner. Members created with the managed member feature will have this field set to false. |
metadata |
String | Additional information a partner can store on the account . |
minimum_balance |
Decimal | The minimum balance associated with the account . |
minimum_payment |
Decimal | The minimum payment required for an account. This can apply to any debt account. |
name |
String | The human-readable name for the account . |
nickname |
String | An alternate name for the account . |
original_balance |
Decimal | The original balance associated with the account . This will always be positive. |
pay_out_amount |
Decimal | The amount paid out to the insured individual or beneficiary under the conditions of the insurance policy. |
payment_due_at |
String | The date and time at which the next payment is due on the account . |
payoff_balance |
Decimal | The payoff balance for a debt account . This will normally be a positive number. |
premium_amount |
Decimal | The insurance policy’s premium amount. |
routing_number |
String | The routing number for the account . |
started_on |
String | The date on which a debt account was started. |
subtype |
String | The account’s subtype, e.g., PLAN_401_K , MONEY_MARKET , or HOME_EQUITY . |
total_account_value |
Decimal | The total value of the account. |
type |
String | The general or parent type of the account . |
updated_at |
String | The date and time at which the account was most recently updated. |
user_guid |
String | The unique identifier for the user associated with the account . Defined by MX. |
user_id |
String | The unique, partner-defined, identifier for the user associated with this account . |
Parent types | |
---|---|
ANY (not provided by data partner or invalid number provided) | |
CHECKING | |
SAVINGS | |
LOAN | |
CREDIT_CARD | |
INVESTMENT | |
LINE_OF_CREDIT | |
MORTGAGE | |
PROPERTY | |
CASH | |
INSURANCE | |
PREPAID |
Subtype | Parent type |
---|---|
MONEY_MARKET | SAVINGS |
CERTIFICATE_OF_DEPOSIT | SAVINGS |
AUTO | LOAN |
STUDENT | LOAN |
SMALL_BUSINESS | LOAN |
PERSONAL | LOAN |
PERSONAL_WITH_COLLATERAL | LOAN |
HOME_EQUITY | LOAN |
PLAN_401_K | INVESTMENT |
PLAN_403_B | INVESTMENT |
PLAN_529 | INVESTMENT |
IRA | INVESTMENT |
ROLLOVER_IRA | INVESTMENT |
ROTH_IRA | INVESTMENT |
TAXABLE | INVESTMENT |
NON_TAXABLE | INVESTMENT |
BROKERAGE | INVESTMENT |
TRUST | INVESTMENT |
UNIFORM_GIFTS_TO_MINORS_ACT | INVESTMENT |
PLAN_457 | INVESTMENT |
PENSION | INVESTMENT |
EMPLOYEE_STOCK_OWNERSHIP_PLAN | INVESTMENT |
SIMPLIFIED_EMPLOYEE_PENSION | INVESTMENT |
SIMPLE_IRA | INVESTMENT |
BOAT | LOAN |
POWERSPORTS | LOAN |
RV | LOAN |
HELOC | LOAN |
PLAN_ROTH_401_K | INVESTMENT |
FIXED_ANNUITY | INVESTMENT |
VARIABLE_ANNUITY | INVESTMENT |
VEHICLE_INSURANCE | INSURANCE |
DISABILITY | INSURANCE |
HEALTH | INSURANCE |
LONG_TERM_CARE | INSURANCE |
PROPERTY_AND_CASUALTY | INSURANCE |
UNIVERSAL_LIFE | INSURANCE |
TERM_LIFE | INSURANCE |
WHOLE_LIFE | INSURANCE |
ACCIDENTAL_DEATH_AND_DISMEMBERMENT | INSURANCE |
VARIABLE_UNIVERSAL_LIFE | INSURANCE |
HSA | INVESTMENT |
TAX_FREE_SAVINGS_ACCOUNT | INVESTMENT |
INDIVIDUAL | INVESTMENT |
REGISTERED_RETIREMENT_INCOME_FUND | INVESTMENT |
CASH_MANAGEMENT_ACCOUNT | INVESTMENT |
EMPLOYEE_STOCK_PURCHASE_PLAN | INVESTMENT |
REGISTERED_EDUCATION_SAVINGS_PLAN | INVESTMENT |
PROFIT_SHARING_PLAN | INVESTMENT |
UNIFORM_TRANSFER_TO_MINORS_ACT | INVESTMENT |
PLAN_401_A | INVESTMENT |
SARSEP_IRA | INVESTMENT |
FIXED_ANNUITY_TRADITIONAL_IRA | INVESTMENT |
VARIABLE_ANNUITY_TRADITIONAL_IRA | INVESTMENT |
SEPP_IRA | INVESTMENT |
INHERITED_TRADITIONAL_IRA | INVESTMENT |
FIXED_ANNUITY_ROTH_IRA | INVESTMENT |
VARIABLE_ANNUITY_ROTH_IRA | INVESTMENT |
INHERITED_ROTH_IRA | INVESTMENT |
COVERDELL | INVESTMENT |
ADVISORY_ACCOUNT | INVESTMENT |
BROKERAGE_MARGIN | INVESTMENT |
CHARITABLE_GIFT_ACCOUNT | INVESTMENT |
CHURCH_ACCOUNT | INVESTMENT |
CONSERVATORSHIP | INVESTMENT |
CUSTODIAL | INVESTMENT |
DEFINED_BENEFIT_PLAN | INVESTMENT |
DEFINED_CONTRIBUTION_PLAN | INVESTMENT |
EDUCATIONAL | INVESTMENT |
ESTATE | INVESTMENT |
EXECUTOR | INVESTMENT |
GROUP_RETIREMENT_SAVINGS_PLAN | INVESTMENT |
GUARANTEED_INVESTMENT_CERTIFICATE | INVESTMENT |
HRA | INVESTMENT |
INDEXED_ANNUITY | INVESTMENT |
INVESTMENT_CLUB | INVESTMENT |
IRREVOCABLE_TRUST | INVESTMENT |
JOINT_TENANTS_BY_ENTIRITY | INVESTMENT |
JOINT_TENANTS_COMMUNITY_PROPERTY | INVESTMENT |
JOINT_TENANTS_IN_COMMON | INVESTMENT |
JOINT_TENANTS_WITH_RIGHTS_OF_SURVIVORSHIP | INVESTMENT |
KEOUGH_PLAN | INVESTMENT |
LIFE_INCOME_FUND | INVESTMENT |
LIVING_TRUST | INVESTMENT |
LOCKED_IN_RETIREMENT_ACCOUNT | INVESTMENT |
LOCKED_IN_RETIREMENT_INVESTMENT_FUND | INVESTMENT |
LOCKED_IN_RETIREMENT_SAVINGS_ACCOUNT | INVESTMENT |
MONEY_PURCHASE_PLAN | INVESTMENT |
PARTNERSHIP | INVESTMENT |
PLAN_409_A | INVESTMENT |
PLAN_ROTH_403_B | INVESTMENT |
REGISTERED_DISABILITY_SAVINGS_PLAN | INVESTMENT |
REGISTERED_LOCKED_IN_SAVINGS_PLAN | INVESTMENT |
REGISTERED_PENSION_PLAN | INVESTMENT |
REGISTERED_RETIREMENT_SAVINGS_PLAN | INVESTMENT |
REVOCABLE_TRUST | INVESTMENT |
ROTH_CONVERSION | INVESTMENT |
SOLE_PROPRIETORSHIP | INVESTMENT |
SPOUSAL_IRA | INVESTMENT |
SPOUSAL_ROTH_IRA | INVESTMENT |
TESTAMENTARY_TRUST | INVESTMENT |
THRIFT_SAVINGS_PLAN | INVESTMENT |
INHERITED_ANNUITY | INVESTMENT |
CORPORATE_ACCOUNT | INVESTMENT |
LIMITED_LIABILITY_ACCOUNT | INVESTMENT |
This endpoint returns a list of all the accounts associated with the specified user
.
Endpoint:
GET /users/{user_guid}/accounts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var page = 1;
var recordsPerPage = 10;
try
{
AccountsResponseBody result = apiInstance.ListUserAccounts(userGuid, page, recordsPerPage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.ListUserAccounts: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
page := int32(1)
recordsPerPage := int32(10)
resp, r, err := api_client.MxPlatformApi.ListUserAccounts(ctx, userGuid).Page(page).RecordsPerPage(recordsPerPage).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.ListUserAccounts``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.ListUserAccounts`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
int page = 1;
int recordsPerPage = 10;
try {
AccountsResponseBody response = apiInstance.listUserAccounts(userGuid, page, recordsPerPage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#listUserAccounts");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const userGuid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54';
const page = 1;
const recordsPerPage = 10;
const response = await client.listUserAccounts(userGuid, page, recordsPerPage);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
page = 1
records_per_page = 10
try:
api_response = api_instance.list_user_accounts(user_guid, page=page, records_per_page=records_per_page)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->list_user_accounts: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
opts = {
page: 1,
records_per_page: 10
}
begin
response = mx_platform_api.list_user_accounts(user_guid, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->list_user_accounts: #{e}"
end
1
2
3
curl -i -X GET 'https://int-api.mx.com/users/USR-fa7537f3-48aa-a683-a02a-b18940482f54/accounts?page=1&records_per_page=10' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
class AccountsResponseBody {
Accounts: List<AccountResponse>(){
class AccountResponse {
AccountNumber: 5366,
Apr: 1.0,
Apy: 1.0,
AvailableBalance: 1000.0,
AvailableCredit: 1000.0,
Balance: 1000.0,
CashBalance: 1000.0,
CashSurrenderValue: 1000.0,
CreatedAt: 2016-10-13T17:57:37.000Z,
CreditLimit: 100.0,
CurrencyCode: USD,
DayPaymentIsDue: 20,
DeathBenefit: 1000,
Guid: ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1,
HoldingsValue: 1000.0,
Id: 1040434698,
ImportedAt: 2015-10-13T17:57:37.000Z,
InstitutionCode: chase,
InsuredName: Frodo Baggins,
InterestRate: 1.0,
IsClosed: False,
IsHidden: False,
LastPayment: 100.0,
LastPaymentAt: 2015-10-13T17:57:37.000Z,
LoanAmount: 1000.0,
MaturesOn: 2015-10-13T17:57:37.000Z,
MemberGuid: MBR-7c6f361b-e582-15b6-60c0-358f12466b4b,
MemberId: member123,
MemberIsManagedByUser: False,
Metadata: some metadata,
MinimumBalance: 100.0,
MinimumPayment: 10.0,
Name: Test account 2,
Nickname: My Checking,
OriginalBalance: 10.0,
PayOutAmount: 10.0,
PaymentDueAt: 2015-10-13T17:57:37.000Z,
PayoffBalance: 10.0,
PremiumAmount: 1.0,
RoutingNumber: 68899990000000,
StartedOn: 2015-10-13T17:57:37.000Z,
Subtype: NONE,
TotalAccountValue: 1.0,
Type: SAVINGS,
UpdatedAt: 2016-10-13T18:08:00.000Z,
UserGuid: USR-fa7537f3-48aa-a683-a02a-b18940482f54,
UserId: user123
}
},
Pagination: class PaginationResponse {
CurrentPage: 1,
PerPage: 25,
TotalEntries: 1,
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
mxplatformgo.AccountsResponseBody{
Accounts: []mxplatformgo.AccountResponse{
mxplatformgo.AccountResponse{
AccountNumber: "5366"
Apr: 1.0
Apy: 1.0
AvailableBalance: 1000.0
AvailableCredit: 1000.0
Balance: 1000.0
CashBalance: 1000.0
CashSurrenderValue: 1000.0
CreatedAt: "2016-10-13T17:57:37.000Z"
CreditLimit: 100.0
CurrencyCode: "USD"
DayPaymentIsDue: 20
DeathBenefit: 1000
Guid: "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
HoldingsValue: 1000.0
Id: "1040434698"
ImportedAt: "2015-10-13T17:57:37.000Z"
InstitutionCode: "chase"
InsuredName: "Frodo Baggins"
InterestRate: 1.0
IsClosed: false
IsHidden: false
LastPayment: 100.0
LastPaymentAt: "2015-10-13T17:57:37.000Z"
LoanAmount: 1000.0
MaturesOn: "2015-10-13T17:57:37.000Z"
MemberGuid: "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
MemberId: "member123"
MemberIsManagedByUser: false
Metadata: "some metadata"
MinimumBalance: 100.0
MinimumPayment: 10.0
Name: "Test account 2"
Nickname: "My Checking"
OriginalBalance: 10.0
PayOutAmount: 10.0
PaymentDueAt: "2015-10-13T17:57:37.000Z"
PayoffBalance: 10.0
PremiumAmount: 1.0
RoutingNumber: "68899990000000"
StartedOn: "2015-10-13T17:57:37.000Z"
Subtype: "NONE"
TotalAccountValue: 1.0
Type: "SAVINGS"
UpdatedAt: "2016-10-13T18:08:00.000Z"
UserGuid: "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
UserId: "user123"
}
}
Pagination: mxplatformgo.PaginationResponse{
CurrentPage: 1
PerPage: 25
TotalEntries: 1
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
class AccountsResponseBody {
accounts: [
class AccountResponse {
accountNumber: 5366
apr: 1.0
apy: 1.0
availableBalance: 1000.0
availableCredit: 1000.0
balance: 1000.0
cashBalance: 1000.0
cashSurrenderValue: 1000.0
createdAt: 2016-10-13T17:57:37.000Z
creditLimit: 100.0
currencyCode: USD
dayPaymentIsDue: 20
deathBenefit: 1000
guid: ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1
holdingsValue: 1000.0
id: 1040434698
importedAt: 2015-10-13T17:57:37.000Z
institutionCode: chase
insuredName: Frodo Baggins
interestRate: 1.0
isClosed: false
isHidden: false
lastPayment: 100.0
lastPaymentAt: 2015-10-13T17:57:37.000Z
loanAmount: 1000.0
maturesOn: 2015-10-13T17:57:37.000Z
memberGuid: MBR-7c6f361b-e582-15b6-60c0-358f12466b4b
memberId: member123
memberIsManagedByUser: false
metadata: some metadata
minimumBalance: 100.0
minimumPayment: 10.0
name: Test account 2
nickname: My Checking
originalBalance: 10.0
payOutAmount: 10.0
paymentDueAt: 2015-10-13T17:57:37.000Z
payoffBalance: 10.0
premiumAmount: 1.0
routingNumber: 68899990000000
startedOn: 2015-10-13T17:57:37.000Z
subtype: NONE
totalAccountValue: 1.0
type: SAVINGS
updatedAt: 2016-10-13T18:08:00.000Z
userGuid: USR-fa7537f3-48aa-a683-a02a-b18940482f54
userId: user123
}
]
pagination: class PaginationResponse {
currentPage: 1
perPage: 25
totalEntries: 1
totalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
{
accounts: [
{
account_number: '5366',
apr: 1.0,
apy: 1.0,
available_balance: 1000.0,
available_credit: 1000.0,
balance: 1000.0,
cash_balance: 1000.0,
cash_surrender_value: 1000.0,
created_at: '2016-10-13T17:57:37.000Z',
credit_limit: 100.0,
currency_code: 'USD',
day_payment_is_due: 20,
death_benefit: 1000,
guid: 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
holdings_value: 1000.0,
id: '1040434698',
imported_at: '2015-10-13T17:57:37.000Z',
institution_code: 'chase',
insured_name: 'Frodo Baggins',
interest_rate: 1.0,
is_closed: false,
is_hidden: false,
last_payment: 100.0,
last_payment_at: '2015-10-13T17:57:37.000Z',
loan_amount: 1000.0,
matures_on: '2015-10-13T17:57:37.000Z',
member_guid: 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
member_id: 'member123',
member_is_managed_by_user: false,
metadata: 'some metadata',
minimum_balance: 100.0,
minimum_payment: 10.0,
name: 'Test account 2',
nickname: 'My Checking',
original_balance: 10.0,
pay_out_amount: 10.0,
payment_due_at: '2015-10-13T17:57:37.000Z',
payoff_balance: 10.0,
premium_amount: 1.0,
routing_number: '68899990000000',
started_on: '2015-10-13T17:57:37.000Z',
subtype: 'NONE',
total_account_value: 1.0,
type: 'SAVINGS',
updated_at: '2016-10-13T18:08:00.000Z',
user_guid: 'USR-fa7537f3-48aa-a683-a02a-b18940482f54',
user_id: 'user123'
}
],
pagination: {
current_page: 1,
per_page: 25,
total_entries: 1,
total_pages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
{
'accounts': [
{
'account_number': '5366',
'apr': 1.0,
'apy': 1.0,
'available_balance': 1000.0,
'available_credit': 1000.0,
'balance': 1000.0,
'cash_balance': 1000.0,
'cash_surrender_value': 1000.0,
'created_at': '2016-10-13T17:57:37.000Z',
'credit_limit': 100.0,
'currency_code': 'USD',
'day_payment_is_due': 20,
'death_benefit': 1000,
'guid': 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
'holdings_value': 1000.0,
'id': '1040434698',
'imported_at': '2015-10-13T17:57:37.000Z',
'institution_code': 'chase',
'insured_name': 'Frodo Baggins',
'interest_rate': 1.0,
'is_closed': False,
'is_hidden': False,
'last_payment': 100.0,
'last_payment_at': '2015-10-13T17:57:37.000Z',
'loan_amount': 1000.0,
'matures_on': '2015-10-13T17:57:37.000Z',
'member_guid': 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
'member_id': 'member123',
'member_is_managed_by_user': False,
'metadata': 'some metadata',
'minimum_balance': 100.0,
'minimum_payment': 10.0,
'name': 'Test account 2',
'nickname': 'My Checking',
'original_balance': 10.0,
'pay_out_amount': 10.0,
'payment_due_at': '2015-10-13T17:57:37.000Z',
'payoff_balance': 10.0,
'premium_amount': 1.0,
'routing_number': '68899990000000',
'started_on': '2015-10-13T17:57:37.000Z',
'subtype': 'NONE',
'total_account_value': 1.0,
'type': 'SAVINGS',
'updated_at': '2016-10-13T18:08:00.000Z',
'user_guid': 'USR-fa7537f3-48aa-a683-a02a-b18940482f54',
'user_id': 'user123'
}
],
'pagination': {
'current_page': 1,
'per_page': 25,
'total_entries': 1,
'total_pages': 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
#<::MxPlatformRuby::AccountsResponseBody
@accounts=[
#<::MxPlatformRuby::AccountResponse
@account_number='5366',
@apr=1.0,
@apy=1.0,
@available_balance=1000.0,
@available_credit=1000.0,
@balance=1000.0,
@cash_balance=1000.0,
@cash_surrender_value=1000.0,
@created_at='2016-10-13T17:57:37.000Z',
@credit_limit=100.0,
@currency_code='USD',
@day_payment_is_due=20,
@death_benefit=1000,
@guid='ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
@holdings_value=1000.0,
@id='1040434698',
@imported_at='2015-10-13T17:57:37.000Z',
@institution_code='chase',
@insured_name='Frodo Baggins',
@interest_rate=1.0,
@is_closed=false,
@is_hidden=false,
@last_payment=100.0,
@last_payment_at='2015-10-13T17:57:37.000Z',
@loan_amount=1000.0,
@matures_on='2015-10-13T17:57:37.000Z',
@member_guid='MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
@member_id='member123',
@member_is_managed_by_user=false,
@metadata='some metadata',
@minimum_balance=100.0,
@minimum_payment=10.0,
@name='Test account 2',
@nickname='My Checking',
@original_balance=10.0,
@pay_out_amount=10.0,
@payment_due_at='2015-10-13T17:57:37.000Z',
@payoff_balance=10.0,
@premium_amount=1.0,
@routing_number='68899990000000',
@started_on='2015-10-13T17:57:37.000Z',
@subtype='NONE',
@total_account_value=1.0,
@type='SAVINGS',
@updated_at='2016-10-13T18:08:00.000Z',
@user_guid='USR-fa7537f3-48aa-a683-a02a-b18940482f54',
@user_id='user123'
>
],
@pagination=#<::MxPlatformRuby::PaginationResponse
@current_page=1,
@per_page=25,
@total_entries=1,
@total_pages=1
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
{
"accounts": [
{
"account_number": "5366",
"apr": 1.0,
"apy": 1.0,
"available_balance": 1000.0,
"available_credit": 1000.0,
"balance": 1000.0,
"cash_balance": 1000.0,
"cash_surrender_value": 1000.0,
"created_at": "2016-10-13T17:57:37.000Z",
"credit_limit": 100.0,
"currency_code": "USD",
"day_payment_is_due": 20,
"death_benefit": 1000,
"guid": "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1",
"holdings_value": 1000.0,
"id": "1040434698",
"imported_at": "2015-10-13T17:57:37.000Z",
"institution_code": "chase",
"insured_name": "Frodo Baggins",
"interest_rate": 1.0,
"is_closed": false,
"is_hidden": false,
"last_payment": 100.0,
"last_payment_at": "2015-10-13T17:57:37.000Z",
"loan_amount": 1000.0,
"matures_on": "2015-10-13T17:57:37.000Z",
"member_guid": "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b",
"member_id": "member123",
"member_is_managed_by_user": false,
"metadata": "some metadata",
"minimum_balance": 100.0,
"minimum_payment": 10.0,
"name": "Test account 2",
"nickname": "My Checking",
"original_balance": 10.0,
"pay_out_amount": 10.0,
"payment_due_at": "2015-10-13T17:57:37.000Z",
"payoff_balance": 10.0,
"premium_amount": 1.0,
"routing_number": "68899990000000",
"started_on": "2015-10-13T17:57:37.000Z",
"subtype": "NONE",
"total_account_value": 1.0,
"type": "SAVINGS",
"updated_at": "2016-10-13T18:08:00.000Z",
"user_guid": "USR-fa7537f3-48aa-a683-a02a-b18940482f54",
"user_id": "user123"
}
],
"pagination": {
"current_page": 1,
"per_page": 25,
"total_entries": 1,
"total_pages": 1
}
}
This endpoint returns the specified account
resource.
Endpoint:
GET /users/{user_guid}/accounts/{account_guid}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var accountGuid = "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1";
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
try
{
AccountResponseBody result = apiInstance.ReadAccount(accountGuid, userGuid);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.ReadAccount: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
accountGuid := "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
resp, r, err := api_client.MxPlatformApi.ReadAccount(ctx, accountGuid, userGuid).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.ReadAccount``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.ReadAccount`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String accountGuid = "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1";
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
try {
AccountResponseBody response = apiInstance.readAccount(accountGuid, userGuid);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#readAccount");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const accountGuid = 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1';
const userGuid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54';
const response = await client.readAccount(accountGuid, userGuid);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
account_guid = 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1'
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
try:
api_response = api_instance.read_account(account_guid, user_guid)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->read_account: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
account_guid = 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1'
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
begin
response = mx_platform_api.read_account(account_guid, user_guid)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->read_account: #{e}"
end
1
2
3
curl -i -X GET 'https://int-api.mx.com/users/USR-fa7537f3-48aa-a683-a02a-b18940482f54/accounts/ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
class AccountResponseBody {
Account: class AccountResponse {
AccountNumber: 5366,
Apr: 1.0,
Apy: 1.0,
AvailableBalance: 1000.0,
AvailableCredit: 1000.0,
Balance: 1000.0,
CashBalance: 1000.0,
CashSurrenderValue: 1000.0,
CreatedAt: 2016-10-13T17:57:37.000Z,
CreditLimit: 100.0,
CurrencyCode: USD,
DayPaymentIsDue: 20,
DeathBenefit: 1000,
Guid: ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1,
HoldingsValue: 1000.0,
Id: 1040434698,
ImportedAt: 2015-10-13T17:57:37.000Z,
InstitutionCode: chase,
InsuredName: Frodo Baggins,
InterestRate: 1.0,
IsClosed: False,
IsHidden: False,
LastPayment: 100.0,
LastPaymentAt: 2015-10-13T17:57:37.000Z,
LoanAmount: 1000.0,
MaturesOn: 2015-10-13T17:57:37.000Z,
MemberGuid: MBR-7c6f361b-e582-15b6-60c0-358f12466b4b,
MemberId: member123,
MemberIsManagedByUser: False,
Metadata: some metadata,
MinimumBalance: 100.0,
MinimumPayment: 10.0,
Name: Test account 2,
Nickname: My Checking,
OriginalBalance: 10.0,
PayOutAmount: 10.0,
PaymentDueAt: 2015-10-13T17:57:37.000Z,
PayoffBalance: 10.0,
PremiumAmount: 1.0,
RoutingNumber: 68899990000000,
StartedOn: 2015-10-13T17:57:37.000Z,
Subtype: NONE,
TotalAccountValue: 1.0,
Type: SAVINGS,
UpdatedAt: 2016-10-13T18:08:00.000Z,
UserGuid: USR-fa7537f3-48aa-a683-a02a-b18940482f54,
UserId: user123
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
mxplatformgo.AccountResponseBody{
Account: mxplatformgo.AccountResponse{
AccountNumber: "5366"
Apr: 1.0
Apy: 1.0
AvailableBalance: 1000.0
AvailableCredit: 1000.0
Balance: 1000.0
CashBalance: 1000.0
CashSurrenderValue: 1000.0
CreatedAt: "2016-10-13T17:57:37.000Z"
CreditLimit: 100.0
CurrencyCode: "USD"
DayPaymentIsDue: 20
DeathBenefit: 1000
Guid: "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
HoldingsValue: 1000.0
Id: "1040434698"
ImportedAt: "2015-10-13T17:57:37.000Z"
InstitutionCode: "chase"
InsuredName: "Frodo Baggins"
InterestRate: 1.0
IsClosed: false
IsHidden: false
LastPayment: 100.0
LastPaymentAt: "2015-10-13T17:57:37.000Z"
LoanAmount: 1000.0
MaturesOn: "2015-10-13T17:57:37.000Z"
MemberGuid: "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
MemberId: "member123"
MemberIsManagedByUser: false
Metadata: "some metadata"
MinimumBalance: 100.0
MinimumPayment: 10.0
Name: "Test account 2"
Nickname: "My Checking"
OriginalBalance: 10.0
PayOutAmount: 10.0
PaymentDueAt: "2015-10-13T17:57:37.000Z"
PayoffBalance: 10.0
PremiumAmount: 1.0
RoutingNumber: "68899990000000"
StartedOn: "2015-10-13T17:57:37.000Z"
Subtype: "NONE"
TotalAccountValue: 1.0
Type: "SAVINGS"
UpdatedAt: "2016-10-13T18:08:00.000Z"
UserGuid: "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
UserId: "user123"
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
class AccountResponseBody {
account: class AccountResponse {
accountNumber: 5366
apr: 1.0
apy: 1.0
availableBalance: 1000.0
availableCredit: 1000.0
balance: 1000.0
cashBalance: 1000.0
cashSurrenderValue: 1000.0
createdAt: 2016-10-13T17:57:37.000Z
creditLimit: 100.0
currencyCode: USD
dayPaymentIsDue: 20
deathBenefit: 1000
guid: ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1
holdingsValue: 1000.0
id: 1040434698
importedAt: 2015-10-13T17:57:37.000Z
institutionCode: chase
insuredName: Frodo Baggins
interestRate: 1.0
isClosed: false
isHidden: false
lastPayment: 100.0
lastPaymentAt: 2015-10-13T17:57:37.000Z
loanAmount: 1000.0
maturesOn: 2015-10-13T17:57:37.000Z
memberGuid: MBR-7c6f361b-e582-15b6-60c0-358f12466b4b
memberId: member123
memberIsManagedByUser: false
metadata: some metadata
minimumBalance: 100.0
minimumPayment: 10.0
name: Test account 2
nickname: My Checking
originalBalance: 10.0
payOutAmount: 10.0
paymentDueAt: 2015-10-13T17:57:37.000Z
payoffBalance: 10.0
premiumAmount: 1.0
routingNumber: 68899990000000
startedOn: 2015-10-13T17:57:37.000Z
subtype: NONE
totalAccountValue: 1.0
type: SAVINGS
updatedAt: 2016-10-13T18:08:00.000Z
userGuid: USR-fa7537f3-48aa-a683-a02a-b18940482f54
userId: user123
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{
account: {
account_number: '5366',
apr: 1.0,
apy: 1.0,
available_balance: 1000.0,
available_credit: 1000.0,
balance: 1000.0,
cash_balance: 1000.0,
cash_surrender_value: 1000.0,
created_at: '2016-10-13T17:57:37.000Z',
credit_limit: 100.0,
currency_code: 'USD',
day_payment_is_due: 20,
death_benefit: 1000,
guid: 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
holdings_value: 1000.0,
id: '1040434698',
imported_at: '2015-10-13T17:57:37.000Z',
institution_code: 'chase',
insured_name: 'Frodo Baggins',
interest_rate: 1.0,
is_closed: false,
is_hidden: false,
last_payment: 100.0,
last_payment_at: '2015-10-13T17:57:37.000Z',
loan_amount: 1000.0,
matures_on: '2015-10-13T17:57:37.000Z',
member_guid: 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
member_id: 'member123',
member_is_managed_by_user: false,
metadata: 'some metadata',
minimum_balance: 100.0,
minimum_payment: 10.0,
name: 'Test account 2',
nickname: 'My Checking',
original_balance: 10.0,
pay_out_amount: 10.0,
payment_due_at: '2015-10-13T17:57:37.000Z',
payoff_balance: 10.0,
premium_amount: 1.0,
routing_number: '68899990000000',
started_on: '2015-10-13T17:57:37.000Z',
subtype: 'NONE',
total_account_value: 1.0,
type: 'SAVINGS',
updated_at: '2016-10-13T18:08:00.000Z',
user_guid: 'USR-fa7537f3-48aa-a683-a02a-b18940482f54',
user_id: 'user123'
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{
'account': {
'account_number': '5366',
'apr': 1.0,
'apy': 1.0,
'available_balance': 1000.0,
'available_credit': 1000.0,
'balance': 1000.0,
'cash_balance': 1000.0,
'cash_surrender_value': 1000.0,
'created_at': '2016-10-13T17:57:37.000Z',
'credit_limit': 100.0,
'currency_code': 'USD',
'day_payment_is_due': 20,
'death_benefit': 1000,
'guid': 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
'holdings_value': 1000.0,
'id': '1040434698',
'imported_at': '2015-10-13T17:57:37.000Z',
'institution_code': 'chase',
'insured_name': 'Frodo Baggins',
'interest_rate': 1.0,
'is_closed': False,
'is_hidden': False,
'last_payment': 100.0,
'last_payment_at': '2015-10-13T17:57:37.000Z',
'loan_amount': 1000.0,
'matures_on': '2015-10-13T17:57:37.000Z',
'member_guid': 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
'member_id': 'member123',
'member_is_managed_by_user': False,
'metadata': 'some metadata',
'minimum_balance': 100.0,
'minimum_payment': 10.0,
'name': 'Test account 2',
'nickname': 'My Checking',
'original_balance': 10.0,
'pay_out_amount': 10.0,
'payment_due_at': '2015-10-13T17:57:37.000Z',
'payoff_balance': 10.0,
'premium_amount': 1.0,
'routing_number': '68899990000000',
'started_on': '2015-10-13T17:57:37.000Z',
'subtype': 'NONE',
'total_account_value': 1.0,
'type': 'SAVINGS',
'updated_at': '2016-10-13T18:08:00.000Z',
'user_guid': 'USR-fa7537f3-48aa-a683-a02a-b18940482f54',
'user_id': 'user123'
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#<::MxPlatformRuby::AccountResponseBody
@account=#<::MxPlatformRuby::AccountResponse
@account_number='5366',
@apr=1.0,
@apy=1.0,
@available_balance=1000.0,
@available_credit=1000.0,
@balance=1000.0,
@cash_balance=1000.0,
@cash_surrender_value=1000.0,
@created_at='2016-10-13T17:57:37.000Z',
@credit_limit=100.0,
@currency_code='USD',
@day_payment_is_due=20,
@death_benefit=1000,
@guid='ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
@holdings_value=1000.0,
@id='1040434698',
@imported_at='2015-10-13T17:57:37.000Z',
@institution_code='chase',
@insured_name='Frodo Baggins',
@interest_rate=1.0,
@is_closed=false,
@is_hidden=false,
@last_payment=100.0,
@last_payment_at='2015-10-13T17:57:37.000Z',
@loan_amount=1000.0,
@matures_on='2015-10-13T17:57:37.000Z',
@member_guid='MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
@member_id='member123',
@member_is_managed_by_user=false,
@metadata='some metadata',
@minimum_balance=100.0,
@minimum_payment=10.0,
@name='Test account 2',
@nickname='My Checking',
@original_balance=10.0,
@pay_out_amount=10.0,
@payment_due_at='2015-10-13T17:57:37.000Z',
@payoff_balance=10.0,
@premium_amount=1.0,
@routing_number='68899990000000',
@started_on='2015-10-13T17:57:37.000Z',
@subtype='NONE',
@total_account_value=1.0,
@type='SAVINGS',
@updated_at='2016-10-13T18:08:00.000Z',
@user_guid='USR-fa7537f3-48aa-a683-a02a-b18940482f54',
@user_id='user123'
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{
"account": {
"account_number": "5366",
"apr": 1.0,
"apy": 1.0,
"available_balance": 1000.0,
"available_credit": 1000.0,
"balance": 1000.0,
"cash_balance": 1000.0,
"cash_surrender_value": 1000.0,
"created_at": "2016-10-13T17:57:37.000Z",
"credit_limit": 100.0,
"currency_code": "USD",
"day_payment_is_due": 20,
"death_benefit": 1000,
"guid": "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1",
"holdings_value": 1000.0,
"id": "1040434698",
"imported_at": "2015-10-13T17:57:37.000Z",
"institution_code": "chase",
"insured_name": "Frodo Baggins",
"interest_rate": 1.0,
"is_closed": false,
"is_hidden": false,
"last_payment": 100.0,
"last_payment_at": "2015-10-13T17:57:37.000Z",
"loan_amount": 1000.0,
"matures_on": "2015-10-13T17:57:37.000Z",
"member_guid": "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b",
"member_id": "member123",
"member_is_managed_by_user": false,
"metadata": "some metadata",
"minimum_balance": 100.0,
"minimum_payment": 10.0,
"name": "Test account 2",
"nickname": "My Checking",
"original_balance": 10.0,
"pay_out_amount": 10.0,
"payment_due_at": "2015-10-13T17:57:37.000Z",
"payoff_balance": 10.0,
"premium_amount": 1.0,
"routing_number": "68899990000000",
"started_on": "2015-10-13T17:57:37.000Z",
"subtype": "NONE",
"total_account_value": 1.0,
"type": "SAVINGS",
"updated_at": "2016-10-13T18:08:00.000Z",
"user_guid": "USR-fa7537f3-48aa-a683-a02a-b18940482f54",
"user_id": "user123"
}
}
This endpoint allows you to update certain attributes of an account
resource.
Parameters
Field name | Data type | Required? |
---|---|---|
is_hidden |
Boolean | No |
Endpoint:
PUT /users/{user_guid}/members/{member_guid}/accounts/{account_guid}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var accountGuid = "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1";
var memberGuid = "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b";
var userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
var requestBody = new AccountUpdateRequestBody(
account: new AccountUpdateRequest(
isHidden: false
)
);
try
{
AccountResponseBody result = apiInstance.UpdateAccountByMember(accountGuid, memberGuid, userGuid, requestBody);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.UpdateAccountByMember: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
accountGuid := "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
memberGuid := "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
userGuid := "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
accountUpdateRequestBody := *mxplatformgo.NewAccountUpdateRequestBodyWithDefaults()
accountUpdateRequest := *mxplatformgo.NewAccountUpdateRequestWithDefaults()
accountUpdateRequest.SetIsHidden(false)
accountUpdateRequestBody.SetAccount(accountUpdateRequest)
resp, r, err := api_client.MxPlatformApi.UpdateAccountByMember(ctx, accountGuid, memberGuid, userGuid).AccountUpdateRequestBody(accountUpdateRequestBody).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.UpdateAccountByMember``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.UpdateAccountByMember`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String accountGuid = "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1";
String memberGuid = "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b";
String userGuid = "USR-fa7537f3-48aa-a683-a02a-b18940482f54";
AccountUpdateRequestBody accountUpdateRequestBody = new AccountUpdateRequestBody();
AccountUpdateRequest accountUpdateRequest = new AccountUpdateRequest();
accountUpdateRequest.setIsHidden(false);
accountUpdateRequestBody.setAccount(accountUpdateRequest);
try {
AccountResponseBody response = apiInstance.updateAccountByMember(accountGuid, memberGuid, userGuid, accountUpdateRequestBody);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#updateAccountByMember");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const accountGuid = 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1';
const memberGuid = 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b';
const userGuid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54';
const requestBody = {
account: {
is_hidden: false
}
};
const response = await client.updateAccountByMember(accountGuid, memberGuid, userGuid, requestBody);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
account_guid = 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1'
member_guid = 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b'
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = AccountUpdateRequestBody(
account = AccountUpdateRequest(
is_hidden = False
)
)
try:
api_response = api_instance.update_account_by_member(account_guid, member_guid, user_guid, request_body)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->update_account_by_member: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
account_guid = 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1'
member_guid = 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b'
user_guid = 'USR-fa7537f3-48aa-a683-a02a-b18940482f54'
request_body = ::MxPlatformRuby::AccountUpdateRequestBody.new(
account: ::MxPlatformRuby::AccountUpdateRequest.new(
is_hidden: false
)
)
begin
response = mx_platform_api.update_account_by_member(account_guid, member_guid, user_guid, request_body)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->update_account_by_member: #{e}"
end
1
2
3
4
5
6
7
8
9
curl -i -X PUT 'https://int-api.mx.com/users/USR-fa7537f3-48aa-a683-a02a-b18940482f54/members/MBR-7c6f361b-e582-15b6-60c0-358f12466b4b/accounts/ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-H 'Content-Type: application/json' \
-u 'client_id:api_key' \
-d '{
"account": {
"is_hidden": false
}
}'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
class AccountResponseBody {
Account: class AccountResponse {
AccountNumber: 5366,
Apr: 1.0,
Apy: 1.0,
AvailableBalance: 1000.0,
AvailableCredit: 1000.0,
Balance: 1000.0,
CashBalance: 1000.0,
CashSurrenderValue: 1000.0,
CreatedAt: 2016-10-13T17:57:37.000Z,
CreditLimit: 100.0,
CurrencyCode: USD,
DayPaymentIsDue: 20,
DeathBenefit: 1000,
Guid: ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1,
HoldingsValue: 1000.0,
Id: 1040434698,
ImportedAt: 2015-10-13T17:57:37.000Z,
InstitutionCode: chase,
InsuredName: Frodo Baggins,
InterestRate: 1.0,
IsClosed: False,
IsHidden: False,
LastPayment: 100.0,
LastPaymentAt: 2015-10-13T17:57:37.000Z,
LoanAmount: 1000.0,
MaturesOn: 2015-10-13T17:57:37.000Z,
MemberGuid: MBR-7c6f361b-e582-15b6-60c0-358f12466b4b,
MemberId: member123,
MemberIsManagedByUser: False,
Metadata: some metadata,
MinimumBalance: 100.0,
MinimumPayment: 10.0,
Name: Test account 2,
Nickname: My Checking,
OriginalBalance: 10.0,
PayOutAmount: 10.0,
PaymentDueAt: 2015-10-13T17:57:37.000Z,
PayoffBalance: 10.0,
PremiumAmount: 1.0,
RoutingNumber: 68899990000000,
StartedOn: 2015-10-13T17:57:37.000Z,
Subtype: NONE,
TotalAccountValue: 1.0,
Type: SAVINGS,
UpdatedAt: 2016-10-13T18:08:00.000Z,
UserGuid: USR-fa7537f3-48aa-a683-a02a-b18940482f54,
UserId: user123
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
mxplatformgo.AccountResponseBody{
Account: mxplatformgo.AccountResponse{
AccountNumber: "5366"
Apr: 1.0
Apy: 1.0
AvailableBalance: 1000.0
AvailableCredit: 1000.0
Balance: 1000.0
CashBalance: 1000.0
CashSurrenderValue: 1000.0
CreatedAt: "2016-10-13T17:57:37.000Z"
CreditLimit: 100.0
CurrencyCode: "USD"
DayPaymentIsDue: 20
DeathBenefit: 1000
Guid: "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1"
HoldingsValue: 1000.0
Id: "1040434698"
ImportedAt: "2015-10-13T17:57:37.000Z"
InstitutionCode: "chase"
InsuredName: "Frodo Baggins"
InterestRate: 1.0
IsClosed: false
IsHidden: false
LastPayment: 100.0
LastPaymentAt: "2015-10-13T17:57:37.000Z"
LoanAmount: 1000.0
MaturesOn: "2015-10-13T17:57:37.000Z"
MemberGuid: "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b"
MemberId: "member123"
MemberIsManagedByUser: false
Metadata: "some metadata"
MinimumBalance: 100.0
MinimumPayment: 10.0
Name: "Test account 2"
Nickname: "My Checking"
OriginalBalance: 10.0
PayOutAmount: 10.0
PaymentDueAt: "2015-10-13T17:57:37.000Z"
PayoffBalance: 10.0
PremiumAmount: 1.0
RoutingNumber: "68899990000000"
StartedOn: "2015-10-13T17:57:37.000Z"
Subtype: "NONE"
TotalAccountValue: 1.0
Type: "SAVINGS"
UpdatedAt: "2016-10-13T18:08:00.000Z"
UserGuid: "USR-fa7537f3-48aa-a683-a02a-b18940482f54"
UserId: "user123"
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
class AccountResponseBody {
account: class AccountResponse {
accountNumber: 5366
apr: 1.0
apy: 1.0
availableBalance: 1000.0
availableCredit: 1000.0
balance: 1000.0
cashBalance: 1000.0
cashSurrenderValue: 1000.0
createdAt: 2016-10-13T17:57:37.000Z
creditLimit: 100.0
currencyCode: USD
dayPaymentIsDue: 20
deathBenefit: 1000
guid: ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1
holdingsValue: 1000.0
id: 1040434698
importedAt: 2015-10-13T17:57:37.000Z
institutionCode: chase
insuredName: Frodo Baggins
interestRate: 1.0
isClosed: false
isHidden: false
lastPayment: 100.0
lastPaymentAt: 2015-10-13T17:57:37.000Z
loanAmount: 1000.0
maturesOn: 2015-10-13T17:57:37.000Z
memberGuid: MBR-7c6f361b-e582-15b6-60c0-358f12466b4b
memberId: member123
memberIsManagedByUser: false
metadata: some metadata
minimumBalance: 100.0
minimumPayment: 10.0
name: Test account 2
nickname: My Checking
originalBalance: 10.0
payOutAmount: 10.0
paymentDueAt: 2015-10-13T17:57:37.000Z
payoffBalance: 10.0
premiumAmount: 1.0
routingNumber: 68899990000000
startedOn: 2015-10-13T17:57:37.000Z
subtype: NONE
totalAccountValue: 1.0
type: SAVINGS
updatedAt: 2016-10-13T18:08:00.000Z
userGuid: USR-fa7537f3-48aa-a683-a02a-b18940482f54
userId: user123
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{
account: {
account_number: '5366',
apr: 1.0,
apy: 1.0,
available_balance: 1000.0,
available_credit: 1000.0,
balance: 1000.0,
cash_balance: 1000.0,
cash_surrender_value: 1000.0,
created_at: '2016-10-13T17:57:37.000Z',
credit_limit: 100.0,
currency_code: 'USD',
day_payment_is_due: 20,
death_benefit: 1000,
guid: 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
holdings_value: 1000.0,
id: '1040434698',
imported_at: '2015-10-13T17:57:37.000Z',
institution_code: 'chase',
insured_name: 'Frodo Baggins',
interest_rate: 1.0,
is_closed: false,
is_hidden: false,
last_payment: 100.0,
last_payment_at: '2015-10-13T17:57:37.000Z',
loan_amount: 1000.0,
matures_on: '2015-10-13T17:57:37.000Z',
member_guid: 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
member_id: 'member123',
member_is_managed_by_user: false,
metadata: 'some metadata',
minimum_balance: 100.0,
minimum_payment: 10.0,
name: 'Test account 2',
nickname: 'My Checking',
original_balance: 10.0,
pay_out_amount: 10.0,
payment_due_at: '2015-10-13T17:57:37.000Z',
payoff_balance: 10.0,
premium_amount: 1.0,
routing_number: '68899990000000',
started_on: '2015-10-13T17:57:37.000Z',
subtype: 'NONE',
total_account_value: 1.0,
type: 'SAVINGS',
updated_at: '2016-10-13T18:08:00.000Z',
user_guid: 'USR-fa7537f3-48aa-a683-a02a-b18940482f54',
user_id: 'user123'
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{
'account': {
'account_number': '5366',
'apr': 1.0,
'apy': 1.0,
'available_balance': 1000.0,
'available_credit': 1000.0,
'balance': 1000.0,
'cash_balance': 1000.0,
'cash_surrender_value': 1000.0,
'created_at': '2016-10-13T17:57:37.000Z',
'credit_limit': 100.0,
'currency_code': 'USD',
'day_payment_is_due': 20,
'death_benefit': 1000,
'guid': 'ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
'holdings_value': 1000.0,
'id': '1040434698',
'imported_at': '2015-10-13T17:57:37.000Z',
'institution_code': 'chase',
'insured_name': 'Frodo Baggins',
'interest_rate': 1.0,
'is_closed': False,
'is_hidden': False,
'last_payment': 100.0,
'last_payment_at': '2015-10-13T17:57:37.000Z',
'loan_amount': 1000.0,
'matures_on': '2015-10-13T17:57:37.000Z',
'member_guid': 'MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
'member_id': 'member123',
'member_is_managed_by_user': False,
'metadata': 'some metadata',
'minimum_balance': 100.0,
'minimum_payment': 10.0,
'name': 'Test account 2',
'nickname': 'My Checking',
'original_balance': 10.0,
'pay_out_amount': 10.0,
'payment_due_at': '2015-10-13T17:57:37.000Z',
'payoff_balance': 10.0,
'premium_amount': 1.0,
'routing_number': '68899990000000',
'started_on': '2015-10-13T17:57:37.000Z',
'subtype': 'NONE',
'total_account_value': 1.0,
'type': 'SAVINGS',
'updated_at': '2016-10-13T18:08:00.000Z',
'user_guid': 'USR-fa7537f3-48aa-a683-a02a-b18940482f54',
'user_id': 'user123'
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
#<::MxPlatformRuby::AccountResponseBody
@account=#<::MxPlatformRuby::AccountResponse
@account_number='5366',
@apr=1.0,
@apy=1.0,
@available_balance=1000.0,
@available_credit=1000.0,
@balance=1000.0,
@cash_balance=1000.0,
@cash_surrender_value=1000.0,
@created_at='2016-10-13T17:57:37.000Z',
@credit_limit=100.0,
@currency_code='USD',
@day_payment_is_due=20,
@death_benefit=1000,
@guid='ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1',
@holdings_value=1000.0,
@id='1040434698',
@imported_at='2015-10-13T17:57:37.000Z',
@institution_code='chase',
@insured_name='Frodo Baggins',
@interest_rate=1.0,
@is_closed=false,
@is_hidden=false,
@last_payment=100.0,
@last_payment_at='2015-10-13T17:57:37.000Z',
@loan_amount=1000.0,
@matures_on='2015-10-13T17:57:37.000Z',
@member_guid='MBR-7c6f361b-e582-15b6-60c0-358f12466b4b',
@member_id='member123',
@member_is_managed_by_user=false,
@metadata='some metadata',
@minimum_balance=100.0,
@minimum_payment=10.0,
@name='Test account 2',
@nickname='My Checking',
@original_balance=10.0,
@pay_out_amount=10.0,
@payment_due_at='2015-10-13T17:57:37.000Z',
@payoff_balance=10.0,
@premium_amount=1.0,
@routing_number='68899990000000',
@started_on='2015-10-13T17:57:37.000Z',
@subtype='NONE',
@total_account_value=1.0,
@type='SAVINGS',
@updated_at='2016-10-13T18:08:00.000Z',
@user_guid='USR-fa7537f3-48aa-a683-a02a-b18940482f54',
@user_id='user123'
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
{
"account": {
"account_number": "5366",
"apr": 1.0,
"apy": 1.0,
"available_balance": 1000.0,
"available_credit": 1000.0,
"balance": 1000.0,
"cash_balance": 1000.0,
"cash_surrender_value": 1000.0,
"created_at": "2016-10-13T17:57:37.000Z",
"credit_limit": 100.0,
"currency_code": "USD",
"day_payment_is_due": 20,
"death_benefit": 1000,
"guid": "ACT-06d7f44b-caae-0f6e-1384-01f52e75dcb1",
"holdings_value": 1000.0,
"id": "1040434698",
"imported_at": "2015-10-13T17:57:37.000Z",
"institution_code": "chase",
"insured_name": "Frodo Baggins",
"interest_rate": 1.0,
"is_closed": false,
"is_hidden": false,
"last_payment": 100.0,
"last_payment_at": "2015-10-13T17:57:37.000Z",
"loan_amount": 1000.0,
"matures_on": "2015-10-13T17:57:37.000Z",
"member_guid": "MBR-7c6f361b-e582-15b6-60c0-358f12466b4b",
"member_id": "member123",
"member_is_managed_by_user": false,
"metadata": "some metadata",
"minimum_balance": 100.0,
"minimum_payment": 10.0,
"name": "Test account 2",
"nickname": "My Checking",
"original_balance": 10.0,
"pay_out_amount": 10.0,
"payment_due_at": "2015-10-13T17:57:37.000Z",
"payoff_balance": 10.0,
"premium_amount": 1.0,
"routing_number": "68899990000000",
"started_on": "2015-10-13T17:57:37.000Z",
"subtype": "NONE",
"total_account_value": 1.0,
"type": "SAVINGS",
"updated_at": "2016-10-13T18:08:00.000Z",
"user_guid": "USR-fa7537f3-48aa-a683-a02a-b18940482f54",
"user_id": "user123"
}
}
An institution
represents a financial institution like Chase, Wells Fargo, or Mountain America Credit Union.
It’s important to point out that many real-world financial institutions will actually have several different institution
objects within the MX Platform API. This is because, for example, the banking and mortgage divisions of Wells Fargo may use separate online systems for accessing customer data, both of which may be different from the credit card division’s system, etc.
In the integration environment, only some of the top financial institutions will be included in institution endpoints, and there is only one institution that supports OAuth: mx_bank_oauth
.
In the production environment, all institutions will be included in these endpoints. However, if you have not yet been registered with institutions that support OAuth, these will be excluded until registration is approved.
Field | Data type | Description |
---|---|---|
code |
String | A unique identifier for each institution , defined by MX. |
instructional_text |
string | Text intended to help end users provide the correct credentials when creating a new member. May contain <a></a> tags to link to explanatory material. Partners should render this text when end users are asked for their credentials. |
medium_logo_url |
String | The URL for a 100px X 100px logo for each institution . A generic logo is returned for institutions that don’t have one. |
name |
String | An easy-to-read name for an institution , e.g., “Chase Bank” or “Wells Fargo Bank.” |
small_logo_url |
String | The URL for a 50px X 50px logo for each institution . A generic logo is returned for institutions that don’t have one. |
supports_account_identification |
Boolean | This indicates whether the institution supports account identification. |
supports_account_statement |
Boolean | This indicates whether the institution provides access to account statements. |
supports_account_verification |
Boolean | This indicates whether the institution supports account verification. |
supports_oauth |
Boolean | This indicates whether the institution supports OAuth authentication. |
supports_transaction_history |
Boolean | This indicates whether the institution allows access to up to 24 months of transaction data. |
url |
String | The URL for particular institution’s website , e.g., www.chase.com . |
This endpoint returns a paginated list containing institutions that have been set as the partner’s favorites, sorted by popularity.
Please contact MX to set a list of favorites.
Endpoint:
GET /institutions/favorites
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var page = 1;
var recordsPerPage = 10;
try
{
InstitutionsResponseBody result = apiInstance.ListFavoriteInstitutions(page, recordsPerPage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.ListFavoriteInstitutions: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
page := int32(1)
recordsPerPage := int32(10)
resp, r, err := api_client.MxPlatformApi.ListFavoriteInstitutions(ctx).Page(page).RecordsPerPage(recordsPerPage).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.ListFavoriteInstitutions``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.ListFavoriteInstitutions`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
int page = 1;
int recordsPerPage = 10;
try {
InstitutionsResponseBody response = apiInstance.listFavoriteInstitutions(page, recordsPerPage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#listFavoriteInstitutions");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const page = 1;
const recordsPerPage = 10;
const response = await client.listFavoriteInstitutions(page, recordsPerPage);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
page = 1
records_per_page = 10
try:
api_response = api_instance.list_favorite_institutions(page=page, records_per_page=records_per_page)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->list_favorite_institutions: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
opts = {
page: 1,
records_per_page: 10
}
begin
response = mx_platform_api.list_favorite_institutions(opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->list_favorite_institutions: #{e}"
end
1
2
3
curl -i -X GET 'https://int-api.mx.com/institutions/favorites?page=1&records_per_page=10' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
class InstitutionsResponseBody {
Institutions: List<InstitutionResponse>(){
class InstitutionResponse {
Code: chase,
InstructionalText: Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.,
MediumLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png,
Name: Chase Bank,
SmallLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png,
SupportsAccountIdentification: True,
SupportsAccountStatement: True,
SupportsAccountVerification: True,
SupportsOauth: True,
SupportsTransactionHistory: True,
Url: https://www.chase.com
}
},
Pagination: class PaginationResponse {
CurrentPage: 1,
PerPage: 25,
TotalEntries: 1,
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
mxplatformgo.InstitutionsResponseBody{
Institutions: []mxplatformgo.InstitutionResponse{
mxplatformgo.InstitutionResponse{
Code: "chase"
InstructionalText: "Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>."
MediumLogoUrl: "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png"
Name: "Chase Bank"
SmallLogoUrl: "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png"
SupportsAccountIdentification: true
SupportsAccountStatement: true
SupportsAccountVerification: true
SupportsOauth: true
SupportsTransactionHistory: true
Url: "https://www.chase.com"
}
}
Pagination: mxplatformgo.PaginationResponse{
CurrentPage: 1
PerPage: 25
TotalEntries: 1
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
class InstitutionsResponseBody {
institutions: [
class InstitutionResponse {
code: chase
instructionalText: Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.
mediumLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png
name: Chase Bank
smallLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png
supportsAccountIdentification: true
supportsAccountStatement: true
supportsAccountVerification: true
supportsOauth: true
supportsTransactionHistory: true
url: https://www.chase.com
}
]
pagination: class PaginationResponse {
currentPage: 1
perPage: 25
totalEntries: 1
totalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
institutions: [
{
code: 'chase',
instructional_text: 'Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
medium_logo_url: 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
name: 'Chase Bank',
small_logo_url: 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
supports_account_identification: true,
supports_account_statement: true,
supports_account_verification: true,
supports_oauth: true,
supports_transaction_history: true,
url: 'https://www.chase.com'
}
],
pagination: {
current_page: 1,
per_page: 25,
total_entries: 1,
total_pages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
'institutions': [
{
'code': 'chase',
'instructional_text': 'Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
'medium_logo_url': 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
'name': 'Chase Bank',
'small_logo_url': 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
'supports_account_identification': True,
'supports_account_statement': True,
'supports_account_verification': True,
'supports_oauth': True,
'supports_transaction_history': True,
'url': 'https://www.chase.com'
}
],
'pagination': {
'current_page': 1,
'per_page': 25,
'total_entries': 1,
'total_pages': 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#<::MxPlatformRuby::InstitutionsResponseBody
@institutions=[
#<::MxPlatformRuby::InstitutionResponse
@code='chase',
@instructional_text='Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
@medium_logo_url='https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
@name='Chase Bank',
@small_logo_url='https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
@supports_account_identification=true,
@supports_account_statement=true,
@supports_account_verification=true,
@supports_oauth=true,
@supports_transaction_history=true,
@url='https://www.chase.com'
>
],
@pagination=#<::MxPlatformRuby::PaginationResponse
@current_page=1,
@per_page=25,
@total_entries=1,
@total_pages=1
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
"institutions": [
{
"code": "chase",
"instructional_text": "Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.",
"medium_logo_url": "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png",
"name": "Chase Bank",
"small_logo_url": "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png",
"supports_account_identification": true,
"supports_account_statement": true,
"supports_account_verification": true,
"supports_oauth": true,
"supports_transaction_history": true,
"url": "https://www.chase.com"
}
],
"pagination": {
"current_page": 1,
"per_page": 25,
"total_entries": 1,
"total_pages": 1
}
}
This endpoint returns an array which contains information on every non-MFA credential
associated with a specific institution
.
Credential fields
Field | Data type | Description |
---|---|---|
display_order |
Integer | The order in which the credential should be displayed to the end user; lower numbers should be displayed first. |
field_name |
String | The name of the credential field for the institution, e.g., “LOGIN”. |
field_type (deprecated) |
String | The type of field for this credential, e.g., TEXT , OPTIONS , TOKEN . This field is deprecated. Use type instead. |
guid |
String | A unique identifier for the credential . Defined by MX. |
label |
String | A label for the credential , intended to be readable by the end user, e.g., Username . |
type |
String | The type of field for this credential, e.g., TEXT , OPTIONS , TOKEN . |
Credential field types
Type integer | Type string |
---|---|
0 | TEXT |
1 | PASSWORD |
2 | OPTIONS |
3 | LOGIN |
12 | TOKEN |
13 | IMAGE_DATA |
14 | IMAGE_OPTIONS |
Endpoint:
GET /institutions/{institution_code}/credentials
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var institutionCode = "chase";
var page = 1;
var recordsPerPage = 10;
try
{
CredentialsResponseBody result = apiInstance.ListInstitutionCredentials(institutionCode, page, recordsPerPage);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.ListInstitutionCredentials: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
institutionCode := "chase"
page := int32(1)
recordsPerPage := int32(10)
resp, r, err := api_client.MxPlatformApi.ListInstitutionCredentials(ctx, institutionCode).Page(page).RecordsPerPage(recordsPerPage).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.ListInstitutionCredentials``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.ListInstitutionCredentials`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String institutionCode = "chase";
int page = 1;
int recordsPerPage = 10;
try {
CredentialsResponseBody response = apiInstance.listInstitutionCredentials(institutionCode, page, recordsPerPage);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#listInstitutionCredentials");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const institutionCode = 'chase';
const page = 1;
const recordsPerPage = 10;
const response = await client.listInstitutionCredentials(institutionCode, page, recordsPerPage);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
institution_code = 'chase'
page = 1
records_per_page = 10
try:
api_response = api_instance.list_institution_credentials(institution_code, page=page, records_per_page=records_per_page)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->list_institution_credentials: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
institution_code = 'chase'
opts = {
page: 1,
records_per_page: 10
}
begin
response = mx_platform_api.list_institution_credentials(institution_code, opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->list_institution_credentials: #{e}"
end
1
2
3
curl -i -X GET 'https://int-api.mx.com/institutions/chase/credentials?page=1&records_per_page=10' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
class CredentialsResponseBody {
Credentials: List<CredentialResponse>(){
class CredentialResponse {
DisplayOrder: 1,
FieldName: LOGIN,
FieldType: TEXT,
Guid: CRD-1ec152cd-e628-e81a-e852-d1e7104624da,
Label: Username,
Type: TEXT
}
},
Pagination: class PaginationResponse {
CurrentPage: 1,
PerPage: 25,
TotalEntries: 1,
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
mxplatformgo.CredentialsResponseBody{
Credentials: []mxplatformgo.CredentialResponse{
mxplatformgo.CredentialResponse{
DisplayOrder: 1
FieldName: "LOGIN"
FieldType: "TEXT"
Guid: "CRD-1ec152cd-e628-e81a-e852-d1e7104624da"
Label: "Username"
Type: "TEXT"
}
}
Pagination: mxplatformgo.PaginationResponse{
CurrentPage: 1
PerPage: 25
TotalEntries: 1
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
class CredentialsResponseBody {
credentials: [
class CredentialResponse {
displayOrder: 1
fieldName: LOGIN
fieldType: TEXT
guid: CRD-1ec152cd-e628-e81a-e852-d1e7104624da
label: Username
type: TEXT
}
]
pagination: class PaginationResponse {
currentPage: 1
perPage: 25
totalEntries: 1
totalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{
credentials: [
{
display_order: 1,
field_name: 'LOGIN',
field_type: 'TEXT',
guid: 'CRD-1ec152cd-e628-e81a-e852-d1e7104624da',
label: 'Username',
type: 'TEXT'
}
],
pagination: {
current_page: 1,
per_page: 25,
total_entries: 1,
total_pages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{
'credentials': [
{
'display_order': 1,
'field_name': 'LOGIN',
'field_type': 'TEXT',
'guid': 'CRD-1ec152cd-e628-e81a-e852-d1e7104624da',
'label': 'Username',
'type': 'TEXT'
}
],
'pagination': {
'current_page': 1,
'per_page': 25,
'total_entries': 1,
'total_pages': 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
#<::MxPlatformRuby::CredentialsResponseBody
@credentials=[
#<::MxPlatformRuby::CredentialResponse
@display_order=1,
@field_name='LOGIN',
@field_type='TEXT',
@guid='CRD-1ec152cd-e628-e81a-e852-d1e7104624da',
@label='Username',
@type='TEXT'
>
],
@pagination=#<::MxPlatformRuby::PaginationResponse
@current_page=1,
@per_page=25,
@total_entries=1,
@total_pages=1
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
{
"credentials": [
{
"display_order": 1,
"field_name": "LOGIN",
"field_type": "TEXT",
"guid": "CRD-1ec152cd-e628-e81a-e852-d1e7104624da",
"label": "Username",
"type": "TEXT"
}
],
"pagination": {
"current_page": 1,
"per_page": 25,
"total_entries": 1,
"total_pages": 1
}
}
This endpoint returns a list of institutions based on the specified search term or parameter.
Query parameters
Parameter | Results |
---|---|
name={string} |
Only institutions whose name contains the appended string will be returned. |
supports_account_identification=true |
Only institutions which support identity will be returned. |
supports_account_statement=true |
Only institutions which offer access to account statements will be returned. |
supports_account_verification=true |
Only institutions which support account verification will be returned. |
supports_transaction_history=true |
Only institutions which offer an extended transaction history will be returned. |
Endpoint:
GET /institutions
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var name = "chase";
var page = 1;
var recordsPerPage = 10;
var supportsAccountIdentification = true;
var supportsAccountStatement = true;
var supportsAccountVerification = true;
var supportsTransactionHistory = true;
try
{
InstitutionsResponseBody result = apiInstance.ListInstitutions(name, page, recordsPerPage, supportsAccountIdentification, supportsAccountStatement, supportsAccountVerification, supportsTransactionHistory);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.ListInstitutions: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
name := "chase"
page := int32(1)
recordsPerPage := int32(10)
supportsAccountIdentification := true
supportsAccountStatement := true
supportsAccountVerification := true
supportsTransactionHistory := true
resp, r, err := api_client.MxPlatformApi.ListInstitutions(ctx).Name(name).Page(page).RecordsPerPage(recordsPerPage).SupportsAccountIdentification(supportsAccountIdentification).SupportsAccountStatement(supportsAccountStatement).SupportsAccountVerification(supportsAccountVerification).SupportsTransactionHistory(supportsTransactionHistory).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.ListInstitutions``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.ListInstitutions`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String name = "chase";
int page = 1;
int recordsPerPage = 10;
boolean supportsAccountIdentification = true;
boolean supportsAccountStatement = true;
boolean supportsAccountVerification = true;
boolean supportsTransactionHistory = true;
try {
InstitutionsResponseBody response = apiInstance.listInstitutions(name, page, recordsPerPage, supportsAccountIdentification, supportsAccountStatement, supportsAccountVerification, supportsTransactionHistory);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#listInstitutions");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const name = 'chase';
const page = 1;
const recordsPerPage = 10;
const supportsAccountIdentification = true;
const supportsAccountStatement = true;
const supportsAccountVerification = true;
const supportsTransactionHistory = true;
const response = await client.listInstitutions(name, page, recordsPerPage, supportsAccountIdentification, supportsAccountStatement, supportsAccountVerification, supportsTransactionHistory);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
name = 'chase'
page = 1
records_per_page = 10
supports_account_identification = True
supports_account_statement = True
supports_account_verification = True
supports_transaction_history = True
try:
api_response = api_instance.list_institutions(name=name, page=page, records_per_page=records_per_page, supports_account_identification=supports_account_identification, supports_account_statement=supports_account_statement, supports_account_verification=supports_account_verification, supports_transaction_history=supports_transaction_history)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->list_institutions: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
opts = {
name: 'chase',
page: 1,
records_per_page: 10,
supports_account_identification: true,
supports_account_statement: true,
supports_account_verification: true,
supports_transaction_history: true
}
begin
response = mx_platform_api.list_institutions(opts)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->list_institutions: #{e}"
end
1
2
3
curl -i -X GET 'https://int-api.mx.com/institutions?name=chase&page=1&records_per_page=10&supports_account_identification=true&supports_account_statement=true&supports_account_verification=true&supports_transaction_history=true' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
class InstitutionsResponseBody {
Institutions: List<InstitutionResponse>(){
class InstitutionResponse {
Code: chase,
InstructionalText: Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.,
MediumLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png,
Name: Chase Bank,
SmallLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png,
SupportsAccountIdentification: True,
SupportsAccountStatement: True,
SupportsAccountVerification: True,
SupportsOauth: True,
SupportsTransactionHistory: True,
Url: https://www.chase.com
}
},
Pagination: class PaginationResponse {
CurrentPage: 1,
PerPage: 25,
TotalEntries: 1,
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
mxplatformgo.InstitutionsResponseBody{
Institutions: []mxplatformgo.InstitutionResponse{
mxplatformgo.InstitutionResponse{
Code: "chase"
InstructionalText: "Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>."
MediumLogoUrl: "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png"
Name: "Chase Bank"
SmallLogoUrl: "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png"
SupportsAccountIdentification: true
SupportsAccountStatement: true
SupportsAccountVerification: true
SupportsOauth: true
SupportsTransactionHistory: true
Url: "https://www.chase.com"
}
}
Pagination: mxplatformgo.PaginationResponse{
CurrentPage: 1
PerPage: 25
TotalEntries: 1
TotalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
class InstitutionsResponseBody {
institutions: [
class InstitutionResponse {
code: chase
instructionalText: Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.
mediumLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png
name: Chase Bank
smallLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png
supportsAccountIdentification: true
supportsAccountStatement: true
supportsAccountVerification: true
supportsOauth: true
supportsTransactionHistory: true
url: https://www.chase.com
}
]
pagination: class PaginationResponse {
currentPage: 1
perPage: 25
totalEntries: 1
totalPages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
institutions: [
{
code: 'chase',
instructional_text: 'Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
medium_logo_url: 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
name: 'Chase Bank',
small_logo_url: 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
supports_account_identification: true,
supports_account_statement: true,
supports_account_verification: true,
supports_oauth: true,
supports_transaction_history: true,
url: 'https://www.chase.com'
}
],
pagination: {
current_page: 1,
per_page: 25,
total_entries: 1,
total_pages: 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
'institutions': [
{
'code': 'chase',
'instructional_text': 'Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
'medium_logo_url': 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
'name': 'Chase Bank',
'small_logo_url': 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
'supports_account_identification': True,
'supports_account_statement': True,
'supports_account_verification': True,
'supports_oauth': True,
'supports_transaction_history': True,
'url': 'https://www.chase.com'
}
],
'pagination': {
'current_page': 1,
'per_page': 25,
'total_entries': 1,
'total_pages': 1
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
#<::MxPlatformRuby::InstitutionsResponseBody
@institutions=[
#<::MxPlatformRuby::InstitutionResponse
@code='chase',
@instructional_text='Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
@medium_logo_url='https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
@name='Chase Bank',
@small_logo_url='https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
@supports_account_identification=true,
@supports_account_statement=true,
@supports_account_verification=true,
@supports_oauth=true,
@supports_transaction_history=true,
@url='https://www.chase.com'
>
],
@pagination=#<::MxPlatformRuby::PaginationResponse
@current_page=1,
@per_page=25,
@total_entries=1,
@total_pages=1
>
>
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
{
"institutions": [
{
"code": "chase",
"instructional_text": "Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.",
"medium_logo_url": "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png",
"name": "Chase Bank",
"small_logo_url": "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png",
"supports_account_identification": true,
"supports_account_statement": true,
"supports_account_verification": true,
"supports_oauth": true,
"supports_transaction_history": true,
"url": "https://www.chase.com"
}
],
"pagination": {
"current_page": 1,
"per_page": 25,
"total_entries": 1,
"total_pages": 1
}
}
This endpoint returns information about the institution specified by institution_code
.
Endpoint:
GET /institutions/{institution_code}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
using System;
using MX.Platform.CSharp.Api;
using MX.Platform.CSharp.Client;
using MX.Platform.CSharp.Model;
using System.Collections.Generic;
namespace MyProject
{
class Program
{
static void Main(string[] args)
{
Configuration config = new Configuration();
config.DefaultHeaders = new Dictionary<string, string>{{ "Accept", "application/vnd.mx.api.v1+json" }};
// Configure with your Client ID/API Key from https://dashboard.mx.com
config.Username = "Your Client ID";
config.Password = "Your API Key";
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
config.BasePath = "https://int-api.mx.com";
var apiInstance = new MxPlatformApi(config);
var institutionCode = "chase";
try
{
InstitutionResponseBody result = apiInstance.ReadInstitution(institutionCode);
Console.WriteLine(result);
}
catch (ApiException e)
{
Console.WriteLine("Exception when calling MxPlatformApi.ReadInstitution: " + e.Message );
Console.WriteLine("Status Code: "+ e.ErrorCode);
Console.WriteLine(e.StackTrace);
}
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
package main
import (
"context"
"fmt"
"github.com/mxenabled/mx-platform-go"
"os"
)
func main() {
configuration := mxplatformgo.NewConfiguration()
configuration.AddDefaultHeader("Accept", "application/vnd.mx.api.v1+json")
api_client := mxplatformgo.NewAPIClient(configuration)
// Configure environment. 0 for production, 1 for development
ctx := context.WithValue(context.Background(), mxplatformgo.ContextServerIndex, 1)
// Configure with your Client ID/API Key from https://dashboard.mx.com
ctx = context.WithValue(ctx, mxplatformgo.ContextBasicAuth, mxplatformgo.BasicAuth{
UserName: "Your Client ID",
Password: "Your API Key",
})
institutionCode := "chase"
resp, r, err := api_client.MxPlatformApi.ReadInstitution(ctx, institutionCode).Execute()
if err != nil {
fmt.Fprintf(os.Stderr, "Error when calling `MxPlatformApi.ReadInstitution``: %v\n", err)
fmt.Fprintf(os.Stderr, "Full HTTP response: %v\n", r)
}
fmt.Printf("Response from `MxPlatformApi.ReadInstitution`: %#v\n", resp)
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
import com.mx.client.ApiClient;
import com.mx.client.ApiException;
import com.mx.client.Configuration;
import com.mx.client.auth.*;
import com.mx.client.model.*;
import com.mx.client.mx_platform_api.MxPlatformApi;
import java.util.*;
public class Example {
public static void main(String[] args) {
ApiClient defaultClient = Configuration.getDefaultApiClient();
defaultClient.addDefaultHeader("Accept", "application/vnd.mx.api.v1+json");
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
defaultClient.setBasePath("https://int-api.mx.com");
// Configure with your Client ID/API Key from https://dashboard.mx.com
HttpBasicAuth basicAuth = (HttpBasicAuth) defaultClient.getAuthentication("basicAuth");
basicAuth.setUsername("Your Client ID");
basicAuth.setPassword("Your API Key");
MxPlatformApi apiInstance = new MxPlatformApi(defaultClient);
String institutionCode = "chase";
try {
InstitutionResponseBody response = apiInstance.readInstitution(institutionCode);
System.out.println(response);
} catch (ApiException e) {
System.err.println("Exception when calling MxPlatformApi#readInstitution");
System.err.println("Status code: " + e.getCode());
System.err.println("Reason: " + e.getResponseBody());
System.err.println("Response headers: " + e.getResponseHeaders());
e.printStackTrace();
}
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
import { Configuration, MxPlatformApi } from 'mx-platform-node';
const configuration = new Configuration({
// Configure with your Client ID/API Key from https://dashboard.mx.com
username: 'Your Client ID',
password: 'Your API Key',
// Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
basePath: 'https://int-api.mx.com',
baseOptions: {
headers: {
Accept: 'application/vnd.mx.api.v1+json'
}
}
});
const client = new MxPlatformApi(configuration);
const institutionCode = 'chase';
const response = await client.readInstitution(institutionCode);
console.log(response.data);
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
import mx_platform_python
from mx_platform_python.api import mx_platform_api
from mx_platform_python.models import *
from pprint import pprint
configuration = mx_platform_python.Configuration(
# Configure with your Client ID/API Key from https://dashboard.mx.com
username = 'Your Client ID',
password = 'Your API Key',
# Configure environment. https://int-api.mx.com for development, https://api.mx.com for production
host = 'https://int-api.mx.com'
)
with mx_platform_python.ApiClient(configuration, 'Accept', 'application/vnd.mx.api.v1+json') as api_client:
api_instance = mx_platform_api.MxPlatformApi(api_client)
institution_code = 'chase'
try:
api_response = api_instance.read_institution(institution_code)
pprint(api_response)
except mx_platform_python.ApiException as e:
print("Exception when calling MxPlatformApi->read_institution: %s\n" % e)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
require 'mx-platform-ruby'
::MxPlatformRuby.configure do |config|
# Configure with your Client ID/API Key from https://dashboard.mx.com
config.username = 'Your Client ID'
config.password = 'Your API Key'
# Configure environment. 0 for production, 1 for development
config.server_index = 1
end
api_client = ::MxPlatformRuby::ApiClient.new
api_client.default_headers['Accept'] = 'application/vnd.mx.api.v1+json'
mx_platform_api = ::MxPlatformRuby::MxPlatformApi.new(api_client)
institution_code = 'chase'
begin
response = mx_platform_api.read_institution(institution_code)
p response
rescue ::MxPlatformRuby::ApiError => e
puts "Error when calling MxPlatformApi->read_institution: #{e}"
end
1
2
3
curl -i -X GET 'https://int-api.mx.com/institutions/chase' \
-H 'Accept: application/vnd.mx.api.v1+json' \
-u 'client_id:api_key'
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
class InstitutionResponseBody {
Institution: class InstitutionResponse {
Code: chase,
InstructionalText: Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.,
MediumLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png,
Name: Chase Bank,
SmallLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png,
SupportsAccountIdentification: True,
SupportsAccountStatement: True,
SupportsAccountVerification: True,
SupportsOauth: True,
SupportsTransactionHistory: True,
Url: https://www.chase.com
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
mxplatformgo.InstitutionResponseBody{
Institution: mxplatformgo.InstitutionResponse{
Code: "chase"
InstructionalText: "Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>."
MediumLogoUrl: "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png"
Name: "Chase Bank"
SmallLogoUrl: "https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png"
SupportsAccountIdentification: true
SupportsAccountStatement: true
SupportsAccountVerification: true
SupportsOauth: true
SupportsTransactionHistory: true
Url: "https://www.chase.com"
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
class InstitutionResponseBody {
institution: class InstitutionResponse {
code: chase
instructionalText: Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.
mediumLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png
name: Chase Bank
smallLogoUrl: https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png
supportsAccountIdentification: true
supportsAccountStatement: true
supportsAccountVerification: true
supportsOauth: true
supportsTransactionHistory: true
url: https://www.chase.com
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
{
institution: {
code: 'chase',
instructional_text: 'Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
medium_logo_url: 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
name: 'Chase Bank',
small_logo_url: 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
supports_account_identification: true,
supports_account_statement: true,
supports_account_verification: true,
supports_oauth: true,
supports_transaction_history: true,
url: 'https://www.chase.com'
}
}
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
{
'institution': {
'code': 'chase',
'instructional_text': 'Some instructional text <a href="https://example.url.chase.com/instructions" id="instructional_text">for end users</a>.',
'medium_logo_url': 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/100x100/default_100x100.png',
'name': 'Chase Bank',
'small_logo_url': 'https://content.moneydesktop.com/storage/MD_Assets/Ipad%20Logos/50x50/default_50x50.png',
'supports_account_identification': True,
'supports_account_statement': True,
'supports_account_verification': True,
'supports_oauth': True,
'supports_transaction_history': True,
'url': 'https://www.chase.com'
}
}