NAV Navbar
Shell HTTP JavaScript Node.JS Ruby Python Java Go

Introduction

Last Updated: September 22, 2021

The Urjanet API allows you to interact programmatically with the Urjanet Utility Data Platform. Through this REST API you can perform a variety of actions, from requesting utility data from providers to managing your users and organization.

This document refers to a few different personas:

Base URL: https://api.urjanet.com

Rate Limiting

The Urjanet API's rate limits are the following:

API Rate Limits

Sandbox API Rate Limits

Error Responses

Error responses are served with a non-200-series HTTP code. Usually a JSON response will be attached, but some errors will respond with different kinds of body. In these circumstances where a response structure cannot be parsed, consider the HTTP code’s core meaning to take precedence. For instance, you may occasionally see a HTTP 404 along with a HTML response. In this case, it’s safe to assume that the content cannot be found (HTTP 404 means “Not Found”).

HTTP Status Codes and Messages

Code Text Description Troubleshooting tips
200 OK The request was successful!
304 Not Modified There was no new data to return.
400 Bad Request The request was invalid or cannot be otherwise served. An accompanying error message will explain further. Double check the format of your JSON request body.
401 Unauthorized There was a problem authenticating your request. This could be due to missing or incorrect authentication credentials. This may also be returned in other undefined circumstances. Check that you are using the correct authentication method and that your credentials are correct.
403 Forbidden The request is understood, but it has been refused or access is not allowed. An accompanying error message will explain why. Check that your account has the necessary permission to perform the operation.
404 Not Found The URI requested is invalid or the resource requested, such as an account or provider, does not exist. Check that you are using valid parameters and the correct URI for the endpoint you’re using.
406 Not Acceptable Returned when an invalid format is specified in the request. Generally, this occurs where your client fails to properly include the headers to accept the response type. Check that you are correctly passing expected query parameters, including expected headers, in your request.
409 Conflict Returned when the resource cannot be modified in the requested way as it would conflict with another resource. Usually this occurs when trying to name a resource with a name that is already in use, or when trying to delete a resource which is linked via other resources.
410 Gone This resource is gone. Used to indicate that an API endpoint has been turned off.
422 Unprocessable Entity Returned when the data is unable to be processed. Check that the data you are sending in your request is valid. For example, this data could be the JSON body of your request or an image.
429 Too Many Requests Returned when a request cannot be served due to the App's rate limit having been exhausted for the resource. See Rate Limiting. Check the number of requests per timeframe allowed with the endpoint you’re using. Wait for the timeframe to reset. Space out your requests to ensure you don’t hit rate limits.
500 Internal Server Error Something is broken. This is usually a temporary error, for example in a high load situation or if an endpoint is temporarily having issues. Check the Urjanet Status Page or simply wait and try again later.
502 Bad Gateway Urjanet API is down, or being upgraded Check the Urjanet Status Page or simply wait and try again later.
503 Service Unavailable The Urjanet servers are up, but overloaded with requests. Try again later. Check the Urjanet Status Page or simply wait and try again later.
504 Gateway Timeout The Urjanet servers are up, but the request couldn’t be serviced due to some failure within the internal stack. Try again later. Check the Urjanet Status Page or simply wait and try again later.

When an error occurs during a request, detailed information about the error is returned in the response body to aid in diagnosing the problem.

{
    "error": "Entity Not Found",
    "message": [
        "No UtilityProvider found at 8888888"
    ],
    "path": "/api/public/v1/identity/providers/8888888",
    "status": 404,
    "timestamp": 1632319685942
}

Response Details

On-Demand Data Webhooks

Webhook Response

{
   "requestUri":"https://api.urjanet.com/credit/requests/3579",
   "correlationId":"test-urjanet-test2018",
   "completionStatus":"SUCCESS",
   "completionStatusDetail":"MULTIPLE_ACCOUNTS_ON_SITE"
}

Urjanet can send webhook events that notify you whenever there is a significant status update to a data request. This includes notification when data is ready for download or when a login failure occurs.

When an update occurs, Urjanet sends an event containing the new status via an HTTP POST to the webhookUrl specified on the data request. Urjanet expects a 2XX response from your server to indicate that you received the response. If we do not receive a 2XX response or are unable to deliver it for any other reason, we will attempt to resend the webhook every hour for up to seven days.

See below for a complete list of statuses

Completion Status Completion Status Detail Description
SUCCESS null Successfully found and delivered statements
SUCCESS NO_STATEMENTS_IN_PERIOD Credentials were valid, but no statements were found in the given date range
SUCCESS MULTIPLE_ACCOUNTS_ON_SITE Credentials were valid, multiple accounts are available on the site. Statements for multiple accounts will be returned
PENDING RETRYING_UNTIL_EXPIRATION When a request errors out with GENERAL_FAILURE, we retry it until it succeeds or expires
FAILURE ACCOUNT_NOT_FOUND Credentials were valid, but no statements were found with the given account number
FAILURE CREDENTIALS_INVALID Confirmed login failure
FAILURE MISSING_REQUIRED_PARAMETER Additional parameters are required to complete the request. The supplied credentials most likely have extra security requiring password2
FAILURE MISSING_REQUIRED_DATA The utility company failed to provide critical data for this account
FAILURE MULTI_FACTOR_AUTH_FAILURE Confirmed login failure due to unsupported multi factor authentication
FAILURE MULTI_FACTOR_AUTH_TIMEOUT User input for MFA response was not provided soon enough, so the navigation timed out.
FAILURE UNSUPPORTED_ACCOUNT_PREPAID Account not supported due to prepaid status
FAILURE UNSUPPORTED_CAPTCHA We encountered an unsupported captcha
FAILURE USER_ACTION_REQUIRED Some form of input is required that Urjanet cannot perform on behalf of the owner
FAILURE WEBSITE_DOWN The website is currently down for maintenance. The customer can resubmit the job at a later time when the website is up.
FAILURE LIMITED_ACCESS Credentials were valid, but user does not have access to billing data
FAILURE GENERAL_FAILURE Covers all other failures outside those described above
FAILURE PROVIDER_NOT_CURRENTLY_SUPPORTED Provider was marked as unsupported after request was submitted
FAILURE LOGIN_ATTEMPTS_EXCEEDED User has exceeded the maximum number of login attempts allowed. Try again later.
TIMEOUT null Request did not complete within the given timeout (Deprecated; may be present in older data)
CANCELLED null Request was successfully submitted but later cancelled by the user

Recurring Data Webhooks

Webhook Response

{
   "eventType": "RECURRING_REQUEST_COMPLETE",
   "created": "2021-02-05T16:32:16+00:00",
   "subject": "CREDENTIAL",
   "entityId":"https://api.urjanet.com/apautomation/credentials/3579",
   "correlationId":"test-urjanet-test2018",
   "status":"OK",
   "statusDetail":"NO_ACTION_REQUIRED"
}

Urjanet can also send webhook events for any notable events for recurring requests. For example, this could include if a new statement is available or we notice a credential is now resulting in login failure.

To specify the webhook URI that you would like the events to be POSTed to, you can update it in the Urjanet Console from the Configurations tab on the My Account page.

When sending a webhook, Urjanet looks for a 2xx response. If such a response is not received, it will be assumed that the webhook failed to deliver and the Urjanet platform will continue to send the webhook response 4 times every 6 hours for a total of 1 day. Urjanet assumes the webhook failed to deliver if there isn’t a 2xx response.

See below for a complete list of statuses:

Event Types

Event Type Subject Types Description
RECURRING_REQUEST_COMPLETE ACCOUNT / CREDENTIAL This event is sent when an attempted extraction is completed for an account or credential.
STATUS_CHANGE ACCOUNT / CREDENTIAL This event is sent for any status changes outside of a scheduled extraction. Generally, this is because of an Urjanet employee investigating unknown issues and updating the status to reflect what the problem is. Any statuses may be sent with this event type except for PENDING (and the associated status details).
MODIFIED_STATEMENT STATEMENT Indicates that an existing statement has been updated with modified data. Generally, this is because of updates to the extraction logic that are minor enough not to affect passing data quality audits
NEW_STATEMENT STATEMENT Indicates that a new statement has been initially stored for the first time.

Credential Events

Status Status Detail Description
OK NO_ACTION_REQUIRED Login was successful and statements were extracted
PENDING WEBSITE_DOWN The website is currently down for maintenance or unreachable
PENDING STATEMENT_UNAVAILABLE Latest bill is not available on the website
PENDING NAVIGATION_FAILURE Navigation was not successful; Urjanet is working internally to fix this
PENDING UNDER_REVIEW Urjanet needs to review this credential to confirm the status
ACTION_REQUIRED UNSUPPORTED_CAPTCHA Confirmed login failure due to unsupported captcha image
ACTION_REQUIRED MULTI_FACTOR_AUTH_FAILURE Confirmed login failure due to unsupported multi factor authentication
ACTION_REQUIRED MULTI_FACTOR_AUTH_TIMEOUT This indicates that the last attempted extraction timed out while waiting for interactive user input for MFA.
ACTION_REQUIRED MULTI_FACTOR_AUTH_REFRESH_REQUIRED This is only applicable for credentials that require one-time passwords or other forms of MFA. This indicates the credential is ready to be refreshed (See example here).
ACTION_REQUIRED E_BILL_REQUIRED Requested account requires E-bill enrollment to be processed
ACTION_REQUIRED NO_ACCOUNTS_FOUND Login was successful, but no accounts were found behind this credential
ACTION_REQUIRED USER_ACTION_REQUIRED Some form of input is required that Urjanet cannot perform on behalf of the owner
ACTION_REQUIRED ACCOUNT_SETUP_REQUIRED The credentials need more setup before data can be acquired
ACTION_REQUIRED LOGIN_FAILURE Confirmed login failure
ACTION_REQUIRED SECURITY_QUESTIONS Confirmed login failure due to unspecified security question answers
ACTION_REQUIRED ACCOUNT_LOCKED Login was unsuccessful because the account has been locked
ACTION_REQUIRED LOGIN_ATTEMPTS_EXCEEDED User has exceeded the maximum number of login attempts allowed. Try again later.

