Messages v0.4.1
Scroll down for code samples, example requests and responses. Select a language for code samples from the tabs above or the mobile navigation menu.
Secure/private in-application messages, organized in message threads, between a banking customer and the financial institution.
A message thread is a sequence of one or more messageswith a common message topic, a banking customer, an optional subject, and an optional context. The caller must include a new message object when creating a new message thread. This API provides a list of topics to choose from when creating a new message thread, such as an inquiry, a dispute, a request for support or to report a problem. The context defines what the message thread pertains to, such as an account or problems with the client mobile or web application. A thread can be started by the customer or the financial institution. Customers can only view threads which they created or which the financial institution assigned the customer as the thread recipient. Messages in a message thread are ordered in chronological order (oldest first).
New threads start in the open
state. The customer or the financial institution may closeMessageThread
the thread. financial institution operators may reopen closed message threads.
Each message within a message thread contains some plain text, optional attachments, the thread the message belongs to, a sender, and the message read/unread status. Customers can mark messages from the financial institution as (read
or unread
). but may not delete them. Customers or the financial institution operators may reply to a thread by creating new messages in the thread. Messages are immutable, although the customer may delete attachments from messages.
Error Types
Error responses in this API may have one of the type
values described below.
See Errors for more information
on error responses and error types.
cannotChangeReadStateOfOwnMessage
Description: A user can only mark a message as read
or unread
if they are not the message author.
Remediation: Call the mark-as-read operations only on received messages.
invalidAttachmentContentType
Description: The contentType
was invalid, did not match the URI content, or is not an allowed media type.
Remediation: Use an allwoed media type that matches the content.
invalidAttachmentUri
Description: The attachment URI is invalid.
Remediation: Use a URI of a valid file's raw content in the Vault service.
invalidContext
Description: The context URI is invalid or is not a an allowed resource for the message topic.
Remediation: Use a valid context resource that relates to the selected message topic.
messageThreadClosed
Description: Replying to a closed message thread is not allowed.
Remediation: Re-open the thread, reply to an open thread, or start a new thread.
noSuchMessage
Description: No such message for the given message
parameter.
Remediation: Use the _id
of an existing message resource.
noSuchMessageThread
Description: No such message thread.
Remediation: Use the _id
of the existing message thread.
noSuchMessageTopic
Description: No such message topic.
Remediation: Use the name
of an existing message topic for the messageTopic
.
noSuchOperator
Description: No such operator thread.
Remediation: Use the _id
of the existing operator.
noSuchUser
Description: No such user.
Remediation: Use the _id
of an existing customer user.
tooManyMessagesInThread
Description: The message thread already contains the maximum number of messages.
Remediation: Start a new message thread.
Download OpenAPI Definition (YAML)
Base URLs:
Authentication
- API Key (
apiKey
)- header parameter: API-Key
- API Key based authentication. See details at Secure Access.
- OAuth2 authentication (
accessToken
)- OAuth2 client access token authentication. See details at Secure Access.
- Flow:
authorizationCode
- Authorization URL = https://auth.apiture.com/oauth2/authorize
- Token URL = https://auth.apiture.com/auth/oauth2/token
Scope | Scope Description |
---|---|
data/read |
Read access to non-account, non-profile data. |
data/write |
Write (update) access to non-account, non-profile data. |
data/delete |
Delete access to non-account, non-profile data. |
data/full |
Full access to non-account, non-profile data. |
Message Threads
Threaded discussions between the Customer and the Financial Institution
getMessageThreads
Code samples
# You can also use wget
curl -X GET https://api.devbank.apiture.com/messages/messageThreads \
-H 'Accept: application/json' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
GET https://api.devbank.apiture.com/messages/messageThreads HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
var headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messageThreads',
method: 'get',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messageThreads',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.get 'https://api.devbank.apiture.com/messages/messageThreads',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.get('https://api.devbank.apiture.com/messages/messageThreads', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messageThreads");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/messages/messageThreads", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Return a collection of message threads
GET /messageThreads
Return a paginated filterable collection of message threads. The links in the response include pagination links.
The items are returned in chronological order (oldest first).
When called by a customer user, this operation returns only threads that are owned by the customer. For the customer view, clients should use ?state=open
to exclude closed threads or threads in other states.
Parameters
Parameter | Description |
---|---|
state (query) |
string Filter message threads whose state matches the query parameter. array[string] values: open , closed |
assignedOperator (query) |
string Filter message threads whose assignedOperator operator ID matches the query parameter. This parameter is only used by financial institution operators. minLength: 16 maxLength: 48 |
userId (query) |
string Filter message threads whose userId matches the query parameter. This parameter is only used by financial institution operators. minLength: 16 maxLength: 48 |
topicName (query) |
string Filter message threads whose topicName matches the query parameter. The value should be one of the message topic names from getMessageTopics . minLength: 4 maxLength: 24 |
contextType (query) |
string Filter message threads whose contextType matches the query parameter. minLength: 4 maxLength: 40 |
start (query) |
integer(int64) The zero-based index of the first message thread item to include in this page. The default 0 denotes the beginning of the collection. |
limit (query) |
integer(int32) The maximum number of message thread representations to return in this page. Default: 100 |
filter (query) |
string Optional filter criteria. See filtering. This collection may be filtered by the following properties and functions: • Property topicName using functions in , eq • Property contextType using functions in , eq • Property applicationPlatform using functions in , eq • Property createdAt using functions lt , le , gt , ge • Property unreadOperatorMessageCount using functions lt , le , gt , ge , eq , ne • Property unreadCustomerMessageCount using functions lt , le , gt , ge , eq , ne . |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThreads/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads?start=10&limit=10"
},
"first": {
"href": "https://api.devbank.apiture.com/messages/messageThreads?start=0&limit=10"
},
"next": {
"href": "https://api.devbank.apiture.com/messages/messageThreads?start=20&limit=10"
},
"collection": {
"href": "https://api.devbank.apiture.com/messages/messageThreads"
}
},
"name": "messageThreads",
"start": 10,
"limit": 10,
"count": 67,
"_embedded": {
"items": {
"0": {
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_profile": "https://production.api.apiture.com/schemas/messages/summaryMessageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "/messages/messageThreads/0399abed-fd3d-4830-a88b-30f38b8a365c"
}
}
}
}
}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: messageThreads |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
422 | Unprocessable Entity |
Unprocessable Entity. The request body and/or query parameters were well formed but otherwise invalid. The This error response may have one of the following | |
Schema: errorResponse |
createMessageThread
Code samples
# You can also use wget
curl -X POST https://api.devbank.apiture.com/messages/messageThreads \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
POST https://api.devbank.apiture.com/messages/messageThreads HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/json
Accept: application/json
var headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messageThreads',
method: 'post',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const inputBody = '{
"_profile": "https://production.api.apiture.com/schemas/messages/createMessageThread/v1.0.1/profile.json",
"_links": {},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"message": {
"body": "The app still shows that my card is locked. See the attached screen capture",
"attachments": {
"0": {
"name": "screen=capture-0001.png",
"contentType": "image/png",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
}
}
}';
const headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messageThreads',
{
method: 'POST',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Content-Type' => 'application/json',
'Accept' => 'application/json',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.post 'https://api.devbank.apiture.com/messages/messageThreads',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://api.devbank.apiture.com/messages/messageThreads', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messageThreads");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Content-Type": []string{"application/json"},
"Accept": []string{"application/json"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/messages/messageThreads", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Create a new message thread
POST /messageThreads
Create a new message thread in the message threads collection.
Body parameter
{
"_profile": "https://production.api.apiture.com/schemas/messages/createMessageThread/v1.0.1/profile.json",
"_links": {},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"message": {
"body": "The app still shows that my card is locked. See the attached screen capture",
"attachments": {
"0": {
"name": "screen=capture-0001.png",
"contentType": "image/png",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
}
}
}
Parameters
Parameter | Description |
---|---|
body (body) |
createMessageThread The data necessary to create a new message thread. |
Try It
Example responses
201 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
201 | Created |
Created. | |
Schema: messageThread |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
422 | Unprocessable Entity |
Unprocessable Entity. The request body and/or query parameters were well formed but otherwise invalid. The This error response may have one of the following | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
201 | Location string uri |
The URI of the new resource. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme ://host | |
201 | ETag string |
An entity tag which may be passed in the If-Match request header for PUT or PATCH operations which update the resource. |
getMessageThread
Code samples
# You can also use wget
curl -X GET https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId} \
-H 'Accept: application/json' \
-H 'If-None-Match: string' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
GET https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
If-None-Match: string
var headers = {
'Accept':'application/json',
'If-None-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
method: 'get',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'If-None-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'If-None-Match' => 'string',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.get 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'If-None-Match': 'string',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.get('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"If-None-Match": []string{"string"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Fetch a representation of this message thread
GET /messageThreads/{messageThreadId}
Return a HAL representation of this message thread resource.
Parameters
Parameter | Description |
---|---|
If-None-Match (header) |
string The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET returns 304 (Not Modified) and no response body, else the resource representation is returned. |
messageThreadId (path) |
string (required) The unique identifier of this message thread. This is an opaque string. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: messageThread |
Status | Description |
---|---|
304 | Not Modified |
Not Modified. The resource has not been modified since it was last fetched. |
Status | Description |
---|---|
404 | Not Found |
Not Found. There is no such message thread resource at the specified {messageThreadId} . The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
200 | ETag string |
The ETag response header specifies an entity tag which may be provided in an If-Match request header for PUT or PATCH operations which update this message thread resource. |
updateMessageThread
Code samples
# You can also use wget
curl -X PUT https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId} \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'If-Match: string' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
PUT https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/json
Accept: application/json
If-Match: string
var headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
method: 'put',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const inputBody = '{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}';
const headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
{
method: 'PUT',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Content-Type' => 'application/json',
'Accept' => 'application/json',
'If-Match' => 'string',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.put 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'If-Match': 'string',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.put('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PUT");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Content-Type": []string{"application/json"},
"Accept": []string{"application/json"},
"If-Match": []string{"string"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("PUT", "https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Update this message thread
PUT /messageThreads/{messageThreadId}
Perform a complete replacement of this message thread. Only operators may update message threads. Mutable properties are the topicName
, assignedOperator
, applicationPlatform
.
Body parameter
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Parameters
Parameter | Description |
---|---|
If-Match (header) |
string The entity tag that was returned in the ETag response. If passed, this must match the current entity tag of the resource. |
body (body) |
messageThread A new message thread |
messageThreadId (path) |
string (required) The unique identifier of this message thread. This is an opaque string. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: messageThread |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
404 | Not Found |
Not Found. There is no such message thread resource at the specified {messageThreadId} . The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
412 | Precondition Failed |
Precondition Failed. The supplied If-Match header value does not match the most recent ETag response header value. The resource has changed in the interim. | |
Schema: errorResponse |
Status | Description |
---|---|
422 | Unprocessable Entity |
Unprocessable Entity. The request body and/or query parameters were well formed but otherwise invalid. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
200 | ETag string |
The ETag response header specifies an entity tag which may be provided in an If-Match request header for PUT or PATCH operations which update this message thread resource. |
patchMessageThread
Code samples
# You can also use wget
curl -X PATCH https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId} \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'If-Match: string' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
PATCH https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId} HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/json
Accept: application/json
If-Match: string
var headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
method: 'patch',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const inputBody = '{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}';
const headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
{
method: 'PATCH',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Content-Type' => 'application/json',
'Accept' => 'application/json',
'If-Match' => 'string',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.patch 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'If-Match': 'string',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.patch('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("PATCH");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Content-Type": []string{"application/json"},
"Accept": []string{"application/json"},
"If-Match": []string{"string"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("PATCH", "https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Update this message thread
PATCH /messageThreads/{messageThreadId}
Perform a partial update of this message thread. Fields which are omitted are not updated. Nested _embedded
and _links
are ignored if included. Only operators may update message threads. Mutable properties are the topicName
, assignedOperator
, applicationPlatform
.
Body parameter
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Parameters
Parameter | Description |
---|---|
If-Match (header) |
string The entity tag that was returned in the ETag response. If passed, this must match the current entity tag of the resource. |
body (body) |
messageThread The new message thread. |
messageThreadId (path) |
string (required) The unique identifier of this message thread. This is an opaque string. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: messageThread |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
404 | Not Found |
Not Found. There is no such message thread resource at the specified {messageThreadId} . The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
412 | Precondition Failed |
Precondition Failed. The supplied If-Match header value does not match the most recent ETag response header value. The resource has changed in the interim. | |
Schema: errorResponse |
Status | Description |
---|---|
422 | Unprocessable Entity |
Unprocessable Entity. The request body and/or query parameters were well formed but otherwise invalid. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
200 | ETag string |
The ETag response header specifies an entity tag which may be provided in an If-Match request header for PUT or PATCH operations which update this message thread resource. |
Message Thread Actions
Actions on Message Threads
closeMessageThread
Code samples
# You can also use wget
curl -X POST https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=string \
-H 'Accept: application/json' \
-H 'If-Match: string' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
POST https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
If-Match: string
var headers = {
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/closedMessageThreads',
method: 'post',
data: '?messageThread=string',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=string',
{
method: 'POST',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'If-Match' => 'string',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.post 'https://api.devbank.apiture.com/messages/closedMessageThreads',
params: {
'messageThread' => 'string'
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'If-Match': 'string',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://api.devbank.apiture.com/messages/closedMessageThreads', params={
'messageThread': 'string'
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"If-Match": []string{"string"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/messages/closedMessageThreads", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Close a message thread
POST /closedMessageThreads
Close a message thread. This changes the state
property of the message thread to closed
. This operation is available via the apiture:close
link on the message thread resource, if and only if the message thread is eligible for the close operation. The response is the updated representation of the message thread. Only administrators/operators may close threads.
This operation is idempotent: no changes are made if the message thread is already closed
. The If-Match
request header value, if passed, must match the current entity tag value of the message thread.
Parameters
Parameter | Description |
---|---|
messageThread (query) |
string (required) A string which uniquely identifies a message thread to close. This may be the unique messageThreadId or the URI of the message thread. |
If-Match (header) |
string The entity tag that was returned in the ETag response. If passed, this must match the current entity tag of the resource. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. The operation succeeded. The message thread was updated and its state changed to closed . | |
Schema: messageThread |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The messageThread parameter was malformed or does not refer to an existing or accessible message thread. This error response may have one of the following | |
Schema: errorResponse |
Status | Description |
---|---|
409 | Conflict |
Conflict. The request to close the message thread is not allowed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
412 | Precondition Failed |
Precondition Failed. The supplied If-Match header value does not match the most recent ETag response header value. The resource has changed in the interim. | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
200 | ETag string |
The ETag response header specifies an entity tag which may be provided in an If-Match request header for PUT or PATCH operations which update the resource to perform conditional updates. |
openMessageThread
Code samples
# You can also use wget
curl -X POST https://api.devbank.apiture.com/messages/openMessageThreads?messageThread=string \
-H 'Accept: application/json' \
-H 'If-Match: string' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
POST https://api.devbank.apiture.com/messages/openMessageThreads?messageThread=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
If-Match: string
var headers = {
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/openMessageThreads',
method: 'post',
data: '?messageThread=string',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'If-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/openMessageThreads?messageThread=string',
{
method: 'POST',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'If-Match' => 'string',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.post 'https://api.devbank.apiture.com/messages/openMessageThreads',
params: {
'messageThread' => 'string'
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'If-Match': 'string',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://api.devbank.apiture.com/messages/openMessageThreads', params={
'messageThread': 'string'
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/openMessageThreads?messageThread=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"If-Match": []string{"string"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/messages/openMessageThreads", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Open a message thread
POST /openMessageThreads
Open a message thread. This changes the state
property of the message thread to open
. This operation is available via the apiture:open
link on the message thread resource, if and only if the message thread is eligible for the open operation. The response is the updated representation of the message thread. Only an operator may open a closed thread.
This operation is idempotent: no changes are made if the message thread is already open
. The If-Match
request header value, if passed, must match the current entity tag value of the message thread.
Parameters
Parameter | Description |
---|---|
messageThread (query) |
string (required) A string which uniquely identifies a message thread to open. This may be the unique messageThreadId or the URI of the message thread. |
If-Match (header) |
string The entity tag that was returned in the ETag response. If passed, this must match the current entity tag of the resource. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. The operation succeeded. The message thread was updated and its state changed to open . | |
Schema: messageThread |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The messageThread parameter was malformed or does not refer to an existing or accessible message thread. This error response may have one of the following | |
Schema: errorResponse |
Status | Description |
---|---|
409 | Conflict |
Conflict. The request to open the message thread is not allowed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
412 | Precondition Failed |
Precondition Failed. The supplied If-Match header value does not match the most recent ETag response header value. The resource has changed in the interim. | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
200 | ETag string |
The ETag response header specifies an entity tag which may be provided in an If-Match request header for PUT or PATCH operations which update the resource to perform conditional updates. |
Messages
Messages within a Message Thread
getMessages
Code samples
# You can also use wget
curl -X GET https://api.devbank.apiture.com/messages/messages \
-H 'Accept: application/json' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
GET https://api.devbank.apiture.com/messages/messages HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
var headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messages',
method: 'get',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messages',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.get 'https://api.devbank.apiture.com/messages/messages',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.get('https://api.devbank.apiture.com/messages/messages', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messages");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/messages/messages", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Return a collection of messages
GET /messages
Return a paginated filterable collection of messages. The links in the response include pagination links. The items are returned in chronological order (oldest first).
When called by a customer user, this operation returns only threads that are owned by the customer. For the customer view, clients should use ?state=open
to exclude closed threads or threads in other states.
Parameters
Parameter | Description |
---|---|
messageThread (query) |
string Filter messages to only those within the named message thread. The value must the the _id of an existing message thread. minLength: 16 maxLength: 48 |
readState (query) |
boolean Filter messages whose readState matches the query parameter. |
authorType (query) |
string Filter messages whose authorType matches the query parameter. array[string] values: customer , operator |
start (query) |
integer(int64) The zero-based index of the first message item to include in this page. The default 0 denotes the beginning of the collection. |
limit (query) |
integer(int32) The maximum number of message representations to return in this page. Default: 100 |
filter (query) |
string Optional filter criteria. See filtering. This collection may be filtered by the following properties and functions: • Property applicationPlatform using functions in , eq • Property createdAt using functions lt , le , gt , ge • Property updatedAt using functions lt , le , gt , ge . |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messages/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages?start=10&limit=10"
},
"first": {
"href": "https://api.devbank.apiture.com/messages/messages?start=0&limit=10"
},
"next": {
"href": "https://api.devbank.apiture.com/messages/messages?start=20&limit=10"
},
"collection": {
"href": "https://api.devbank.apiture.com/messages/messages"
}
},
"name": "messages",
"start": 10,
"limit": 10,
"count": 67,
"_embedded": {
"items": {
"0": {
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e-47a2-a168-22427cfeaa0e",
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_profile": "https://production.api.apiture.com/schemas/messages/summaryMessage/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/0399abed-fd3d-4830-a88b-30f38b8a365c"
}
}
}
}
}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: messages |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
422 | Unprocessable Entity |
Unprocessable Entity. The request body and/or query parameters were well formed but otherwise invalid. The This error response may have one of the following | |
Schema: errorResponse |
getMessage
Code samples
# You can also use wget
curl -X GET https://api.devbank.apiture.com/messages/messages/{messageId} \
-H 'Accept: application/json' \
-H 'If-None-Match: string' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
GET https://api.devbank.apiture.com/messages/messages/{messageId} HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
If-None-Match: string
var headers = {
'Accept':'application/json',
'If-None-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messages/{messageId}',
method: 'get',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'If-None-Match':'string',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messages/{messageId}',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'If-None-Match' => 'string',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.get 'https://api.devbank.apiture.com/messages/messages/{messageId}',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'If-None-Match': 'string',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.get('https://api.devbank.apiture.com/messages/messages/{messageId}', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messages/{messageId}");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"If-None-Match": []string{"string"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/messages/messages/{messageId}", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Fetch a representation of this message
GET /messages/{messageId}
Return a HAL representation of this message resource.
Parameters
Parameter | Description |
---|---|
If-None-Match (header) |
string The entity tag that was returned in the ETag response. If the resource's current entity tag matches, the GET returns 304 (Not Modified) and no response body, else the resource representation is returned. |
messageId (path) |
string (required) The unique identifier of this message. This is an opaque string. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/message/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/1a4eaf05-2d8e"
},
"apiture:markAsRead": {
"href": "https://api.devbank.apiture.com/messages/readMessages?message=1a4eaf05-2d8e"
},
"apiture:markAsUnread": {
"href": "https://api.devbank.apiture.com/messages/unreadMessages?message=1a4eaf05-2d8e"
},
"apiture:messageThread": {
"href": "https://api.devbank.apiture.com/messages/messagesThreads/866bd544-18ad"
}
},
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e",
"readState": false,
"authorType": "customer",
"createdBy": "x66677ca3-cffc",
"updatedAt": "2021-02-17T13:04:53.375Z",
"createdAt": "2021-02-17T13:04:59.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: message |
Status | Description |
---|---|
304 | Not Modified |
Not Modified. The resource has not been modified since it was last fetched. |
Status | Description |
---|---|
404 | Not Found |
Not Found. There is no such message resource at the specified {messageId} . The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
200 | ETag string |
The ETag response header specifies an entity tag which may be provided in an If-Match request header for PUT or PATCH operations which update this message resource. |
createMessage
Code samples
# You can also use wget
curl -X POST https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies \
-H 'Content-Type: application/json' \
-H 'Accept: application/json' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
POST https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies HTTP/1.1
Host: api.devbank.apiture.com
Content-Type: application/json
Accept: application/json
var headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies',
method: 'post',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const inputBody = '{
"_profile": "https://production.api.apiture.com/schemas/messages/createMessage/v1.0.1/profile.json",
"_links": {},
"body": "My card is still showing up as locked.",
"attachments": {
"0": {
"name": "screen=capture-0001.png",
"contentType": "image/png",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"threadId": "b171c313-0264"
}';
const headers = {
'Content-Type':'application/json',
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies',
{
method: 'POST',
body: inputBody,
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Content-Type' => 'application/json',
'Accept' => 'application/json',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.post 'https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Content-Type': 'application/json',
'Accept': 'application/json',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Content-Type": []string{"application/json"},
"Accept": []string{"application/json"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/messages/messageThreads/{messageThreadId}/replies", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Create a new message in this thread.
POST /messageThreads/{messageThreadId}/replies
Create a new message within the existing message thread. After creation, the resource is referenced via the getMessage
operation; the new message resource URI is returned in the Location
response header. This operation is available if the thread is open and has not reached its maximum number of messages. (Use the apiture:reply
link a messageThread
.) The authorType
of the new message is assigned automatically based on the access token of the caller.
Body parameter
{
"_profile": "https://production.api.apiture.com/schemas/messages/createMessage/v1.0.1/profile.json",
"_links": {},
"body": "My card is still showing up as locked.",
"attachments": {
"0": {
"name": "screen=capture-0001.png",
"contentType": "image/png",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"threadId": "b171c313-0264"
}
Parameters
Parameter | Description |
---|---|
body (body) |
createMessage The data necessary to create a new message. |
messageThreadId (path) |
string (required) The unique identifier of this message thread. This is an opaque string. |
Try It
Example responses
201 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/message/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/1a4eaf05-2d8e"
},
"apiture:markAsRead": {
"href": "https://api.devbank.apiture.com/messages/readMessages?message=1a4eaf05-2d8e"
},
"apiture:markAsUnread": {
"href": "https://api.devbank.apiture.com/messages/unreadMessages?message=1a4eaf05-2d8e"
},
"apiture:messageThread": {
"href": "https://api.devbank.apiture.com/messages/messagesThreads/866bd544-18ad"
}
},
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e",
"readState": false,
"authorType": "customer",
"createdBy": "x66677ca3-cffc",
"updatedAt": "2021-02-17T13:04:53.375Z",
"createdAt": "2021-02-17T13:04:59.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
201 | Created |
Created. | |
Schema: message |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The request body or one or more of the query parameters was not well formed. The _error field in the response contains details about the request error. | |
Schema: errorResponse |
Status | Description |
---|---|
409 | Conflict |
Conflict. This error response may have one of the following | |
Schema: errorResponse |
Status | Description |
---|---|
422 | Unprocessable Entity |
Unprocessable Entity. The request body and/or query parameters were well formed but otherwise invalid. The This error response may have one of the following | |
Schema: errorResponse |
Response Headers
Status | Description |
---|---|
201 | Location string uri |
The URI of the new resource. If the URI begins with / it is relative to the API root context. Else, it is a full URI starting with scheme ://host | |
201 | ETag string |
An entity tag which may be passed in the If-Match request header for PUT or PATCH operations which update the resource. |
Message Actions
Actions on Messages
markAsRead
Code samples
# You can also use wget
curl -X POST https://api.devbank.apiture.com/messages/readMessages?message=string \
-H 'Accept: application/json' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
POST https://api.devbank.apiture.com/messages/readMessages?message=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
var headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/readMessages',
method: 'post',
data: '?message=string',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/readMessages?message=string',
{
method: 'POST',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.post 'https://api.devbank.apiture.com/messages/readMessages',
params: {
'message' => 'string'
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://api.devbank.apiture.com/messages/readMessages', params={
'message': 'string'
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/readMessages?message=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/messages/readMessages", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Mark as message as read.
POST /readMessages
Mark as message as read. This changes the readState
property of the message to true
and also the messages updatedAt
time stamp. This operation is available via the apiture:markAsRead
link on the message resource when the current user did not author the message and the message's readState
is not already true
. The client application should call this operation on an unread message when it presents the message to the user or the user specifically toggles an unread message to read. The response is the updated representation of the message.
This operation is idempotent: no changes are made if the message is already read
.
Parameters
Parameter | Description |
---|---|
message (query) |
string (required) A string which uniquely identifies a message to read. This may be the unique messageId or the URI of the message. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/message/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/1a4eaf05-2d8e"
},
"apiture:markAsRead": {
"href": "https://api.devbank.apiture.com/messages/readMessages?message=1a4eaf05-2d8e"
},
"apiture:markAsUnread": {
"href": "https://api.devbank.apiture.com/messages/unreadMessages?message=1a4eaf05-2d8e"
},
"apiture:messageThread": {
"href": "https://api.devbank.apiture.com/messages/messagesThreads/866bd544-18ad"
}
},
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e",
"readState": false,
"authorType": "customer",
"createdBy": "x66677ca3-cffc",
"updatedAt": "2021-02-17T13:04:53.375Z",
"createdAt": "2021-02-17T13:04:59.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. The operation succeeded. The message was updated and its state changed to read . | |
Schema: message |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The message parameter was malformed or does not refer to an existing or accessible message. This error response may have one of the following | |
Schema: errorResponse |
Status | Description |
---|---|
409 | Conflict |
Conflict. The request to read the message is not allowed. The This error response may have one of the following | |
Schema: errorResponse |
Status | Description |
---|---|
412 | Precondition Failed |
Precondition Failed. The supplied If-Match header value does not match the most recent ETag response header value. The resource has changed in the interim. | |
Schema: errorResponse |
markAsUnread
Code samples
# You can also use wget
curl -X POST https://api.devbank.apiture.com/messages/unreadMessages?message=string \
-H 'Accept: application/json' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
POST https://api.devbank.apiture.com/messages/unreadMessages?message=string HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
var headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/unreadMessages',
method: 'post',
data: '?message=string',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/unreadMessages?message=string',
{
method: 'POST',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.post 'https://api.devbank.apiture.com/messages/unreadMessages',
params: {
'message' => 'string'
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.post('https://api.devbank.apiture.com/messages/unreadMessages', params={
'message': 'string'
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/unreadMessages?message=string");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("POST");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("POST", "https://api.devbank.apiture.com/messages/unreadMessages", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Mark as message as unread.
POST /unreadMessages
Mark as message as unread. This changes the readState
property of the message to false
and also the messages updatedAt
time stamp. This operation is available via the apiture:markAsUnRead
link on the message resource when the current user did not author the message and the message's readState
is not already false
. The response is the updated representation of the message.
This operation is idempotent: no changes are made if the message is already unread
.
Parameters
Parameter | Description |
---|---|
message (query) |
string (required) A string which uniquely identifies a message to unread. This may be the unique messageId or the URI of the message. |
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/message/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/1a4eaf05-2d8e"
},
"apiture:markAsRead": {
"href": "https://api.devbank.apiture.com/messages/readMessages?message=1a4eaf05-2d8e"
},
"apiture:markAsUnread": {
"href": "https://api.devbank.apiture.com/messages/unreadMessages?message=1a4eaf05-2d8e"
},
"apiture:messageThread": {
"href": "https://api.devbank.apiture.com/messages/messagesThreads/866bd544-18ad"
}
},
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e",
"readState": false,
"authorType": "customer",
"createdBy": "x66677ca3-cffc",
"updatedAt": "2021-02-17T13:04:53.375Z",
"createdAt": "2021-02-17T13:04:59.375Z",
"_embedded": {}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. The operation succeeded. The message was updated and its state changed to unread . | |
Schema: message |
Status | Description |
---|---|
400 | Bad Request |
Bad Request. The message parameter was malformed or does not refer to an existing or accessible message. This error response may have one of the following | |
Schema: errorResponse |
Status | Description |
---|---|
409 | Conflict |
Conflict. The request to unread the message is not allowed. The This error response may have one of the following | |
Schema: errorResponse |
Status | Description |
---|---|
412 | Precondition Failed |
Precondition Failed. The supplied If-Match header value does not match the most recent ETag response header value. The resource has changed in the interim. | |
Schema: errorResponse |
Message Topics
Topics for Message Threads
getMessageTopics
Code samples
# You can also use wget
curl -X GET https://api.devbank.apiture.com/messages/messageTopics \
-H 'Accept: application/json' \
-H 'API-Key: API_KEY' \
-H 'Authorization: Bearer {access-token}'
GET https://api.devbank.apiture.com/messages/messageTopics HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
var headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/messageTopics',
method: 'get',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json',
'API-Key':'API_KEY',
'Authorization':'Bearer {access-token}'
};
fetch('https://api.devbank.apiture.com/messages/messageTopics',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json',
'API-Key' => 'API_KEY',
'Authorization' => 'Bearer {access-token}'
}
result = RestClient.get 'https://api.devbank.apiture.com/messages/messageTopics',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json',
'API-Key': 'API_KEY',
'Authorization': 'Bearer {access-token}'
}
r = requests.get('https://api.devbank.apiture.com/messages/messageTopics', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/messageTopics");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
"API-Key": []string{"API_KEY"},
"Authorization": []string{"Bearer {access-token}"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/messages/messageTopics", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Return a list of message topics
GET /messageTopics
Return a list of message topics. When creating a new message thread, one of these topics' names must be passed as the topicName
.
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageTopics/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/apiName/resourceName/resourceId"
}
},
"topics": {
"0": {
"name": "accountsAndApplications",
"label": "Accounts and Applications"
},
"1": {
"name": "cardServices",
"label": "Card Services"
},
"2": {
"name": "technicalAssistance",
"label": "Technical Assistance"
},
"3": {
"name": "inquiry",
"label": "General Inquiry or Feedback"
}
}
}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: messageTopics |
API
The Message API
getApi
Code samples
# You can also use wget
curl -X GET https://api.devbank.apiture.com/messages/ \
-H 'Accept: application/hal+json'
GET https://api.devbank.apiture.com/messages/ HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/hal+json
var headers = {
'Accept':'application/hal+json'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/',
method: 'get',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/hal+json'
};
fetch('https://api.devbank.apiture.com/messages/',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/hal+json'
}
result = RestClient.get 'https://api.devbank.apiture.com/messages/',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/hal+json'
}
r = requests.get('https://api.devbank.apiture.com/messages/', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/hal+json"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/messages/", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Top-level resources and operations in this API
GET /
Return links to the top-level resources and operations in this API.
Try It
Example responses
200 Response
{
"_profile": "https://production.api.apiture.com/schemas/common/root/v2.1.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/apiName/resourceName/resourceId"
}
},
"id": "apiName",
"name": "API name",
"apiVersion": "1.0.0"
}
Responses
getApiDoc
Code samples
# You can also use wget
curl -X GET https://api.devbank.apiture.com/messages/apiDoc \
-H 'Accept: application/json'
GET https://api.devbank.apiture.com/messages/apiDoc HTTP/1.1
Host: api.devbank.apiture.com
Accept: application/json
var headers = {
'Accept':'application/json'
};
$.ajax({
url: 'https://api.devbank.apiture.com/messages/apiDoc',
method: 'get',
headers: headers,
success: function(data) {
console.log(JSON.stringify(data));
}
})
const fetch = require('node-fetch');
const headers = {
'Accept':'application/json'
};
fetch('https://api.devbank.apiture.com/messages/apiDoc',
{
method: 'GET',
headers: headers
})
.then(function(res) {
return res.json();
}).then(function(body) {
console.log(body);
});
require 'rest-client'
require 'json'
headers = {
'Accept' => 'application/json'
}
result = RestClient.get 'https://api.devbank.apiture.com/messages/apiDoc',
params: {
}, headers: headers
p JSON.parse(result)
import requests
headers = {
'Accept': 'application/json'
}
r = requests.get('https://api.devbank.apiture.com/messages/apiDoc', params={
}, headers = headers)
print r.json()
URL obj = new URL("https://api.devbank.apiture.com/messages/apiDoc");
HttpURLConnection con = (HttpURLConnection) obj.openConnection();
con.setRequestMethod("GET");
int responseCode = con.getResponseCode();
BufferedReader in = new BufferedReader(
new InputStreamReader(con.getInputStream()));
String inputLine;
StringBuffer response = new StringBuffer();
while ((inputLine = in.readLine()) != null) {
response.append(inputLine);
}
in.close();
System.out.println(response.toString());
package main
import (
"bytes"
"net/http"
)
func main() {
headers := map[string][]string{
"Accept": []string{"application/json"},
}
data := bytes.NewBuffer([]byte{jsonReq})
req, err := http.NewRequest("GET", "https://api.devbank.apiture.com/messages/apiDoc", data)
req.Header = headers
client := &http.Client{}
resp, err := client.Do(req)
// ...
}
Return API definition document
GET /apiDoc
Return the OpenAPI document that describes this API.
Try It
Example responses
200 Response
{}
Responses
Status | Description |
---|---|
200 | OK |
OK. | |
Schema: Inline |
Response Schema
Schemas
abstractRequest
{
"_profile": "https://production.api.apiture.com/schemas/common/abstractRequest/v2.0.0/profile.json",
"_links": {}
}
Abstract Request (v2.0.0)
An abstract schema used to define other request-only schemas. This is a HAL resource representation, minus the _error
defined in abstractResource
.
This schema was resolved from common/abstractRequest
.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
abstractResource
{
"_profile": "https://production.api.apiture.com/schemas/common/abstractResource/v2.1.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/apiName/resourceName/resourceId"
}
}
}
Abstract Resource (v2.1.0)
An abstract schema used to define other schemas for request and response bodies. This is a HAL resource representation. This model contains hypermedia _links
, and either optional domain object data with _profile
and optional _embedded
objects, or an _error
object. In responses, if the operation was successful, this object will not include the _error
, but if the operation was a 4xx or 5xx error, this object will not include _embedded
or any data fields, only _error
and optionally _links
.
This schema was resolved from common/abstractResource
.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
applicationPlatform
"web"
Application Platform (v1.0.0)
The client application platform type.
applicationPlatform
strings may have one of the following enumerated values:
Value | Description |
---|---|
web | Web Application |
android | Android Application |
ios | iOS Application |
Type: string
Enumerated values: web
android
ios
attributes
{}
Attributes (v2.1.0)
An optional map of name/value pairs which contains additional dynamic data about the resource.
This schema was resolved from common/attributes
.
Properties
collection
{
"_profile": "https://production.api.apiture.com/schemas/common/abstractResource/v2.1.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/apiName/resourceName/resourceId"
}
}
}
Collection (v2.1.0)
A collection of resources. This is an abstract model schema which is extended to define specific resource collections.
This schema was resolved from common/collection
.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
count | integer The number of items in the collection. This value is optional and may be omitted if the count is not computable efficiently. If a filter is applied to the collection (either implicitly or explicitly), the count, if present, indicates the number of items that satisfy the filter. |
start | integer The start index of this page of items. |
limit | integer The maximum number of items per page. |
name | string The name of the collection. |
createMessage
{
"_profile": "https://production.api.apiture.com/schemas/messages/createMessage/v1.0.1/profile.json",
"_links": {},
"body": "My card is still showing up as locked.",
"attachments": {
"0": {
"name": "screen=capture-0001.png",
"contentType": "image/png",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"threadId": "b171c313-0264"
}
Create Message (v1.0.1)
Representation used to create a new message.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
body | string (required) The plain text body of the message. This may contain URLs. Line breaks are preserved. While the text might contain HTML or other special markup characters, these characters are not escaped. Clients must not interpret such HTML when displaying the body text. minLength: 2
maxLength: 2000
|
attachments | [messageAttachment] Optional documents attached to this message. The financial institution might configure the maximum number of attachments to be less than 5. maxItems: 5
|
operatorSignature | string The financial institution operator's name or other signature information. This is plain text and human readable, intended for the customer user. It is not the operator ID or operator username or email address. Note: This property is ignored when a customer user creates a message. minLength: 2
maxLength: 24
|
createMessageThread
{
"_profile": "https://production.api.apiture.com/schemas/messages/createMessageThread/v1.0.1/profile.json",
"_links": {},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"message": {
"body": "The app still shows that my card is locked. See the attached screen capture",
"attachments": {
"0": {
"name": "screen=capture-0001.png",
"contentType": "image/png",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
}
}
}
Create Message Thread (v1.0.1)
Representation used to create a new message thread.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
topicName | string (required) The name of this thread's topic. This must be the name of one of the topics from getMessageTopics .
minLength: 4
maxLength: 24
pattern: ^[a-z][a-zA-Z0-9]{3,23}$
|
contextUri | string(uri) The optional URI of a resource that this thread pertains to. This must be a URI within the deployed Apiture system (the hostname must match the services' API host, such as https://api.thirdpartybank.apiture.com/ )
maxLength: 2048
|
contextType | string An identifier which indicates the type of resource referenced by the contextUri .
maxLength: 40
pattern: ^[a-z][a-zA-Z0-9]{3,39}$
|
applicationPlatform | applicationPlatform An optional name of the client application platform. The client should set this when creating a message with the topicName of technicalAssistance or inquiry .
|
subject | string An optional subject (title) for this thread. maxLength: 80
|
assignedOperator | string The ID of an financial institution operator that this thread is assigned to. This is set via the assignMessageThread operation
minLength: 4
maxLength: 48
|
userId | string The _id of the user (Users API) associated with this thread. This is inferred when a customer user creates a message thread. A financial institution operator can set this to start a new message thread for a specific customer user.
minLength: 16
maxLength: 48
|
message | createMessage (required) The contents of the first message in the thread. |
error
{
"_id": "2eae46e1575c0a7b0115a4b3",
"message": "Descriptive error message...",
"statusCode": 422,
"type": "errorType1",
"remediation": "Remediation string...",
"occurredAt": "2018-01-25T05:50:52.375Z",
"errors": [
{
"_id": "ccdbe2c5c938a230667b3827",
"message": "An optional embedded error"
},
{
"_id": "dbe9088dcfe2460f229338a3",
"message": "Another optional embedded error"
}
],
"_links": {
"describedby": {
"href": "https://developer.apiture.com/errors/errorType1"
}
}
}
Error (v2.1.0)
Describes an error in an API request or in a service called via the API.
This schema was resolved from common/error
.
Properties
Name | Description |
---|---|
message | string (required) A localized message string describing the error condition. |
_id | string A unique identifier for this error instance. This may be used as a correlation ID with the root cause error (i.e. this ID may be logged at the source of the error). This is is an opaque string. read-only
|
statusCode | integer The HTTP status code associate with this error. minimum: 100
maximum: 599
|
type | string An error identifier which indicates the category of error and associate it with API support documentation or which the UI tier can use to render an appropriate message or hint. This provides a finer level of granularity than the statusCode . For example, instead of just 400 Bad Request, the type may be much more specific. such as integerValueNotInAllowedRange or numericValueExceedsMaximum or stringValueNotInAllowedSet .
|
occurredAt | string(date-time) An RFC 3339 UTC time stamp indicating when the error occurred. |
attributes | attributes Informative values or constraints which describe the error. For example, for a value out of range error, the attributes may specify the minimum and maximum values. This allows clients to present error messages as they see fit (the API does not assume the client/presentation tier). The set of attributes varies by error type .
|
remediation | string An optional localized string which provides hints for how the user or client can resolve the error. |
errors | [error] An optional array of nested error objects. This property is not always present. |
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
errorResponse
{
"_profile": "https://production.api.apiture.com/schemas/common/errorResponse/v2.1.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/apiName/resourceName/resourceId"
}
},
"_error": {
"_id": "2eae46e1-575c-4d69-8a8f-0a7b0115a4b3",
"message": "Description of the error will appear here.",
"statusCode": 422,
"type": "specificErrorType",
"attributes": {
"value": "Optional attribute describing the error"
},
"remediation": "Optional instructions to remediate the error may appear here.",
"occurredAt": "2018-01-25T05:50:52.375Z",
"_links": {
"describedby": {
"href": "https://production.api.apiture.com/errors/specificErrorType"
}
},
"_embedded": {
"errors": {}
}
}
}
Error Response (v2.1.0)
Describes an error response, typically returned on 4xx or 5xx errors from API operations. The _error
object contains the error details.
This schema was resolved from common/errorResponse
.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
link
{
"href": "https://api.devbank.apiture.com/applications/application/328f6bf6-d762-422f-a077-ab91ca4d0b6f",
"title": "Application"
}
Link (v1.0.0)
Describes a hypermedia link within a _links
object in HAL representations. In Apiture APIs, links are HAL links, but Apiture APIs do not use the name
or hreflang
properties of HAL. Apiture links may include a method
property.
This schema was resolved from common/link
.
Properties
Name | Description |
---|---|
href | string(uri) (required) The URI or URI template for the resource/operation this link refers to. |
type | string The media type for the resource. |
templated | boolean If true, the link's href is a URI template. |
title | string An optional human-readable localized title for the link. |
deprecation | string(uri) If present, the containing link is deprecated and the value is a URI which provides human-readable text information about the deprecation. |
profile | string(uri) The URI of a profile document, a JSON document which describes the target resource/operation. |
links
{
"property1": {
"href": "https://api.devbank.apiture.com/applications/application/328f6bf6-d762-422f-a077-ab91ca4d0b6f",
"title": "Application"
},
"property2": {
"href": "https://api.devbank.apiture.com/applications/application/328f6bf6-d762-422f-a077-ab91ca4d0b6f",
"title": "Application"
}
}
Links (v1.0.0)
An optional map of links, mapping each link relation to a link object. This model defines the _links
object of HAL representations.
This schema was resolved from common/links
.
Properties
Name | Description |
---|---|
additionalProperties | link Describes a hypermedia link within a _links object in HAL representations. In Apiture APIs, links are HAL links, but Apiture APIs do not use the name or hreflang properties of HAL. Apiture links may include a method property. This schema was resolved from |
message
{
"_profile": "https://production.api.apiture.com/schemas/messages/message/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/1a4eaf05-2d8e"
},
"apiture:markAsRead": {
"href": "https://api.devbank.apiture.com/messages/readMessages?message=1a4eaf05-2d8e"
},
"apiture:markAsUnread": {
"href": "https://api.devbank.apiture.com/messages/unreadMessages?message=1a4eaf05-2d8e"
},
"apiture:messageThread": {
"href": "https://api.devbank.apiture.com/messages/messagesThreads/866bd544-18ad"
}
},
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e",
"readState": false,
"authorType": "customer",
"createdBy": "x66677ca3-cffc",
"updatedAt": "2021-02-17T13:04:53.375Z",
"createdAt": "2021-02-17T13:04:59.375Z",
"_embedded": {}
}
Message (v1.0.0)
Representation of a message resource.
Links
Response and request bodies using this message
schema may contain the following links:
Rel | Summary | Method |
---|---|---|
self | Fetch a representation of this message | GET |
apiture:messageThread | Fetch a representation of this message thread | GET |
apiture:markAsRead | Mark as message as read. | POST |
apiture:markAsUnread | Mark as message as unread. | POST |
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
body | string The plain text body of the message. This may contain URLs. Line breaks are preserved. While the text might contain HTML or other special markup characters, these characters are not escaped. Clients must not interpret such HTML when displaying the body text. minLength: 2
maxLength: 2000
|
attachments | [messageAttachment] Optional documents attached to this message. The financial institution might configure the maximum number of attachments to be less than 5. maxItems: 5
|
operatorSignature | string The financial institution operator's name or other signature information. This is plain text and human readable, intended for the customer user. It is not the operator ID or operator username or email address. Note: This property is ignored when a customer user creates a message. minLength: 2
maxLength: 24
|
_id | string The unique identifier for this message resource. This is an immutable opaque string. read-only
|
readState | boolean Indicates if the recipient has read the message or not (or if they have marked it unread). Toggle this with the markAsRead and markAsUnread operations which are available via the links, apiture:markAsRead and apiture:markAsUnread .
read-only
|
createdBy | string Indicates who created the message. This the _id user or operator who created the message.
read-only
minLength: 16
maxLength: 48
|
authorType | messageAuthorType Indicates whether the message originated with the customer or a financial institution operator. read-only
|
updatedAt | string(date-time) The RFC 3339 UTC date-time when the message was updated. read-only
|
createdAt | string(date-time) The RFC 3339 UTC date-time when the message was created. read-only
|
messageAttachment
{
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
messageAttachment (v1.0.0)
A file attached to a message.
Properties
Name | Description |
---|---|
name | string The file name (excluding any path or URL prefix). minLength: 6
maxLength: 64
|
contentType | string The media type for this attachment. minLength: 6
maxLength: 64
|
uri | string(uri) (required) The document URI. The content at this URI must be a file content URI from the Vault API. maxLength: 2048
|
messageAuthorType
"customer"
Message Author Type (v1.0.0)
Indicates the type of user who created the message, and by inference, who the message recipient is. If the author is customer
, then the recipient is the operator
; if the author is operator
, then the recipient is the customer
.
messageAuthorType
strings may have one of the following enumerated values:
Value | Description |
---|---|
customer | Customer: This message was written by the customer |
operator | Operator: This message was written by a financial institution operator. |
Type: string
Enumerated values: customer
operator
messageThread
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d"
},
"apiture:messages": {
"href": "https://api.devbank.apiture.com/messages/message?messageThread=0399abed-fd3d"
},
"apiture:reply": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/0399abed-fd3d/replies"
},
"apiture:close": {
"href": "https://api.devbank.apiture.com/messages/closedMessageThreads?messageThread=0399abed-fd3d"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "0399abed-fd3d",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0,
"createdAt": "2021-02-17T13:04:05.375Z",
"_embedded": {}
}
Message Thread (v1.0.0)
Representation of a message thread resource.
Links
Response and request bodies using this messageThread
schema may contain the following links:
Rel | Summary | Method |
---|---|---|
self | Fetch a representation of this message thread | GET |
apiture:messages | Return a collection of messages | GET |
apiture:reply | Create a new message in this thread. | POST |
apiture:open | Open a message thread | POST |
apiture:close | Close a message thread | POST |
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
topicName | string The name of this thread's topic. This must be the name of one of the topics from getMessageTopics .
minLength: 4
maxLength: 24
pattern: ^[a-z][a-zA-Z0-9]{3,23}$
|
contextUri | string(uri) The optional URI of a resource that this thread pertains to. This must be a URI within the deployed Apiture system (the hostname must match the services' API host, such as https://api.thirdpartybank.apiture.com/ )
maxLength: 2048
|
contextType | string An identifier which indicates the type of resource referenced by the contextUri .
maxLength: 40
pattern: ^[a-z][a-zA-Z0-9]{3,39}$
|
applicationPlatform | applicationPlatform An optional name of the client application platform. The client should set this when creating a message with the topicName of technicalAssistance or inquiry .
|
subject | string An optional subject (title) for this thread. maxLength: 80
|
assignedOperator | string The ID of an financial institution operator that this thread is assigned to. This is set via the assignMessageThread operation
minLength: 4
maxLength: 48
|
userId | string The _id of the user (Users API) associated with this thread. This is inferred when a customer user creates a message thread. A financial institution operator can set this to start a new message thread for a specific customer user.
minLength: 16
maxLength: 48
|
_id | string The unique identifier for this message thread resource. This is an immutable opaque string. read-only
|
state | messageThreadState The open/closed state of the thread. This is changed by the openMessageThread or closeMessageThread operations.
read-only
|
unreadOperatorMessageCount | integer The number of unread messages sent by an operator. This is changed when the operator reads a unread message sent to the operator or marks a read message as unread .
read-only
maximum: 100
|
unreadCustomerMessageCount | integer The number of unread messages sent by the customer. This is changed when the customer reads a unread message sent to the customer or marks a read message as unread .
read-only
maximum: 100
|
createdAt | string(date-time) The RFC 3339 UTC date-time when the message was created. read-only
|
messageThreadState
"open"
Message Thread State (v1.0.0)
The state of the entire message thread.
messageThreadState
strings may have one of the following enumerated values:
Value | Description |
---|---|
open | Open: An active message thread. The customer normally only views open threads in their message user experience. |
closed | Closed: An message that the customer or the financial institution has closed. The financial institution can reopen closed threads. |
Type: string
Enumerated values: open
closed
messageThreads
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageThreads/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads?start=10&limit=10"
},
"first": {
"href": "https://api.devbank.apiture.com/messages/messageThreads?start=0&limit=10"
},
"next": {
"href": "https://api.devbank.apiture.com/messages/messageThreads?start=20&limit=10"
},
"collection": {
"href": "https://api.devbank.apiture.com/messages/messageThreads"
}
},
"name": "messageThreads",
"start": 10,
"limit": 10,
"count": 67,
"_embedded": {
"items": {
"0": {
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_profile": "https://production.api.apiture.com/schemas/messages/summaryMessageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "/messages/messageThreads/0399abed-fd3d-4830-a88b-30f38b8a365c"
}
}
}
}
}
}
Message Thread Collection (v1.0.0)
Collection of message threads. The items in the collection are ordered in the _embedded.items
array; the name
is messageThreads
. The top-level _links
object may contain pagination links (self
, next
, prev
, first
, last
, collection
).
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object Embedded objects. |
» items | [summaryMessageThread] An array containing a page of message thread items. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
count | integer The number of items in the collection. This value is optional and may be omitted if the count is not computable efficiently. If a filter is applied to the collection (either implicitly or explicitly), the count, if present, indicates the number of items that satisfy the filter. |
start | integer The start index of this page of items. |
limit | integer The maximum number of items per page. |
name | string The name of the collection. |
messageTopic
{
"name": "cardServices",
"label": "Card Services"
}
Message Topic (v1.0.0)
Representation of a message topic.
Properties
Name | Description |
---|---|
name | string The topic's name; a unique immutable identifier. minLength: 4
maxLength: 24
pattern: ^[a-z][a-zA-Z0-9]{3,23}$
|
label | string The human-readable label for this topic minLength: 4
maxLength: 24
|
messageTopics
{
"_profile": "https://production.api.apiture.com/schemas/messages/messageTopics/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/apiName/resourceName/resourceId"
}
},
"topics": {
"0": {
"name": "accountsAndApplications",
"label": "Accounts and Applications"
},
"1": {
"name": "cardServices",
"label": "Card Services"
},
"2": {
"name": "technicalAssistance",
"label": "Technical Assistance"
},
"3": {
"name": "inquiry",
"label": "General Inquiry or Feedback"
}
}
}
Message Topic Collection (v1.0.0)
A list of message topics.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
topics | object Array of topics |
» items | [messageTopic] An array containing all message topic items. |
messages
{
"_profile": "https://production.api.apiture.com/schemas/messages/messages/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages?start=10&limit=10"
},
"first": {
"href": "https://api.devbank.apiture.com/messages/messages?start=0&limit=10"
},
"next": {
"href": "https://api.devbank.apiture.com/messages/messages?start=20&limit=10"
},
"collection": {
"href": "https://api.devbank.apiture.com/messages/messages"
}
},
"name": "messages",
"start": 10,
"limit": 10,
"count": 67,
"_embedded": {
"items": {
"0": {
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e-47a2-a168-22427cfeaa0e",
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_profile": "https://production.api.apiture.com/schemas/messages/summaryMessage/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/0399abed-fd3d-4830-a88b-30f38b8a365c"
}
}
}
}
}
}
Message Collection (v1.0.0)
Collection of messages. The items in the collection are ordered in the _embedded.items
array; the name
is messages
. The top-level _links
object may contain pagination links (self
, next
, prev
, first
, last
, collection
).
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object Embedded objects. |
» items | [summaryMessage] An array containing a page of message items. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
count | integer The number of items in the collection. This value is optional and may be omitted if the count is not computable efficiently. If a filter is applied to the collection (either implicitly or explicitly), the count, if present, indicates the number of items that satisfy the filter. |
start | integer The start index of this page of items. |
limit | integer The maximum number of items per page. |
name | string The name of the collection. |
root
{
"_profile": "https://production.api.apiture.com/schemas/common/root/v2.1.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/apiName/resourceName/resourceId"
}
},
"id": "apiName",
"name": "API name",
"apiVersion": "1.0.0"
}
API Root (v2.1.0)
A HAL response, with hypermedia _links
for the top-level resources and operations in API.
This schema was resolved from common/root
.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
_id | string This API's unique ID. read-only
|
name | string This API's name. |
apiVersion | string This API's version. |
summaryMessage
{
"_profile": "https://production.api.apiture.com/schemas/messages/summaryMessage/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messages/0399abed-fd3d-4830-a88b-30f38b8a365c"
}
},
"body": "Here is the actual invoice",
"attachments": {
"0": {
"name": "invoice-2020-10-01a.pdf",
"contentType": "application/pdf",
"uri": "https://api.devbank.apiture.com/vault/files/91c28be9-ef79-4b94-a2a0-e0aa9ddcab99/content"
}
},
"_id": "0399abed-fd3d-4830-a88b-30f38b8a365c",
"threadId": "1a4eaf05-2d8e-47a2-a168-22427cfeaa0e",
"readState": false,
"authorType": "customer",
"createdBy": "x66677ca3-cffc"
}
Message Summary (v1.0.0)
Summary representation of a message resource in messages collections. This representation normally does not contain any _embedded
objects. If needed, call the GET
operation on the item's self
link to get _embedded
objects.
Links
Response and request bodies using this summaryMessage
schema may contain the following links:
Rel | Summary | Method |
---|---|---|
self | Fetch a representation of this message | GET |
apiture:messageThread | Fetch a representation of this message thread | GET |
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
body | string The plain text body of the message. This may contain URLs. Line breaks are preserved. While the text might contain HTML or other special markup characters, these characters are not escaped. Clients must not interpret such HTML when displaying the body text. minLength: 2
maxLength: 2000
|
attachments | [messageAttachment] Optional documents attached to this message. The financial institution might configure the maximum number of attachments to be less than 5. maxItems: 5
|
operatorSignature | string The financial institution operator's name or other signature information. This is plain text and human readable, intended for the customer user. It is not the operator ID or operator username or email address. Note: This property is ignored when a customer user creates a message. minLength: 2
maxLength: 24
|
_id | string The unique identifier for this message resource. This is an immutable opaque string. read-only
|
readState | boolean Indicates if the recipient has read the message or not (or if they have marked it unread). Toggle this with the markAsRead and markAsUnread operations which are available via the links, apiture:markAsRead and apiture:markAsUnread .
read-only
|
createdBy | string Indicates who created the message. This the _id user or operator who created the message.
read-only
minLength: 16
maxLength: 48
|
authorType | messageAuthorType Indicates whether the message originated with the customer or a financial institution operator. read-only
|
summaryMessageThread
{
"_profile": "https://production.api.apiture.com/schemas/messages/summaryMessageThread/v1.0.0/profile.json",
"_links": {
"self": {
"href": "https://api.devbank.apiture.com/messages/messageThreads/b171c313-0264"
}
},
"topicName": "cardServices",
"contextUri": "https://api.devbank.apiture.com/cards/cards/2c4b530a-ecea-4d7b-a543-9a4995869a2e",
"contextType": "card",
"userId": "674ae8f4-097e-4a45-85a0-a331ce7be2da",
"operatorSignature": "Mark S.",
"assignedOperator": "95c943aa-bd7f-4ae0-a8f9-42ba3b4feb5d",
"subject": "Please unlock my debit card",
"_id": "b171c313-0264",
"unreadOperatorMessageCount": 1,
"unreadCustomerMessageCount": 0
}
Message Thread Summary (v1.0.0)
Summary representation of a message thread resource in message threads collections. This representation normally does not contain any _embedded
objects. If needed, call the GET
operation on the item's self
link to get _embedded
objects.
Properties
Name | Description |
---|---|
_links | links An optional map of links, mapping each link relation to a link object. This model defines the _links object of HAL representations. This schema was resolved from |
_embedded | object An optional map of nested resources, mapping each nested resource name to a nested resource representation. |
_profile | string(uri) The URI of a resource profile which describes the representation. read-only
|
_error | error An object which describes an error. This value is omitted if the operation succeeded without error. read-only
|
topicName | string The name of this thread's topic. This must be the name of one of the topics from getMessageTopics .
minLength: 4
maxLength: 24
pattern: ^[a-z][a-zA-Z0-9]{3,23}$
|
contextUri | string(uri) The optional URI of a resource that this thread pertains to. This must be a URI within the deployed Apiture system (the hostname must match the services' API host, such as https://api.thirdpartybank.apiture.com/ )
maxLength: 2048
|
contextType | string An identifier which indicates the type of resource referenced by the contextUri .
maxLength: 40
pattern: ^[a-z][a-zA-Z0-9]{3,39}$
|
applicationPlatform | applicationPlatform An optional name of the client application platform. The client should set this when creating a message with the topicName of technicalAssistance or inquiry .
|
subject | string An optional subject (title) for this thread. maxLength: 80
|
assignedOperator | string The ID of an financial institution operator that this thread is assigned to. This is set via the assignMessageThread operation
minLength: 4
maxLength: 48
|
userId | string The _id of the user (Users API) associated with this thread. This is inferred when a customer user creates a message thread. A financial institution operator can set this to start a new message thread for a specific customer user.
minLength: 16
maxLength: 48
|
_id | string The unique identifier for this message thread resource. This is an immutable opaque string. read-only
|
state | messageThreadState The open/closed state of the thread. This is changed by the openMessageThread or closeMessageThread operations.
read-only
|
unreadOperatorMessageCount | integer The number of unread messages sent by an operator. This is changed when the operator reads a unread message sent to the operator or marks a read message as unread .
read-only
maximum: 100
|
unreadCustomerMessageCount | integer The number of unread messages sent by the customer. This is changed when the customer reads a unread message sent to the customer or marks a read message as unread .
read-only
maximum: 100
|