const mangopayInstance = require('mangopay4-nodejs-sdk')
const mangopay = new mangopayInstance({
clientId: 'your-client-id',
clientApiKey: 'your-api-key',
})
let myCountry = {
code: 'FR'
}
const viewCountryAuthorizations = async (countryCode) => {
return await mangopay.Regulatory.getCountryAuthorizations(countryCode)
.then((response) => {
console.info(response)
return response
})
.catch((err) => {
console.log(err)
return false
})
}
viewCountryAuthorizations(myCountry.code)
require 'mangopay'
MangoPay.configure do |client|
client.preproduction = true
client.client_id = 'your-client-id'
client.client_apiKey = 'your-api-key'
client.log_file = File.join(Dir.pwd, 'mangopay.log')
end
def viewCountryAuthorization(countryCode)
begin
response = MangoPay::Regulatory.get_country_authorizations(countryCode)
puts response
return response
rescue MangoPay::ResponseError => error
puts "Failed to fetch country authorizations: #{error.message}"
puts "Error details: #{error.details}"
return false
end
end
myCountry = {
Code: 'FR'
}
viewCountryAuthorization(myCountry[:Code])
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.mangopay.MangoPayApi;
import com.mangopay.core.enumerations.CountryIso;
import com.mangopay.entities.CountryAuthorization;
public class ViewCountryAuthorization {
public static void main(String[] args) throws Exception {
MangoPayApi mangopay = new MangoPayApi();
mangopay.getConfig().setClientId("your-client-id");
mangopay.getConfig().setClientPassword("your-api-key");
CountryAuthorization viewCountryAuthorization = mangopay.getRegulatoryApi().getCountryAuthorizations(CountryIso.FR);
Gson prettyPrint = new GsonBuilder().setPrettyPrinting().create();
String prettyJson = prettyPrint.toJson(viewCountryAuthorization);
System.out.println(prettyJson);
}
}
from pprint import pprint
import mangopay
mangopay.client_id='your-client-id'
mangopay.apikey='your-api-key'
from mangopay.api import APIRequest
handler = APIRequest(sandbox=True)
from mangopay.resources import CountryAuthorization
view_country_authorization = CountryAuthorization.get_country_authorizations(country_code='FR')
pprint(view_country_authorization._data)
pprint(vars(view_country_authorization.authorization))
using MangoPay.SDK;
using MangoPay.SDK.Core.Enumerations;
using MangoPay.SDK.Entities.GET;
using Newtonsoft.Json;
class Program
{
static async Task Main(string[] args)
{
MangoPayApi api = new MangoPayApi();
api.Config.ClientId = "your-client-id";
api.Config.ClientPassword = "your-api-key";
CountryAuthorizationDTO countryAuthorization = await api.Regulatory.GetCountryAuthorizations(CountryIso.FR);
string prettyPrint = JsonConvert.SerializeObject(countryAuthorization, Formatting.Indented);
Console.WriteLine(prettyPrint);
}
}
{
"CountryCode":"FR",
"CountryName":"France",
"Authorization":{
"BlockUserCreation":false,
"BlockBankAccountCreation":false,
"BlockPayout":false
},
"LastUpdate":1463494366
}
Country authorizations
View Authorizations for a country
GET
/
v2.01
/
countries
/
{CountryCode}
/
authorizations
const mangopayInstance = require('mangopay4-nodejs-sdk')
const mangopay = new mangopayInstance({
clientId: 'your-client-id',
clientApiKey: 'your-api-key',
})
let myCountry = {
code: 'FR'
}
const viewCountryAuthorizations = async (countryCode) => {
return await mangopay.Regulatory.getCountryAuthorizations(countryCode)
.then((response) => {
console.info(response)
return response
})
.catch((err) => {
console.log(err)
return false
})
}
viewCountryAuthorizations(myCountry.code)
require 'mangopay'
MangoPay.configure do |client|
client.preproduction = true
client.client_id = 'your-client-id'
client.client_apiKey = 'your-api-key'
client.log_file = File.join(Dir.pwd, 'mangopay.log')
end
def viewCountryAuthorization(countryCode)
begin
response = MangoPay::Regulatory.get_country_authorizations(countryCode)
puts response
return response
rescue MangoPay::ResponseError => error
puts "Failed to fetch country authorizations: #{error.message}"
puts "Error details: #{error.details}"
return false
end
end
myCountry = {
Code: 'FR'
}
viewCountryAuthorization(myCountry[:Code])
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.mangopay.MangoPayApi;
import com.mangopay.core.enumerations.CountryIso;
import com.mangopay.entities.CountryAuthorization;
public class ViewCountryAuthorization {
public static void main(String[] args) throws Exception {
MangoPayApi mangopay = new MangoPayApi();
mangopay.getConfig().setClientId("your-client-id");
mangopay.getConfig().setClientPassword("your-api-key");
CountryAuthorization viewCountryAuthorization = mangopay.getRegulatoryApi().getCountryAuthorizations(CountryIso.FR);
Gson prettyPrint = new GsonBuilder().setPrettyPrinting().create();
String prettyJson = prettyPrint.toJson(viewCountryAuthorization);
System.out.println(prettyJson);
}
}
from pprint import pprint
import mangopay
mangopay.client_id='your-client-id'
mangopay.apikey='your-api-key'
from mangopay.api import APIRequest
handler = APIRequest(sandbox=True)
from mangopay.resources import CountryAuthorization
view_country_authorization = CountryAuthorization.get_country_authorizations(country_code='FR')
pprint(view_country_authorization._data)
pprint(vars(view_country_authorization.authorization))
using MangoPay.SDK;
using MangoPay.SDK.Core.Enumerations;
using MangoPay.SDK.Entities.GET;
using Newtonsoft.Json;
class Program
{
static async Task Main(string[] args)
{
MangoPayApi api = new MangoPayApi();
api.Config.ClientId = "your-client-id";
api.Config.ClientPassword = "your-api-key";
CountryAuthorizationDTO countryAuthorization = await api.Regulatory.GetCountryAuthorizations(CountryIso.FR);
string prettyPrint = JsonConvert.SerializeObject(countryAuthorization, Formatting.Indented);
Console.WriteLine(prettyPrint);
}
}
{
"CountryCode":"FR",
"CountryName":"France",
"Authorization":{
"BlockUserCreation":false,
"BlockBankAccountCreation":false,
"BlockPayout":false
},
"LastUpdate":1463494366
}
This call returns the restrictions for a specific country.
Path parameters
string
required
Format: Two-letter country code (ISO 3166-1 alpha-2 format)The code of the country.
Responses
200
200
string
Format: Two-letter country code (ISO 3166-1 alpha-2 format)The code of the country.
string
Name of the country.
object
Information about the country’s restrictions.
Hide properties
Hide properties
boolean
Whether or not user creation is possible based on the user’s country of residence, address, and nationality.
boolean
Whether or not bank account creation is possible based on the bank’s country of domiciliation.
boolean
Whether or not payout creation is possible based on the bank’s country of domiciliation.
Unix timestamp
The date and time when at least one of the country’s authorizations has been last updated.
{
"CountryCode":"FR",
"CountryName":"France",
"Authorization":{
"BlockUserCreation":false,
"BlockBankAccountCreation":false,
"BlockPayout":false
},
"LastUpdate":1463494366
}
const mangopayInstance = require('mangopay4-nodejs-sdk')
const mangopay = new mangopayInstance({
clientId: 'your-client-id',
clientApiKey: 'your-api-key',
})
let myCountry = {
code: 'FR'
}
const viewCountryAuthorizations = async (countryCode) => {
return await mangopay.Regulatory.getCountryAuthorizations(countryCode)
.then((response) => {
console.info(response)
return response
})
.catch((err) => {
console.log(err)
return false
})
}
viewCountryAuthorizations(myCountry.code)
require 'mangopay'
MangoPay.configure do |client|
client.preproduction = true
client.client_id = 'your-client-id'
client.client_apiKey = 'your-api-key'
client.log_file = File.join(Dir.pwd, 'mangopay.log')
end
def viewCountryAuthorization(countryCode)
begin
response = MangoPay::Regulatory.get_country_authorizations(countryCode)
puts response
return response
rescue MangoPay::ResponseError => error
puts "Failed to fetch country authorizations: #{error.message}"
puts "Error details: #{error.details}"
return false
end
end
myCountry = {
Code: 'FR'
}
viewCountryAuthorization(myCountry[:Code])
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.mangopay.MangoPayApi;
import com.mangopay.core.enumerations.CountryIso;
import com.mangopay.entities.CountryAuthorization;
public class ViewCountryAuthorization {
public static void main(String[] args) throws Exception {
MangoPayApi mangopay = new MangoPayApi();
mangopay.getConfig().setClientId("your-client-id");
mangopay.getConfig().setClientPassword("your-api-key");
CountryAuthorization viewCountryAuthorization = mangopay.getRegulatoryApi().getCountryAuthorizations(CountryIso.FR);
Gson prettyPrint = new GsonBuilder().setPrettyPrinting().create();
String prettyJson = prettyPrint.toJson(viewCountryAuthorization);
System.out.println(prettyJson);
}
}
from pprint import pprint
import mangopay
mangopay.client_id='your-client-id'
mangopay.apikey='your-api-key'
from mangopay.api import APIRequest
handler = APIRequest(sandbox=True)
from mangopay.resources import CountryAuthorization
view_country_authorization = CountryAuthorization.get_country_authorizations(country_code='FR')
pprint(view_country_authorization._data)
pprint(vars(view_country_authorization.authorization))
using MangoPay.SDK;
using MangoPay.SDK.Core.Enumerations;
using MangoPay.SDK.Entities.GET;
using Newtonsoft.Json;
class Program
{
static async Task Main(string[] args)
{
MangoPayApi api = new MangoPayApi();
api.Config.ClientId = "your-client-id";
api.Config.ClientPassword = "your-api-key";
CountryAuthorizationDTO countryAuthorization = await api.Regulatory.GetCountryAuthorizations(CountryIso.FR);
string prettyPrint = JsonConvert.SerializeObject(countryAuthorization, Formatting.Indented);
Console.WriteLine(prettyPrint);
}
}
Was this page helpful?