Account Events

Status Status Detail Description
OK NO_ACTION_REQUIRED Login was successful and statements were extracted
PENDING STATEMENT_UNAVAILABLE Latest bill is not available on the website
PENDING EXTRACTION_FAILURE Data extraction was not successful; Urjanet is working internally to fix this
PENDING UNDER_REVIEW Urjanet needs to review this account to confirm the status
PENDING INSUFFICIENT_DATA The data available on the website is not sufficient for successful processing. This would typically resolve by the next billing cycle when the provider posts new statements.
ACCESS_ISSUE E_BILL_REQUIRED Requested account requires E-bill enrollment to be processed
ACCESS_ISSUE ACCOUNT_NUMBER_CHANGE The number for this account number has been changed by the provider
ACCESS_ISSUE INVALID_SOURCE The source type retrieved from the website cannot be processed by Urjanet
ACCESS_ISSUE UNDER_REVIEW All credentials for this account are either disabled or experiencing access issues
ACCESS_ISSUE ACCOUNT_NOT_FOUND Credentials were valid, but no statements were found with the given account number
ACCESS_ISSUE ACCOUNT_SETUP_REQUIRED The account needs more setup before data can be acquired
OLD DORMANT A new statement for this account has not posted in at least 45 days
OLD ACCOUNT_CLOSED This account is confirmed to be closed by our system

Multi Factor Authentication

MFA Challenge

{
   "requestUri":"https://api.urjanet.com/credit/requests/3579",
   "correlationId":"test-urjanet-test2018",
   "eventType": "MFA_CHALLENGE",
   "responseCode": "MFA_RESPONSE_ONE_TIME_PASS",
   "metaData": {
     "MFA_CHALLENGE_CODE_METHOD": "XXX-XXXX-2434"
   }
}

MFA Challenge Response

{
   "responseCode": "MFA_RESPONSE_ONE_TIME_PASS",
   "value": "12345"
}

Login Success

{
   "requestUri":"https://api.urjanet.com/credit/requests/3579",
   "correlationId":"test-urjanet-test2018",
   "eventType": "LOGIN_SUCCESS"
}

Some utility providers may require multi-factor authentication (MFA) to sign in to the website before being able to extract data. These providers are flagged in our system with the hasMultiFactorAuthentication boolean (see here). To support this workflow, our system can send out webhook callbacks while the data extraction is running, and pause for asynchronous user input before continuing. It will also send along any useful metadata for responding to the challenge if available. These are expanded upon below. Each step that is blocked by user action will wait for approximately 2 minutes before timing out.

After receiving an MFA_CHALLENGE request, your system needs to respond with the user input to the challengeResponse endpoint (see here for example). The message body will contain the input value as well as the challenge type that it corresponds to (example on the right). Webhooks will also be sent once the navigation has completed logging in - whether that failed or succeeded. This can be used to mark the end of any necessary user input, and we will continue on to extract any data we find.

To indicate that your system is set up to integrate with this workflow, there is an optional interactive boolean flag when submitting new requests. If this is set to true, then a webhookUrl is required and the system will attempt to handle MFA as described. If the request is not marked as interactive and the extraction encounters an MFA challenge, it will exit immediately and, if possible, not trigger any code to be sent via text, email, etc.

Event Type Description
MFA_CHALLENGE This event indicates that an MFA challenge has been encountered, and we are waiting on user input to continue. See below for possible challenges and descriptions of each.
LOGIN_SUCCESS This event signifies that login was successful, and no further user input is required.
LOGIN_FAILURE This event signifies that login has failed, and no further user input is required.
Response Code Description
MFA_RESPONSE_ONE_TIME_PASS A one time password or PIN is required from the user. This was likely texted or e-mailed to them.
MFA_RESPONSE_CODE_METHOD The user must select the communication method they prefer for receiving the one time pass code.
MFA_RESPONSE_SECURITY_ANSWER The user must provide the answer for the corresponding security question provided as metadata.
MFA_RESPONSE_CAPTCHA_ANSWER The user must provider the correct value for the corresponding CAPTCHA image.
MFA_RESPONSE_MOBILE_NOTIFICATION This represents that a user must verify access through an external application (e.g. mobile app notification). No direct response is required; the user just needs to interact through that external app.
MFA_RESPONSE_PASS_CODE The user must offer a pass code that has already been set up with the utility provider (e.g. similar to a PIN)
Metadata Key Description
MFA_CHALLENGE_CODE_METHOD If known, this will specify the method that a one time pass code should have been sent to
MFA_CHALLENGE_CODE_METHOD_OPTIONS An array of possible methods for communicating a one time pass code - the user must select which option to use
MFA_CHALLENGE_SECURITY_QUESTION This is the question that a user must answer to verify access
MFA_CHALLENGE_CAPTCHA_IMAGE This is the BASE-64 encoded String for the CAPTCHA image that the user must answer

Credential Validation

Each solution has an endpoint which will validate credentials in less than 45 seconds. For a submission to be accepted, the provider must 1) support the specific solution (i.e. Solar, Credit, Identity, AP Automation) and 2) support credential validation.

Credential validation is enabled on a provider-wise basis. This feature's status can be seen in the supportsCredentialValidation field on the Provider object.

The responses returned via the credential validation endpoints are listed below:

Status Status Detail Description
SUCCESS null Credentials have been successfully identified as valid
TIMEOUT null We were not able to confirm the validity of credentials within the 45 second window
FAILURE CREDENTIALS_INVALID Credentials have been identified as invalid
FAILURE UNSUPPORTED_CAPTCHA Website requires a captcha to login
FAILURE WEBSITE_DOWN Provider website is down
FAILURE GENERAL_FAILURE Covers all other failures outside those described above

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

Authentication

Users must be authenticated before they can interact with the Urjanet API.

Authentication is performed by submitting your credentials via an HTTP POST request to the login endpoint. This returns a JWT-encoded bearer token, which you then submit in the header of any subsequent request.

All requests must be made over HTTPS.

Login

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/auth/login \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json'

POST https://api.urjanet.com/auth/login HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'

};

$.ajax({
  url: 'https://api.urjanet.com/auth/login',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "username": "string",
  "password": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json'

};

fetch('https://api.urjanet.com/auth/login',
{
  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'
}

result = RestClient.post 'https://api.urjanet.com/auth/login',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json'
}

r = requests.post('https://api.urjanet.com/auth/login', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/auth/login");
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"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/auth/login", data)
    req.Header = headers

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

POST /auth/login

Exchange username and password for a JWT token

Body parameter

{
  "username": "string",
  "password": "string"
}

Parameters

Parameter In Type Required Description
username body string false Your username to access Urjanet services
password body string false Your password to access Urjanet services

Example responses

200 Response

{
  "expires": "string",
  "message": "string",
  "status": 0,
  "token": "string"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK AuthUserResponse
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse

Credit and Lending

The Credit & Lending API is designed to leverage utility data for credit risk assessment. The data Urjanet collects is formatted here to show the full transaction history for a given customer.

List Providers

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/providers \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/providers HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/providers',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/providers',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/providers',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/providers', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/providers");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/providers", data)
    req.Header = headers

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

GET /credit/providers

Search for a list of utility providers

Providers are the utility companies that Urjanet supports. You will query the list for your end users or select a specific provider to submit a data request.

Parameters

Parameter In Type Required Description
search query string false An RSQL query string. See here for examples. Searchable fields are listed here.

Example responses

200 Response

{
  "_embedded": {
    "providers": [
      {
        "_links": {
          "serviceTypes": "string",
          "parentProvider": "string",
          "self": "string"
        },
        "providerName": "string",
        "hasMultiFactorAuthentication": true,
        "requiredFields": [
          "string"
        ],
        "requiredFieldMetadata": [
          {
            "fieldName": "string",
            "fieldLabel": "string",
            "fieldNumber": 0,
            "fieldPart": 0,
            "fieldLength": 0
          }
        ],
        "supportsCredentialValidation": true,
        "country": "string",
        "enabledSolutions": [
          "CREDIT"
        ],
        "serviceTypes": [
          "string"
        ],
        "providerId": "string",
        "website": "string",
        "hasPrepaid": true,
        "hasPostpaid": true,
        "mock": true,
        "beta": true
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedPublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Provider

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/providers/{providerId} \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/providers/{providerId} HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/providers/{providerId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/providers/{providerId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/providers/{providerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/providers/{providerId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/providers/{providerId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/providers/{providerId}", data)
    req.Header = headers

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

GET /credit/providers/{providerId}

Retrieve the details of a specific provider

Parameters

Parameter In Type Required Description
providerId path string true providerId

Example responses

200 Response

{
  "_links": {
    "serviceTypes": "string",
    "parentProvider": "string",
    "self": "string"
  },
  "providerName": "string",
  "hasMultiFactorAuthentication": true,
  "requiredFields": [
    "string"
  ],
  "requiredFieldMetadata": [
    {
      "fieldName": "string",
      "fieldLabel": "string",
      "fieldNumber": 0,
      "fieldPart": 0,
      "fieldLength": 0
    }
  ],
  "supportsCredentialValidation": true,
  "country": "string",
  "enabledSolutions": [
    "CREDIT"
  ],
  "serviceTypes": [
    "string"
  ],
  "providerId": "string",
  "website": "string",
  "hasPrepaid": true,
  "hasPostpaid": true,
  "mock": true,
  "beta": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Credential Validation

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/credit/credentials/validation \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/credit/credentials/validation HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/credentials/validation',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "providerId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/credentials/validation',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/credit/credentials/validation',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/credit/credentials/validation', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/credentials/validation");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/credit/credentials/validation", data)
    req.Header = headers

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

POST /credit/credentials/validation

Tests the credentials in real time. Returns a response in less than 45 seconds.

Body parameter

{
  "providerId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}

Parameters

Parameter In Type Required Description
providerId body string true The primary key used to represent this provider
username body string true A login input required to access the customer's utility data
username2 body string false Optional parameters required by some providers to access data. The provider object will denote which fields are required for each provider
username3 body string false See username2
username4 body string false See username2
password body string false A sensitive input required to access the customer's utility data. This will not be returned in any GET calls for the request object.
password2 body string false Optional sensitive input required by some providers to access data. The provider object will denote which fields are required for each provider. Like password, this value will not be returned in any GET calls for the request object.
password3 body string false See password2
password4 body string false See password2

Example responses

200 Response

{
  "credentialValidationStatus": "FAILURE",
  "credentialValidationStatusDetail": "CREDENTIALS_INVALID"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK CredentialValidationResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Submit Request

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/credit/requests \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/credit/requests HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "accountNumber": "string",
  "webhookUrl": "string",
  "correlationId": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "providerId": "string",
  "interactive": true,
  "timeout": 3600,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/credit/requests',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/credit/requests', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/credit/requests", data)
    req.Header = headers

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

POST /credit/requests

Create credit request

To pull utility data for a customer you submit a data request object. After submitting a data request, Urjanet will work on the request in the background. Updates to the data request will be reflected in the completionStatus.

Body parameter

{
  "accountNumber": "string",
  "webhookUrl": "string",
  "correlationId": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "providerId": "string",
  "interactive": true,
  "timeout": 3600,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}

Parameters

Parameter In Type Required Description
accountNumber body string false If provided, only data for this account will be extracted
webhookUrl body string false Urjanet will send status updates to this URL via HTTP events
correlationId body string false An ID used to match the utility data pulled for this request back to users in your system
password body string false A sensitive input required to access the customer's utility data. This will not be returned in any GET calls for the request object.
password2 body string false Optional sensitive input required by some providers to access data. The provider object will denote which fields are required for each provider. Like password, this value will not be returned in any GET calls for the request object.
password3 body string false See password2
password4 body string false See password2
periodEnd body string false End date of statements to include; formatted YYYY-MM-DD
periodStart body string false Start date of statements to include; formatted YYYY-MM-DD
providerId body string true The primary key used to represent this provider
interactive body boolean false Indicates that your system can handle a challenge-response workflow (notably MFA). See here for more details. If set to true, webhookUrl is a required field.
timeout body integer(int32) false The length of time, in seconds, which Urjanet will continue to fulfill this request
username body string true A login input required to access the customer's utility data
username2 body string false Optional parameters required by some providers to access data. The provider object will denote which fields are required for each provider
username3 body string false See username2
username4 body string false See username2

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicCreditRequestResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Requests

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/requests HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/requests', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests", data)
    req.Header = headers

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

GET /credit/requests

Search for a list of your previous submitted data requests

Click here for completion status details.

Parameters

Parameter In Type Required Description
search query string false An RSQL query string. See here for examples. Searchable fields are listed here.

Example responses

200 Response

{
  "_embedded": {
    "requests": [
      {
        "_links": {
          "cloneCredit": "string",
          "cloneSolar": "string",
          "cloneIdentity": "string",
          "consent": "string",
          "self": "string"
        },
        "accountNumber": "string",
        "providerId": "string",
        "providerName": "string",
        "webhookResult": 0,
        "webhookUrl": "string",
        "completionStatus": "SUCCESS",
        "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
        "correlationId": "string",
        "createdDate": "2021-09-27T18:43:34Z",
        "expirationDate": "2021-09-27T18:43:34Z",
        "statementCount": 0,
        "username": "string",
        "username2": "string",
        "username3": "string",
        "username4": "string",
        "periodEnd": "string",
        "periodStart": "string",
        "mock": true
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedPublicCreditRequestResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/credit/requests/downloads/consent \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/credit/requests/downloads/consent HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/downloads/consent',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "search": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/downloads/consent',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/credit/requests/downloads/consent',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/credit/requests/downloads/consent', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/downloads/consent");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/credit/requests/downloads/consent", data)
    req.Header = headers

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

POST /credit/requests/downloads/consent

Initiate a download of all CREDIT request consents for a search

Body parameter

{
  "search": "string"
}
Parameter In Type Required Description
search body string false An rsql search string

Example responses

200 Response

{
  "_links": {
    "download": "string"
  },
  "createdDate": "2021-09-27T18:43:34Z"
}

401 Response

Status Meaning Description Schema
200 OK OK PublicDownloadRequestResource
201 Created none None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Request

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/requests/{requestId} HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}", data)
    req.Header = headers

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

GET /credit/requests/{requestId}

Retrieve the details of a specific data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicCreditRequestResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

MFA Challenge

Code samples

# You can also use wget
curl -X PUT https://api.urjanet.com/credit/requests/{requestId}/challengeResponse \
  -H 'Content-Type: application/json' \
  -H 'Accept: */*' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.urjanet.com/credit/requests/{requestId}/challengeResponse HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: */*

var headers = {
  'Content-Type':'application/json',
  'Accept':'*/*',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/challengeResponse',
  method: 'put',

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

const fetch = require('node-fetch');
const inputBody = '{
  "value": "string",
  "challenge": "MFA_RESPONSE_ONE_TIME_PASS"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'*/*',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/challengeResponse',
{
  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' => '*/*',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.urjanet.com/credit/requests/{requestId}/challengeResponse',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': '*/*',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.urjanet.com/credit/requests/{requestId}/challengeResponse', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/challengeResponse");
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{"*/*"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.urjanet.com/credit/requests/{requestId}/challengeResponse", data)
    req.Header = headers

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

PUT /credit/requests/{requestId}/challengeResponse

Submit the requested MFA information provided by a user

Body parameter

{
  "value": "string",
  "challenge": "MFA_RESPONSE_ONE_TIME_PASS"
}

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
value body string false The requested value from the user for MFA input
challenge body string false The particular challenge that this value corresponds to (e.g. one time pass, security question, etc)

Enumerated Values

Parameter Value
challenge MFA_RESPONSE_ONE_TIME_PASS
challenge MFA_RESPONSE_CODE_METHOD
challenge MFA_RESPONSE_CAPTCHA_ANSWER

Example responses

401 Response

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Cancel Request

Code samples

# You can also use wget
curl -X PATCH https://api.urjanet.com/credit/requests/{requestId}/cancel \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

PATCH https://api.urjanet.com/credit/requests/{requestId}/cancel HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/cancel',
  method: 'patch',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/cancel',
{
  method: 'PATCH',

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

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.patch 'https://api.urjanet.com/credit/requests/{requestId}/cancel',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.patch('https://api.urjanet.com/credit/requests/{requestId}/cancel', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/cancel");
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{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://api.urjanet.com/credit/requests/{requestId}/cancel", data)
    req.Header = headers

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

PATCH /credit/requests/{requestId}/cancel

Cancel a previously submitted data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

OK

{
  "_links": [
    {
      "href": "string",
      "rel": "string"
    }
  ],
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "CANCELLED",
  "completionStatusDetail": null,
  "correlationId": "string",
  "createdDate": "2018-08-23T17:31:03Z",
  "expirationDate": "2018-08-23T17:31:03Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string"
}

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicCreditRequestResource
204 No Content No Content None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse

List Accounts

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId}/accounts \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/requests/{requestId}/accounts HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/accounts',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/accounts',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}/accounts',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}/accounts', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/accounts");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}/accounts", data)
    req.Header = headers

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

GET /credit/requests/{requestId}/accounts

Get a list of the account objects returned as part of a data request

An account is a single line of activity for a customer. Each data request can return one or many accounts.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "_embedded": {
    "accounts": [
      {
        "prepaid": true,
        "_links": {
          "statements": "string",
          "self": "string"
        },
        "accountNumber": "string"
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedAccountResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Account

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId} HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}", data)
    req.Header = headers

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

GET /credit/requests/{requestId}/accounts/{accountId}

Retrieve a single account object returned as part of a data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId

Example responses

200 Response

{
  "prepaid": true,
  "_links": {
    "statements": "string",
    "self": "string"
  },
  "accountNumber": "string"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK AccountResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Statements

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements", data)
    req.Header = headers

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

GET /credit/requests/{requestId}/accounts/{accountId}/statements

Get a list of the statement objects returned as part of a data request

A statement is a unique invoice for a particular account. It represents the account's activity over a specific period of time. A data request may return one or many monthly statements depending on the submitted start/end dates and the amount of data made available by the utility provider.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId

Example responses

200 Response

{
  "_embedded": {
    "statements": [
      {
        "_links": {
          "viewstatementsource": "string",
          "self": "string"
        },
        "accountNumber": "string",
        "billingAddressCity": "string",
        "billingAddressCountry": "string",
        "billingAddressName": "string",
        "billingAddressPostalCode": "string",
        "billingAddressRaw": "string",
        "billingAddressState": "string",
        "billingAddressStreet1": "string",
        "billingAddressStreet2": "string",
        "serviceAddressCity": "string",
        "serviceAddressCountry": "string",
        "serviceAddressName": "string",
        "serviceAddressPostalCode": "string",
        "serviceAddressRaw": "string",
        "serviceAddressState": "string",
        "serviceAddressStreet1": "string",
        "serviceAddressStreet2": "string",
        "currency": "string",
        "totalBill": 0,
        "balanceAdjustments": 0,
        "dueDate": "string",
        "statementDate": "string",
        "statementType": "BILL"
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedCreditStatementResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Statement Source

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source \
  -H 'Accept: */*' \
  -H 'Authorization: string'

GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source HTTP/1.1
Host: api.urjanet.com
Accept: */*
Authorization: string

var headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
  method: 'get',

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

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

const headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
{
  method: 'GET',

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

require 'rest-client'
require 'json'

headers = {
  'Accept' => '*/*',
  'Authorization' => 'string'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': '*/*',
  'Authorization': 'string'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source");
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{"*/*"},
        "Authorization": []string{"string"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source", data)
    req.Header = headers

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

GET /credit/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source

Get the source document for a specific statement. This is usually a PDF version of the actual bill.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId
statementId path integer(int64) true statementId
Authorization header string false none

Example responses

401 Response

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Response Headers

Status Header Type Format Description
200 Access-Control-Allow-Headers string none
200 Access-Control-Allow-Methods string none
200 Access-Control-Allow-Origin string none

List Payments

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments", data)
    req.Header = headers

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

GET /credit/requests/{requestId}/accounts/{accountId}/payments

Get a list of the payment objects returned as part of a data request

A payment is a transaction made by the account holder to decrease the balance of the account. A data request may return one or many payments for each account.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId

Example responses

200 Response

{
  "_embedded": {
    "payments": [
      {
        "_links": {
          "viewpaymentsource": "string",
          "self": "string"
        },
        "amount": 0,
        "paymentDate": "string",
        "currency": "string"
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedCreditPaymentResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Payment Source

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source \
  -H 'Accept: */*' \
  -H 'Authorization: string'

GET https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source HTTP/1.1
Host: api.urjanet.com
Accept: */*
Authorization: string

var headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source',
  method: 'get',

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

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

const headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source',
{
  method: 'GET',

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

require 'rest-client'
require 'json'

headers = {
  'Accept' => '*/*',
  'Authorization' => 'string'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': '*/*',
  'Authorization': 'string'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source");
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{"*/*"},
        "Authorization": []string{"string"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source", data)
    req.Header = headers

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

GET /credit/requests/{requestId}/accounts/{accountId}/payments/{paymentId}/source

Get the source document showing the details of a specific payment

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId
paymentId path integer(int64) true paymentId
Authorization header string false none

Example responses

401 Response

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Response Headers

Status Header Type Format Description
200 Access-Control-Allow-Headers string none
200 Access-Control-Allow-Methods string none
200 Access-Control-Allow-Origin string none

Submit Clone Request

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/credit/requests/{requestId}/clones \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/credit/requests/{requestId}/clones HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/clones',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "periodEnd": "string",
  "periodStart": "string",
  "webhookUrl": "string",
  "accountNumber": "string",
  "correlationId": "string",
  "timeout": 3600
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/clones',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/credit/requests/{requestId}/clones',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/credit/requests/{requestId}/clones', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/clones");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/credit/requests/{requestId}/clones", data)
    req.Header = headers

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

POST /credit/requests/{requestId}/clones

Create a copy of a previous credit request

Using a clone to create a credit request allows you to submit a new credit request without needing account credentials. See /credit/requests

Body parameter

{
  "periodEnd": "string",
  "periodStart": "string",
  "webhookUrl": "string",
  "accountNumber": "string",
  "correlationId": "string",
  "timeout": 3600
}

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
periodEnd body string false End date of statements to include; formatted YYYY-MM-DD
periodStart body string false Start date of statements to include; formatted YYYY-MM-DD
webhookUrl body string false Urjanet will send status updates to this URL via HTTP events
accountNumber body string false If provided, only data for this account will be extracted
correlationId body string false An ID used to match the utility data pulled for this request back to users in your system
timeout body integer(int32) false The length of time, in seconds, which Urjanet will continue to fulfill this request

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicCreditRequestResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/credit/requests/{requestId}/consent \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/credit/requests/{requestId}/consent HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/credit/requests/{requestId}/consent',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/credit/requests/{requestId}/consent',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/credit/requests/{requestId}/consent',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/credit/requests/{requestId}/consent', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/credit/requests/{requestId}/consent");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/credit/requests/{requestId}/consent", data)
    req.Header = headers

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

GET /credit/requests/{requestId}/consent

Get the consent data for a request

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "consentStatus": "string",
  "credentialCreatedDate": "2021-09-27T18:43:34Z",
  "lastModifiedDate": "2021-09-27T18:43:34Z",
  "origin": "API",
  "privacyPolicyUrl": "string",
  "revokeDate": "2021-09-27T18:43:34Z",
  "termsOfServiceUrl": "string"
}

401 Response

Status Meaning Description Schema
200 OK OK ConsentResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Solar

The Solar API enables accurate system sizing and ROI calculations for prospective solar buyers. Data returned here provides a full historical view of a customer's monthly usage and cost.

List Providers

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/providers \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/providers HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/providers',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/providers',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/providers',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/providers', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/providers");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/providers", data)
    req.Header = headers

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

GET /solar/providers

Search for a list of utility providers

Providers are the utility companies that Urjanet supports. You will query the list for your end users or select a specific provider to submit a data request.

Parameters

Parameter In Type Required Description
search query string false An RSQL query string. See here for examples. Searchable fields are listed here.

Example responses

200 Response

{
  "_embedded": {
    "providers": [
      {
        "_links": {
          "serviceTypes": "string",
          "parentProvider": "string",
          "self": "string"
        },
        "providerName": "string",
        "hasMultiFactorAuthentication": true,
        "requiredFields": [
          "string"
        ],
        "requiredFieldMetadata": [
          {
            "fieldName": "string",
            "fieldLabel": "string",
            "fieldNumber": 0,
            "fieldPart": 0,
            "fieldLength": 0
          }
        ],
        "supportsCredentialValidation": true,
        "country": "string",
        "enabledSolutions": [
          "CREDIT"
        ],
        "serviceTypes": [
          "string"
        ],
        "providerId": "string",
        "website": "string",
        "hasPrepaid": true,
        "hasPostpaid": true,
        "mock": true,
        "beta": true
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedPublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Provider

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/providers/{providerId} \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/providers/{providerId} HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/providers/{providerId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/providers/{providerId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/providers/{providerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/providers/{providerId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/providers/{providerId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/providers/{providerId}", data)
    req.Header = headers

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

GET /solar/providers/{providerId}

Retrieve the details of a single provider

Parameters

Parameter In Type Required Description
providerId path string true providerId

Example responses

200 Response

{
  "_links": {
    "serviceTypes": "string",
    "parentProvider": "string",
    "self": "string"
  },
  "providerName": "string",
  "hasMultiFactorAuthentication": true,
  "requiredFields": [
    "string"
  ],
  "requiredFieldMetadata": [
    {
      "fieldName": "string",
      "fieldLabel": "string",
      "fieldNumber": 0,
      "fieldPart": 0,
      "fieldLength": 0
    }
  ],
  "supportsCredentialValidation": true,
  "country": "string",
  "enabledSolutions": [
    "CREDIT"
  ],
  "serviceTypes": [
    "string"
  ],
  "providerId": "string",
  "website": "string",
  "hasPrepaid": true,
  "hasPostpaid": true,
  "mock": true,
  "beta": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Credential Validation

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/solar/credentials/validation \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/solar/credentials/validation HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/credentials/validation',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "providerId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/credentials/validation',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/solar/credentials/validation',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/solar/credentials/validation', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/credentials/validation");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/solar/credentials/validation", data)
    req.Header = headers

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

POST /solar/credentials/validation

Tests the credentials in real time. Returns a response in less than 45 seconds.

Body parameter

{
  "providerId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}

Parameters

Parameter In Type Required Description
providerId body string true The primary key used to represent this provider
username body string true A login input required to access the customer's utility data
username2 body string false Optional parameters required by some providers to access data. The provider object will denote which fields are required for each provider
username3 body string false See username2
username4 body string false See username2
password body string false A sensitive input required to access the customer's utility data. This will not be returned in any GET calls for the request object.
password2 body string false Optional sensitive input required by some providers to access data. The provider object will denote which fields are required for each provider. Like password, this value will not be returned in any GET calls for the request object.
password3 body string false See password2
password4 body string false See password2

Example responses

200 Response

{
  "credentialValidationStatus": "FAILURE",
  "credentialValidationStatusDetail": "CREDENTIALS_INVALID"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK CredentialValidationResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Submit Request

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/solar/requests \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/solar/requests HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "accountNumber": "string",
  "webhookUrl": "string",
  "correlationId": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string",
  "interactive": true,
  "periodEnd": "string",
  "periodStart": "string",
  "providerId": "string",
  "timeout": 3600,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/solar/requests',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/solar/requests', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/solar/requests", data)
    req.Header = headers

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

POST /solar/requests

Create solar request

To pull utility data for a customer you submit a data request object. After submitting a data request, Urjanet will work on the request in the background. Updates to the data request will be reflected in the completionStatus.

Body parameter

{
  "accountNumber": "string",
  "webhookUrl": "string",
  "correlationId": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string",
  "interactive": true,
  "periodEnd": "string",
  "periodStart": "string",
  "providerId": "string",
  "timeout": 3600,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}

Parameters

Parameter In Type Required Description
accountNumber body string false If provided, only data for this account will be extracted
webhookUrl body string false Urjanet will send status updates to this URL via HTTP events. See here for more information.
correlationId body string false An ID used to match the utility data pulled for this request back to users in your system
password body string false A sensitive input required to access the customer's utility data. This will not be returned in any GET calls for the request object.
password2 body string false Optional sensitive input required by some providers to access data. The provider object will denote which fields are required for each provider. Like password, this value will not be returned in any GET calls for the request object.
password3 body string false See password2
password4 body string false See password2
interactive body boolean false Indicates that your system can handle a challenge-response workflow (notably MFA). See here for more details. If set to true, webhookUrl is a required field.
periodEnd body string false End date of statements to include; formatted YYYY-MM-DD
periodStart body string false Start date of statements to include; formatted YYYY-MM-DD
providerId body string true The primary key used to represent this provider
timeout body integer(int32) false The length of time, in seconds, which Urjanet will continue to fulfill this request
username body string true A login input required to access the customer's utility data
username2 body string false Optional parameters required by some providers to access data. The provider object will denote which fields are required for each provider
username3 body string false See username2
username4 body string false See username2

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicSolarRequestResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Requests

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/requests \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/requests HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/requests',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/requests', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/requests", data)
    req.Header = headers

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

GET /solar/requests

Search for a list of your previous submitted data requests

Parameters

Parameter In Type Required Description
search query string false An RSQL query string. See here for examples. Searchable fields are listed here.

Example responses

200 Response

{
  "_embedded": {
    "requests": [
      {
        "_links": {
          "cloneCredit": "string",
          "cloneSolar": "string",
          "cloneIdentity": "string",
          "consent": "string",
          "self": "string"
        },
        "accountNumber": "string",
        "providerId": "string",
        "providerName": "string",
        "webhookResult": 0,
        "webhookUrl": "string",
        "completionStatus": "SUCCESS",
        "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
        "correlationId": "string",
        "createdDate": "2021-09-27T18:43:34Z",
        "expirationDate": "2021-09-27T18:43:34Z",
        "statementCount": 0,
        "username": "string",
        "username2": "string",
        "username3": "string",
        "username4": "string",
        "periodEnd": "string",
        "periodStart": "string",
        "mock": true
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedPublicSolarRequestResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/solar/requests/downloads/consent \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/solar/requests/downloads/consent HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/downloads/consent',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "search": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/downloads/consent',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/solar/requests/downloads/consent',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/solar/requests/downloads/consent', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/downloads/consent");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/solar/requests/downloads/consent", data)
    req.Header = headers

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

POST /solar/requests/downloads/consent

Initiate a download of all CREDIT request consents for a search

Body parameter

{
  "search": "string"
}
Parameter In Type Required Description
search body string false An rsql search string

Example responses

200 Response

{
  "_links": {
    "download": "string"
  },
  "createdDate": "2021-09-27T18:43:34Z"
}

401 Response

Status Meaning Description Schema
200 OK OK PublicDownloadRequestResource
201 Created none None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

MFA Challenge

Code samples

# You can also use wget
curl -X PUT https://api.urjanet.com/solar/requests/{requestId}/challengeResponse \
  -H 'Content-Type: application/json' \
  -H 'Accept: */*' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.urjanet.com/solar/requests/{requestId}/challengeResponse HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: */*

var headers = {
  'Content-Type':'application/json',
  'Accept':'*/*',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/challengeResponse',
  method: 'put',

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

const fetch = require('node-fetch');
const inputBody = '{
  "value": "string",
  "challenge": "MFA_RESPONSE_ONE_TIME_PASS"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'*/*',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/challengeResponse',
{
  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' => '*/*',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.urjanet.com/solar/requests/{requestId}/challengeResponse',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': '*/*',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.urjanet.com/solar/requests/{requestId}/challengeResponse', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/challengeResponse");
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{"*/*"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.urjanet.com/solar/requests/{requestId}/challengeResponse", data)
    req.Header = headers

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

PUT /solar/requests/{requestId}/challengeResponse

Submit the requested MFA information provided by a user

Body parameter

{
  "value": "string",
  "challenge": "MFA_RESPONSE_ONE_TIME_PASS"
}

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
value body string false The requested value from the user for MFA input
challenge body string false The particular challenge that this value corresponds to (e.g. one time pass, security question, etc)

Enumerated Values

Parameter Value
challenge MFA_RESPONSE_ONE_TIME_PASS
challenge MFA_RESPONSE_CODE_METHOD
challenge MFA_RESPONSE_CAPTCHA_ANSWER

Example responses

401 Response

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Cancel Solar Request

Code samples

# You can also use wget
curl -X PATCH https://api.urjanet.com/solar/requests/{requestId}/cancel \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

PATCH https://api.urjanet.com/solar/requests/{requestId}/cancel HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/cancel',
  method: 'patch',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/cancel',
{
  method: 'PATCH',

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

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.patch 'https://api.urjanet.com/solar/requests/{requestId}/cancel',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.patch('https://api.urjanet.com/solar/requests/{requestId}/cancel', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/cancel");
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{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://api.urjanet.com/solar/requests/{requestId}/cancel", data)
    req.Header = headers

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

PATCH /solar/requests/{requestId}/cancel

Cancel a previously submitted data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

OK

{
  "_links": [
    {
      "href": "string",
      "rel": "string"
    }
  ],
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "CANCELLED",
  "completionStatusDetail": null,
  "correlationId": "string",
  "createdDate": "2018-08-23T17:31:03Z",
  "expirationDate": "2018-08-23T17:31:03Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string"
}

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicSolarRequestResource
204 No Content No Content None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse

Retrieve Request

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/requests/{requestId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/requests/{requestId} HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/requests/{requestId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/requests/{requestId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/requests/{requestId}", data)
    req.Header = headers

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

GET /solar/requests/{requestId}

Retrieve the details of a specific data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicSolarRequestResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Accounts

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/requests/{requestId}/accounts \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/requests/{requestId}/accounts HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/accounts',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/accounts',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/requests/{requestId}/accounts',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/requests/{requestId}/accounts', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/accounts");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/requests/{requestId}/accounts", data)
    req.Header = headers

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

GET /solar/requests/{requestId}/accounts

Get a list of the account objects returned as part of a data request

An account is a single line of activity for a customer. Each data request can return one or many accounts.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "_embedded": {
    "accounts": [
      {
        "prepaid": true,
        "_links": {
          "statements": "string",
          "self": "string"
        },
        "accountNumber": "string"
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedAccountResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Account

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId} HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}", data)
    req.Header = headers

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

GET /solar/requests/{requestId}/accounts/{accountId}

Retrieve a single account object returned as part of a data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId

Example responses

200 Response

{
  "prepaid": true,
  "_links": {
    "statements": "string",
    "self": "string"
  },
  "accountNumber": "string"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK AccountResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Statements

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements", data)
    req.Header = headers

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

GET /solar/requests/{requestId}/accounts/{accountId}/statements

Get a list of the statement objects returned as part of a data request

A statement is a unique invoice for a particular account. It represents the account's activity over a specific period of time. A data request may return one or many monthly statements depending on the submitted start/end dates and the amount of data made available by the utility provider.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId

Example responses

200 Response

{
  "_embedded": {
    "statements": [
      {
        "_links": {
          "viewstatementsource": "string",
          "self": "string"
        },
        "billingAddressCity": "string",
        "billingAddressCountry": "string",
        "billingAddressName": "string",
        "billingAddressPostalCode": "string",
        "billingAddressRaw": "string",
        "billingAddressState": "string",
        "billingAddressStreet1": "string",
        "billingAddressStreet2": "string",
        "serviceAddressCity": "string",
        "serviceAddressCountry": "string",
        "serviceAddressName": "string",
        "serviceAddressPostalCode": "string",
        "serviceAddressRaw": "string",
        "serviceAddressState": "string",
        "serviceAddressStreet1": "string",
        "serviceAddressStreet2": "string",
        "currency": "string",
        "totalBill": 0,
        "electricCost": 0,
        "consumption": 0,
        "demand": 0,
        "tariff": "string",
        "statementMessages": "string",
        "statementIntervalStart": "string",
        "statementIntervalEnd": "string",
        "usageIntervalStart": "string",
        "usageIntervalEnd": "string",
        "statementType": "BILL"
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedSolarStatementResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Statement Source

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source \
  -H 'Accept: */*' \
  -H 'Authorization: string'

GET https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source HTTP/1.1
Host: api.urjanet.com
Accept: */*
Authorization: string

var headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
  method: 'get',

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

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

const headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
{
  method: 'GET',

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

require 'rest-client'
require 'json'

headers = {
  'Accept' => '*/*',
  'Authorization' => 'string'
}

result = RestClient.get 'https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': '*/*',
  'Authorization': 'string'
}

r = requests.get('https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source");
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{"*/*"},
        "Authorization": []string{"string"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source", data)
    req.Header = headers

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

GET /solar/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source

Get the source document for a specific statement. This is usually a PDF version of the actual bill.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId
statementId path integer(int64) true statementId
Authorization header string false none

Example responses

401 Response

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Response Headers

Status Header Type Format Description
200 Access-Control-Allow-Headers string none
200 Access-Control-Allow-Methods string none
200 Access-Control-Allow-Origin string none

Submit Clone Request

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/solar/requests/{requestId}/clones \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/solar/requests/{requestId}/clones HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/clones',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "periodEnd": "string",
  "periodStart": "string",
  "webhookUrl": "string",
  "accountNumber": "string",
  "correlationId": "string",
  "timeout": 3600
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/clones',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/solar/requests/{requestId}/clones',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/solar/requests/{requestId}/clones', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/clones");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/solar/requests/{requestId}/clones", data)
    req.Header = headers

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

POST /solar/requests/{requestId}/clones

Create a copy of a previous solar request

Using a clone to create a solar request allows you to submit a new solar request without needing account credentials. See /solar/requests

Body parameter

{
  "periodEnd": "string",
  "periodStart": "string",
  "webhookUrl": "string",
  "accountNumber": "string",
  "correlationId": "string",
  "timeout": 3600
}

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
periodEnd body string false End date of statements to include; formatted YYYY-MM-DD
periodStart body string false Start date of statements to include; formatted YYYY-MM-DD
webhookUrl body string false Urjanet will send status updates to this URL via HTTP events
accountNumber body string false If provided, only data for this account will be extracted
correlationId body string false An ID used to match the utility data pulled for this request back to users in your system
timeout body integer(int32) false The length of time, in seconds, which Urjanet will continue to fulfill this request

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "periodEnd": "string",
  "periodStart": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicSolarRequestResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/solar/requests/{requestId}/consent \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/solar/requests/{requestId}/consent HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/solar/requests/{requestId}/consent',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/solar/requests/{requestId}/consent',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/solar/requests/{requestId}/consent',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/solar/requests/{requestId}/consent', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/solar/requests/{requestId}/consent");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/solar/requests/{requestId}/consent", data)
    req.Header = headers

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

GET /solar/requests/{requestId}/consent

Get the consent data for a request

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "consentStatus": "string",
  "credentialCreatedDate": "2021-09-27T18:43:34Z",
  "lastModifiedDate": "2021-09-27T18:43:34Z",
  "origin": "API",
  "privacyPolicyUrl": "string",
  "revokeDate": "2021-09-27T18:43:34Z",
  "termsOfServiceUrl": "string"
}

401 Response

Status Meaning Description Schema
200 OK OK ConsentResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Identity Verification

The Identity API provides utility data for address verification. Data requests made here will return name and address data for the most recent utility bill.

List Providers

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/providers \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/providers HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/providers',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/providers',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/providers',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/providers', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/providers");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/providers", data)
    req.Header = headers

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

GET /identity/providers

Search for a list of utility providers

Providers are the utility companies that Urjanet supports. You will query the list for your end users or select a specific provider to submit a data request.

Parameters

Parameter In Type Required Description
search query string false An RSQL query string. See here for examples. Searchable fields are listed here.

Example responses

200 Response

{
  "_embedded": {
    "providers": [
      {
        "_links": {
          "serviceTypes": "string",
          "parentProvider": "string",
          "self": "string"
        },
        "providerName": "string",
        "hasMultiFactorAuthentication": true,
        "requiredFields": [
          "string"
        ],
        "requiredFieldMetadata": [
          {
            "fieldName": "string",
            "fieldLabel": "string",
            "fieldNumber": 0,
            "fieldPart": 0,
            "fieldLength": 0
          }
        ],
        "supportsCredentialValidation": true,
        "country": "string",
        "enabledSolutions": [
          "CREDIT"
        ],
        "serviceTypes": [
          "string"
        ],
        "providerId": "string",
        "website": "string",
        "hasPrepaid": true,
        "hasPostpaid": true,
        "mock": true,
        "beta": true
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedPublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Provider

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/providers/{providerId} \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/providers/{providerId} HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/providers/{providerId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/providers/{providerId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/providers/{providerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/providers/{providerId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/providers/{providerId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/providers/{providerId}", data)
    req.Header = headers

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

GET /identity/providers/{providerId}

Retrieve the details of a single provider

Parameters

Parameter In Type Required Description
providerId path string true providerId

Example responses

200 Response

{
  "_links": {
    "serviceTypes": "string",
    "parentProvider": "string",
    "self": "string"
  },
  "providerName": "string",
  "hasMultiFactorAuthentication": true,
  "requiredFields": [
    "string"
  ],
  "requiredFieldMetadata": [
    {
      "fieldName": "string",
      "fieldLabel": "string",
      "fieldNumber": 0,
      "fieldPart": 0,
      "fieldLength": 0
    }
  ],
  "supportsCredentialValidation": true,
  "country": "string",
  "enabledSolutions": [
    "CREDIT"
  ],
  "serviceTypes": [
    "string"
  ],
  "providerId": "string",
  "website": "string",
  "hasPrepaid": true,
  "hasPostpaid": true,
  "mock": true,
  "beta": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Credential Validation

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/identity/credentials/validation \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/identity/credentials/validation HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/credentials/validation',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "providerId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/credentials/validation',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/identity/credentials/validation',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/identity/credentials/validation', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/credentials/validation");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/identity/credentials/validation", data)
    req.Header = headers

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

POST /identity/credentials/validation

Tests the credentials in real time. Returns a response in less than 45 seconds.

Body parameter

{
  "providerId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}

Parameters

Parameter In Type Required Description
providerId body string true The primary key used to represent this provider
username body string true A login input required to access the customer's utility data
username2 body string false Optional parameters required by some providers to access data. The provider object will denote which fields are required for each provider
username3 body string false See username2
username4 body string false See username2
password body string false A sensitive input required to access the customer's utility data. This will not be returned in any GET calls for the request object.
password2 body string false Optional sensitive input required by some providers to access data. The provider object will denote which fields are required for each provider. Like password, this value will not be returned in any GET calls for the request object.
password3 body string false See password2
password4 body string false See password2

Example responses

200 Response

{
  "credentialValidationStatus": "FAILURE",
  "credentialValidationStatusDetail": "CREDENTIALS_INVALID"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK CredentialValidationResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Submit Request

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/identity/requests \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/identity/requests HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "accountNumber": "string",
  "webhookUrl": "string",
  "correlationId": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string",
  "interactive": true,
  "providerId": "string",
  "timeout": 3600,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/identity/requests',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/identity/requests', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/identity/requests", data)
    req.Header = headers

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

POST /identity/requests

Create identity request

To pull utility data for a customer you submit a data request object. After submitting a data request, Urjanet will work on the request in the background. Updates to the data request will be reflected in the completionStatus.

Body parameter

{
  "accountNumber": "string",
  "webhookUrl": "string",
  "correlationId": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string",
  "interactive": true,
  "providerId": "string",
  "timeout": 3600,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}

Parameters

Parameter In Type Required Description
accountNumber body string false If provided, only data for this account will be extracted
webhookUrl body string false Urjanet will send status updates to this URL via HTTP events. See here for more information.
correlationId body string false An ID used to match the utility data pulled for this request back to users in your system
password body string false A sensitive input required to access the customer's utility data. This will not be returned in any GET calls for the request object.
password2 body string false Optional sensitive input required by some providers to access data. The provider object will denote which fields are required for each provider. Like password, this value will not be returned in any GET calls for the request object.
password3 body string false See password2
password4 body string false See password2
interactive body boolean false Indicates that your system can handle a challenge-response workflow (notably MFA). See here for more details. If set to true, webhookUrl is a required field.
providerId body string true The primary key used to represent this provider
timeout body integer(int32) false The length of time, in seconds, which Urjanet will continue to fulfill this request
username body string true A login input required to access the customer's utility data
username2 body string false Optional parameters required by some providers to access data. The provider object will denote which fields are required for each provider
username3 body string false See username2
username4 body string false See username2

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicIdentityRequestResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Requests

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/requests \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/requests HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/requests',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/requests', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/requests", data)
    req.Header = headers

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

GET /identity/requests

Search for a list of your previous submitted data requests

Parameters

Parameter In Type Required Description
search query string false An RSQL query string. See here for examples. Searchable fields are listed here.

Example responses

200 Response

{
  "_embedded": {
    "requests": [
      {
        "_links": {
          "cloneCredit": "string",
          "cloneSolar": "string",
          "cloneIdentity": "string",
          "consent": "string",
          "self": "string"
        },
        "accountNumber": "string",
        "providerId": "string",
        "providerName": "string",
        "webhookResult": 0,
        "webhookUrl": "string",
        "completionStatus": "SUCCESS",
        "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
        "correlationId": "string",
        "createdDate": "2021-09-27T18:43:34Z",
        "expirationDate": "2021-09-27T18:43:34Z",
        "statementCount": 0,
        "username": "string",
        "username2": "string",
        "username3": "string",
        "username4": "string",
        "mock": true
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedPublicIdentityRequestResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Download Requests

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/identity/requests/downloads/consent \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/identity/requests/downloads/consent HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/downloads/consent',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "search": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/downloads/consent',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/identity/requests/downloads/consent',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/identity/requests/downloads/consent', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/downloads/consent");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/identity/requests/downloads/consent", data)
    req.Header = headers

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

POST /identity/requests/downloads/consent

Initiate a download of all CREDIT request consents for a search

Body parameter

{
  "search": "string"
}

Parameters

Parameter In Type Required Description
search body string false An rsql search string

Example responses

200 Response

{
  "_links": {
    "download": "string"
  },
  "createdDate": "2021-09-27T18:43:34Z"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicDownloadRequestResource
201 Created none None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

MFA Challenge

Code samples

# You can also use wget
curl -X PUT https://api.urjanet.com/identity/requests/{requestId}/challengeResponse \
  -H 'Content-Type: application/json' \
  -H 'Accept: */*' \
  -H 'Authorization: Bearer {access-token}'

PUT https://api.urjanet.com/identity/requests/{requestId}/challengeResponse HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: */*

var headers = {
  'Content-Type':'application/json',
  'Accept':'*/*',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/challengeResponse',
  method: 'put',

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

const fetch = require('node-fetch');
const inputBody = '{
  "value": "string",
  "challenge": "MFA_RESPONSE_ONE_TIME_PASS"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'*/*',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/challengeResponse',
{
  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' => '*/*',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.put 'https://api.urjanet.com/identity/requests/{requestId}/challengeResponse',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': '*/*',
  'Authorization': 'Bearer {access-token}'
}

r = requests.put('https://api.urjanet.com/identity/requests/{requestId}/challengeResponse', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/challengeResponse");
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{"*/*"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PUT", "https://api.urjanet.com/identity/requests/{requestId}/challengeResponse", data)
    req.Header = headers

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

PUT /identity/requests/{requestId}/challengeResponse

Submit the requested MFA information provided by a user

Body parameter

{
  "value": "string",
  "challenge": "MFA_RESPONSE_ONE_TIME_PASS"
}

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
value body string false The requested value from the user for MFA input
challenge body string false The particular challenge that this value corresponds to (e.g. one time pass, security question, etc)

Enumerated Values

Parameter Value
challenge MFA_RESPONSE_ONE_TIME_PASS
challenge MFA_RESPONSE_CODE_METHOD
challenge MFA_RESPONSE_CAPTCHA_ANSWER

Example responses

401 Response

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Cancel Identity Request

Code samples

# You can also use wget
curl -X PATCH https://api.urjanet.com/identity/requests/{requestId}/cancel \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

PATCH https://api.urjanet.com/identity/requests/{requestId}/cancel HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/cancel',
  method: 'patch',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/cancel',
{
  method: 'PATCH',

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

require 'rest-client'
require 'json'

headers = {
  'Accept' => 'application/json',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.patch 'https://api.urjanet.com/identity/requests/{requestId}/cancel',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.patch('https://api.urjanet.com/identity/requests/{requestId}/cancel', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/cancel");
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{
        "Accept": []string{"application/json"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("PATCH", "https://api.urjanet.com/identity/requests/{requestId}/cancel", data)
    req.Header = headers

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

PATCH /identity/requests/{requestId}/cancel

Cancel a previously submitted data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

OK

{
  "_links": [
    {
      "href": "string",
      "rel": "string"
    }
  ],
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "CANCELLED",
  "completionStatusDetail": null,
  "correlationId": "string",
  "createdDate": "2018-08-23T17:31:03Z",
  "expirationDate": "2018-08-23T17:31:03Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicIdentityRequestResource
204 No Content No Content None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse

Retrieve Request

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/requests/{requestId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/requests/{requestId} HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/requests/{requestId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/requests/{requestId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/requests/{requestId}", data)
    req.Header = headers

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

GET /identity/requests/{requestId}

Retrieve the details of a specific data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicIdentityRequestResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Accounts

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/requests/{requestId}/accounts \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/requests/{requestId}/accounts HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/accounts',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/accounts',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/requests/{requestId}/accounts',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/requests/{requestId}/accounts', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/accounts");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/requests/{requestId}/accounts", data)
    req.Header = headers

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

GET /identity/requests/{requestId}/accounts

Get a list of the account objects returned as part of a data request

An account is a single line of activity for a customer. Each data request can return one or many accounts.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "_embedded": {
    "accounts": [
      {
        "prepaid": true,
        "_links": {
          "statements": "string",
          "self": "string"
        },
        "accountNumber": "string"
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedAccountResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Account

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId} \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId} HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}", data)
    req.Header = headers

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

GET /identity/requests/{requestId}/accounts/{accountId}

Retrieve a single account object returned as part of a data request

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId

Example responses

200 Response

{
  "prepaid": true,
  "_links": {
    "statements": "string",
    "self": "string"
  },
  "accountNumber": "string"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK AccountResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Statements

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements", data)
    req.Header = headers

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

GET /identity/requests/{requestId}/accounts/{accountId}/statements

Get a list of the statement objects returned as part of a data request

A statement is a unique invoice for a particular account. It represents the account's activity over a specific period of time. A data request may return one or many monthly statements depending on the submitted start/end dates and the amount of data made available by the utility provider.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId

Example responses

200 Response

{
  "_embedded": {
    "statements": [
      {
        "_links": {
          "viewstatementsource": "string",
          "self": "string"
        },
        "billingAddressCity": "string",
        "billingAddressCountry": "string",
        "billingAddressName": "string",
        "billingAddressPostalCode": "string",
        "billingAddressRaw": "string",
        "billingAddressState": "string",
        "billingAddressStreet1": "string",
        "billingAddressStreet2": "string",
        "serviceAddressCity": "string",
        "serviceAddressCountry": "string",
        "serviceAddressName": "string",
        "serviceAddressPostalCode": "string",
        "serviceAddressRaw": "string",
        "serviceAddressState": "string",
        "serviceAddressStreet1": "string",
        "serviceAddressStreet2": "string",
        "statementDate": "string",
        "statementType": "BILL"
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedIdentityStatementResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Statement Source

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source \
  -H 'Accept: */*' \
  -H 'Authorization: string'

GET https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source HTTP/1.1
Host: api.urjanet.com
Accept: */*
Authorization: string

var headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
  method: 'get',

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

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

const headers = {
  'Accept':'*/*',
  'Authorization':'string'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
{
  method: 'GET',

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

require 'rest-client'
require 'json'

headers = {
  'Accept' => '*/*',
  'Authorization' => 'string'
}

result = RestClient.get 'https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': '*/*',
  'Authorization': 'string'
}

r = requests.get('https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source");
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{"*/*"},
        "Authorization": []string{"string"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source", data)
    req.Header = headers

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

GET /identity/requests/{requestId}/accounts/{accountId}/statements/{statementId}/source

Get the source document for a specific statement. This is usually a PDF version of the actual bill.

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
accountId path integer(int64) true accountId
statementId path integer(int64) true statementId
Authorization header string false none

Example responses

401 Response

Responses

Status Meaning Description Schema
200 OK OK None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Response Headers

Status Header Type Format Description
200 Access-Control-Allow-Headers string none
200 Access-Control-Allow-Methods string none
200 Access-Control-Allow-Origin string none

Submit Clone Request

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/identity/requests/{requestId}/clones \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/identity/requests/{requestId}/clones HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/clones',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "periodEnd": "string",
  "periodStart": "string",
  "webhookUrl": "string",
  "accountNumber": "string",
  "correlationId": "string",
  "timeout": 3600
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/clones',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/identity/requests/{requestId}/clones',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/identity/requests/{requestId}/clones', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/clones");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/identity/requests/{requestId}/clones", data)
    req.Header = headers

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

POST /identity/requests/{requestId}/clones

Create a copy of a previous identity request

Using a clone to create a identity request allows you to submit a new identity request without needing account credentials. See /identity/requests

Body parameter

{
  "periodEnd": "string",
  "periodStart": "string",
  "webhookUrl": "string",
  "accountNumber": "string",
  "correlationId": "string",
  "timeout": 3600
}

Parameters

Parameter In Type Required Description
requestId path integer(int64) true requestId
periodEnd body string false End date of statements to include; formatted YYYY-MM-DD
periodStart body string false Start date of statements to include; formatted YYYY-MM-DD
webhookUrl body string false Urjanet will send status updates to this URL via HTTP events
accountNumber body string false If provided, only data for this account will be extracted
correlationId body string false An ID used to match the utility data pulled for this request back to users in your system
timeout body integer(int32) false The length of time, in seconds, which Urjanet will continue to fulfill this request

Example responses

200 Response

{
  "_links": {
    "cloneCredit": "string",
    "cloneSolar": "string",
    "cloneIdentity": "string",
    "consent": "string",
    "self": "string"
  },
  "accountNumber": "string",
  "providerId": "string",
  "providerName": "string",
  "webhookResult": 0,
  "webhookUrl": "string",
  "completionStatus": "SUCCESS",
  "completionStatusDetail": "NO_STATEMENTS_IN_PERIOD",
  "correlationId": "string",
  "createdDate": "2021-09-27T18:43:34Z",
  "expirationDate": "2021-09-27T18:43:34Z",
  "statementCount": 0,
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "mock": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicIdentityRequestResource
201 Created Created None
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/identity/requests/{requestId}/consent \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/identity/requests/{requestId}/consent HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/identity/requests/{requestId}/consent',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/identity/requests/{requestId}/consent',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/identity/requests/{requestId}/consent',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/identity/requests/{requestId}/consent', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/identity/requests/{requestId}/consent");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/identity/requests/{requestId}/consent", data)
    req.Header = headers

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

GET /identity/requests/{requestId}/consent

Get the consent data for a request

Parameter In Type Required Description
requestId path integer(int64) true requestId

Example responses

200 Response

{
  "consentStatus": "string",
  "credentialCreatedDate": "2021-09-27T18:43:34Z",
  "lastModifiedDate": "2021-09-27T18:43:34Z",
  "origin": "API",
  "privacyPolicyUrl": "string",
  "revokeDate": "2021-09-27T18:43:34Z",
  "termsOfServiceUrl": "string"
}

401 Response

Status Meaning Description Schema
200 OK OK ConsentResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Bill Payment/AP Automation

The Bill Payment API (formerly known as AP Automation) is designed to provide access to utility data for enabling automated bill payment. The data Urjanet collects is formatted to show the utility bill details that are relevant for processing and paying.

Credential Status

Urjanet can send webhook events that notify you whenever there is a significant status update to a provider connection. This includes notification when the connection is complete or there is an issue with the connection.

When an update occurs, Urjanet sends an event containing the new status via an HTTP POST to the webhookUrl specified on the data request. See below for a complete list of statuses.

Completion Status Completion Status Detail Description
OK NO_ACTION_REQUIRED No action required
PENDING WEBSITE_DOWN Temporary problem in accessing the website
PENDING UNDER_REVIEW Urjanet is reviewing the issue and will update the status shortly
PENDING STATEMENT_UNAVAILABLE Temporary problem in accessing bills within this credential
PENDING NAVIGATION_FAILURE No action required
ACTION_REQUIRED LOGIN_FAILURE Login attempt failed. Update your credentials, and the system will try again
ACTION_REQUIRED NO_ACCOUNTS_FOUND No accounts found within this credential
ACTION_REQUIRED UNSUPPORTED_CAPTCHA Login failed due to a captcha required by the utility. In some cases, captcha can be disabled in the utility's website settings.
ACTION_REQUIRED MULTI_FACTOR_AUTH_FAILURE Login failed due to PIN or Access Code required by the utility for login.
ACTION_REQUIRED USER_ACTION_REQUIRED Login attempt passed, but unable to reach to the account information
ACTION_REQUIRED SECURITY_QUESTIONS Login attempt failed due to security questions posed by the utility. Add security questions & answers using the additional login fields.
ACTION_REQUIRED ACCOUNT_LOCKED Login failed due to account lockout. Please unlock the account.
ACTION_REQUIRED E_BILL_REQUIRED Enrollment in electronic billing is required to access online statements.

Account Status

Urjanet can send webhook events that notify you whenever there is a significant status update to a specific account.

When an update occurs, Urjanet sends an event containing the new status via an HTTP POST to the webhookUrl specified on the data request. See below for a complete list of statuses.

Completion Status Completion Status Detail Description
OK NO_ACTION_REQUIRED No action required
PENDING EXTRACTION FAILURE Pending an Urjanet fix
PENDING WEBSITE_DOWN Temporary problem in accessing the website
PENDING UNDER_REVIEW Urjanet is reviewing the issue and will update the status shortly
PENDING STATEMENT_UNAVAILABLE Temporary problem in accessing bills within this credential
PENDING NAVIGATION_FAILURE No action required
ACCESS_ISSUE ACCOUNT_NOT_FOUND Account not found in site
ACCESS_ISSUE E_BILL_REQUIRED Enrollment in electronic billing is required to access online statements.
ACCESS_ISSUE INVALID_SOURCE The data source available is in a format rejected by your organization.
ACCESS_ISSUE ACCOUNT_NUMBER_CHANGE Account number changed and this is no longer valid. Unsubscribe it.
OLD DORMANT Account has not seen a new bill for 45 days
OLD ACCOUNT_CLOSED This account has received a Final Bill notice or has been marked inactive on the provider's website.

List Providers

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/apautomation/providers \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/apautomation/providers HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/apautomation/providers',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/apautomation/providers',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/apautomation/providers',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/apautomation/providers', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/apautomation/providers");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/apautomation/providers", data)
    req.Header = headers

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

GET /apautomation/providers

Search for a list of utility providers

Providers are the utility companies that Urjanet supports. In order to submit a request to Urjanet, you will need a providerID. List Providers allows you to query the providers endpoint to find a list of providers that meet specific criteria or to search for a specific provider.

Parameters

Parameter In Type Required Description
search query string false An RSQL query string. See here for examples. Searchable fields are listed here.

Example responses

200 Response

{
  "_embedded": {
    "providers": [
      {
        "_links": {
          "serviceTypes": "string",
          "parentProvider": "string",
          "self": "string"
        },
        "providerName": "string",
        "hasMultiFactorAuthentication": true,
        "requiredFields": [
          "string"
        ],
        "requiredFieldMetadata": [
          {
            "fieldName": "string",
            "fieldLabel": "string",
            "fieldNumber": 0,
            "fieldPart": 0,
            "fieldLength": 0
          }
        ],
        "supportsCredentialValidation": true,
        "country": "string",
        "enabledSolutions": [
          "CREDIT"
        ],
        "serviceTypes": [
          "string"
        ],
        "providerId": "string",
        "website": "string",
        "hasPrepaid": true,
        "hasPostpaid": true,
        "mock": true,
        "beta": true
      }
    ]
  },
  "_links": {
    "last": "string",
    "next": "string",
    "prev": "string",
    "self": "string"
  },
  "page": {
    "number": 0,
    "size": 0,
    "totalElements": 0,
    "totalPages": 0
  }
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PagedPublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Retrieve Provider

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/apautomation/providers/{providerId} \
  -H 'Accept: application/hal+json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/apautomation/providers/{providerId} HTTP/1.1
Host: api.urjanet.com
Accept: application/hal+json

var headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/apautomation/providers/{providerId}',
  method: 'get',

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

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

const headers = {
  'Accept':'application/hal+json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/apautomation/providers/{providerId}',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/apautomation/providers/{providerId}',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/hal+json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/apautomation/providers/{providerId}', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/apautomation/providers/{providerId}");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("GET", "https://api.urjanet.com/apautomation/providers/{providerId}", data)
    req.Header = headers

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

GET /apautomation/providers/{providerId}

Retrieve the details of a specific provider

Once you have found a specific provider that you would like to submit a request for, you can see the details of that provider using the Retrieve Provider endpoint. This allows you to understand specific details of a utility provider like the required login fields, what solutions are enabled for this provider and the service type.

Parameters

Parameter In Type Required Description
providerId path string true providerId

Example responses

200 Response

{
  "_links": {
    "serviceTypes": "string",
    "parentProvider": "string",
    "self": "string"
  },
  "providerName": "string",
  "hasMultiFactorAuthentication": true,
  "requiredFields": [
    "string"
  ],
  "requiredFieldMetadata": [
    {
      "fieldName": "string",
      "fieldLabel": "string",
      "fieldNumber": 0,
      "fieldPart": 0,
      "fieldLength": 0
    }
  ],
  "supportsCredentialValidation": true,
  "country": "string",
  "enabledSolutions": [
    "CREDIT"
  ],
  "serviceTypes": [
    "string"
  ],
  "providerId": "string",
  "website": "string",
  "hasPrepaid": true,
  "hasPostpaid": true,
  "mock": true,
  "beta": true
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicProviderResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

Create Credential

Code samples

# You can also use wget
curl -X POST https://api.urjanet.com/apautomation/providers/{providerId}/credentials \
  -H 'Content-Type: application/json' \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

POST https://api.urjanet.com/apautomation/providers/{providerId}/credentials HTTP/1.1
Host: api.urjanet.com
Content-Type: application/json
Accept: application/json

var headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/apautomation/providers/{providerId}/credentials',
  method: 'post',

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

const fetch = require('node-fetch');
const inputBody = '{
  "correlationId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}';
const headers = {
  'Content-Type':'application/json',
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/apautomation/providers/{providerId}/credentials',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.post 'https://api.urjanet.com/apautomation/providers/{providerId}/credentials',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Content-Type': 'application/json',
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.post('https://api.urjanet.com/apautomation/providers/{providerId}/credentials', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/apautomation/providers/{providerId}/credentials");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte{jsonReq})
    req, err := http.NewRequest("POST", "https://api.urjanet.com/apautomation/providers/{providerId}/credentials", data)
    req.Header = headers

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

POST /apautomation/providers/{providerId}/credentials

Create a credential

The credentials endpoint can also be used to create a new credential in the system. In order to create a new credential in the system, you must use the provider Id in the path and submit the required username and password as defined by the providers endpoint, and an organizationId.

Body parameter

{
  "correlationId": "string",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string",
  "password": "string",
  "password2": "string",
  "password3": "string",
  "password4": "string"
}

Parameters

Parameter In Type Required Description
providerId path string true providerId
correlationId body string false An ID used to match the utility data pulled for this request back to users in your system
username body string false A login input required to access the customer's utility data
username2 body string false Optional parameters required by some providers to access data. The provider object will denote which fields are required for each provider
username3 body string false See username2
username4 body string false See username2
password body string false A sensitive input required to access the customer's utility data. This will not be returned in any GET calls for the request object.
password2 body string false Optional sensitive input required by some providers to access data. The provider object will denote which fields are required for each provider. Like password, this value will not be returned in any GET calls for the request object.
password3 body string false See password2
password4 body string false See password2

Example responses

200 Response

{
  "_embedded": {
    "customData": {}
  },
  "_links": {
    "provider": "string",
    "passwords": "string",
    "events": "string",
    "customData": "string",
    "consent": "string",
    "updateUrl": "string",
    "refreshUrl": "string",
    "download": "string",
    "accounts": "string",
    "self": "string"
  },
  "runHistory": true,
  "correlationId": "string",
  "created": "2021-09-27T18:43:34Z",
  "createdBy": "string",
  "enabled": true,
  "lastModified": "2021-09-27T18:43:34Z",
  "lastModifiedBy": "string",
  "nextScheduledRun": "2021-09-27T18:43:34Z",
  "providerName": "string",
  "status": "OK",
  "statusDetail": "ACCOUNT_LOCKED",
  "username": "string",
  "username2": "string",
  "username3": "string",
  "username4": "string"
}

401 Response

Responses

Status Meaning Description Schema
200 OK OK PublicCredentialResource
401 Unauthorized Unauthorized ErrorResponse
403 Forbidden Forbidden ErrorResponse
404 Not Found NotFound ErrorResponse

List Credentials

Code samples

# You can also use wget
curl -X GET https://api.urjanet.com/apautomation/credentials \
  -H 'Accept: application/json' \
  -H 'Authorization: Bearer {access-token}'

GET https://api.urjanet.com/apautomation/credentials HTTP/1.1
Host: api.urjanet.com
Accept: application/json

var headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

$.ajax({
  url: 'https://api.urjanet.com/apautomation/credentials',
  method: 'get',

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

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

const headers = {
  'Accept':'application/json',
  'Authorization':'Bearer {access-token}'

};

fetch('https://api.urjanet.com/apautomation/credentials',
{
  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',
  'Authorization' => 'Bearer {access-token}'
}

result = RestClient.get 'https://api.urjanet.com/apautomation/credentials',
  params: {
  }, headers: headers

p JSON.parse(result)

import requests
headers = {
  'Accept': 'application/json',
  'Authorization': 'Bearer {access-token}'
}

r = requests.get('https://api.urjanet.com/apautomation/credentials', params={

}, headers = headers)

print r.json()

URL obj = new URL("https://api.urjanet.com/apautomation/credentials");
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"},
        "Authorization": []string{"Bearer {access-token}"},

    }

    data := bytes.NewBuffer([]byte