{
"Type": "DELIVERY_PROOF",
"Tag": "Custom meta"
}
<?php
require_once 'vendor/autoload.php';
use MangoPay\MangoPayApi;
use MangoPay\Libraries\ResponseException as MGPResponseException;
use MangoPay\Libraries\Exception as MGPException;
$api = new MangoPayApi();
$api->Config->ClientId = 'your-client-id';
$api->Config->ClientPassword = 'your-api-key';
$api->Config->TemporaryFolder = 'tmp/';
ry {
$disputeId = '199385842';
$document = new \MangoPay\DisputeDocument();
$document->Type = \MangoPay\DisputeDocumentType::DeliveryProof;
$document->Tag = 'Created using Mangopay PHP SDK';
$response = $api->Disputes->CreateDisputeDocument($disputeId, $document);
print_r($response);
} catch(MGPResponseException $e) {
print_r($e);
} catch(MGPException $e) {
print_r($e);
}
const mangopayInstance = require('mangopay4-nodejs-sdk')
const mangopay = new mangopayInstance({
clientId: 'your-client-id',
clientApiKey: 'your-api-key',
})
let myDispute = {
Id: '172969213',
}
let myDisputeDocument = {
Type: 'DELIVERY_PROOF',
Tag: 'Created using Mangopay Node.js SDK',
}
const createDisputeDocument = async (disputeId, disputeDocument) => {
return await mangopay.Disputes.createDisputeDocument(disputeId, disputeDocument)
.then((response) => {
console.info(response)
return response
})
.catch((err) => {
console.log(err)
return false
})
}
createDisputeDocument(myDispute.Id, myDisputeDocument)
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.mangopay.MangoPayApi;
import com.mangopay.core.enumerations.DisputeDocumentType;
import com.mangopay.entities.DisputeDocument;
public class CreateDisputeDoc {
public static void main(String[] args) throws Exception {
MangoPayApi mangopay = new MangoPayApi();
mangopay.getConfig().setClientId("your-client-id");
mangopay.getConfig().setClientPassword("your-api-key");
var disputeId = "dispute_m_01J354MZ17XZA4DMAQS1766VXM";
DisputeDocument disputeDocument = new DisputeDocument();
disputeDocument.setDisputeId(disputeId);
disputeDocument.setType(DisputeDocumentType.DELIVERY_PROOF);
DisputeDocument createDisputeDoc = mangopay.getDisputeApi().createDisputeDocument(disputeDocument, disputeId);
Gson prettyPrint = new GsonBuilder().setPrettyPrinting().create();
String prettyJson = prettyPrint.toJson(createDisputeDoc);
System.out.println(prettyJson);
}
}
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 createDisputeDocument(disputeId, disputeDocumentObject)
begin
response = MangoPay::Dispute.create_document(disputeId, disputeDocumentObject)
puts response
return response
rescue MangoPay::ResponseError => error
puts "Failed to create Document: #{error.message}"
puts "Error details: #{error.details}"
return false
end
end
myDispute = {
Id:'194413022'
}
myDocument = {
Type:'DELIVERY_PROOF',
Tag:'Created using Mangopay Ruby SDK'
}
createDisputeDocument(myDispute[:Id], myDocument)
using MangoPay.SDK;
using MangoPay.SDK.Core.Enumerations;
using MangoPay.SDK.Entities.POST;
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";
var disputeId = "dispute_m_01J41GEVRQN3W1C4YRK7NC04QT";
DisputeDocumentPostDTO disputeDoc = new DisputeDocumentPostDTO(DisputeDocumentType.INVOICE);
var createDisputeDocument = await api.Disputes.CreateDisputeDocumentAsync(disputeDoc, disputeId);
string prettyPrint = JsonConvert.SerializeObject(createDisputeDocument, Formatting.Indented);
Console.WriteLine(prettyPrint);
}
}
{
"DisputeId": "159102965",
"Type": "DELIVERY_PROOF",
"Id": "159188418",
"Tag": null,
"CreationDate": 1672655973,
"ProcessedDate": null,
"Status": "CREATED",
"RefusedReasonType": null,
"RefusedReasonMessage": null
}
Dispute documents
Create a Dispute Document
POST
/
v2.01
/
{ClientId}
/
disputes
/
{DisputeId}
/
documents
{
"Type": "DELIVERY_PROOF",
"Tag": "Custom meta"
}
<?php
require_once 'vendor/autoload.php';
use MangoPay\MangoPayApi;
use MangoPay\Libraries\ResponseException as MGPResponseException;
use MangoPay\Libraries\Exception as MGPException;
$api = new MangoPayApi();
$api->Config->ClientId = 'your-client-id';
$api->Config->ClientPassword = 'your-api-key';
$api->Config->TemporaryFolder = 'tmp/';
ry {
$disputeId = '199385842';
$document = new \MangoPay\DisputeDocument();
$document->Type = \MangoPay\DisputeDocumentType::DeliveryProof;
$document->Tag = 'Created using Mangopay PHP SDK';
$response = $api->Disputes->CreateDisputeDocument($disputeId, $document);
print_r($response);
} catch(MGPResponseException $e) {
print_r($e);
} catch(MGPException $e) {
print_r($e);
}
const mangopayInstance = require('mangopay4-nodejs-sdk')
const mangopay = new mangopayInstance({
clientId: 'your-client-id',
clientApiKey: 'your-api-key',
})
let myDispute = {
Id: '172969213',
}
let myDisputeDocument = {
Type: 'DELIVERY_PROOF',
Tag: 'Created using Mangopay Node.js SDK',
}
const createDisputeDocument = async (disputeId, disputeDocument) => {
return await mangopay.Disputes.createDisputeDocument(disputeId, disputeDocument)
.then((response) => {
console.info(response)
return response
})
.catch((err) => {
console.log(err)
return false
})
}
createDisputeDocument(myDispute.Id, myDisputeDocument)
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.mangopay.MangoPayApi;
import com.mangopay.core.enumerations.DisputeDocumentType;
import com.mangopay.entities.DisputeDocument;
public class CreateDisputeDoc {
public static void main(String[] args) throws Exception {
MangoPayApi mangopay = new MangoPayApi();
mangopay.getConfig().setClientId("your-client-id");
mangopay.getConfig().setClientPassword("your-api-key");
var disputeId = "dispute_m_01J354MZ17XZA4DMAQS1766VXM";
DisputeDocument disputeDocument = new DisputeDocument();
disputeDocument.setDisputeId(disputeId);
disputeDocument.setType(DisputeDocumentType.DELIVERY_PROOF);
DisputeDocument createDisputeDoc = mangopay.getDisputeApi().createDisputeDocument(disputeDocument, disputeId);
Gson prettyPrint = new GsonBuilder().setPrettyPrinting().create();
String prettyJson = prettyPrint.toJson(createDisputeDoc);
System.out.println(prettyJson);
}
}
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 createDisputeDocument(disputeId, disputeDocumentObject)
begin
response = MangoPay::Dispute.create_document(disputeId, disputeDocumentObject)
puts response
return response
rescue MangoPay::ResponseError => error
puts "Failed to create Document: #{error.message}"
puts "Error details: #{error.details}"
return false
end
end
myDispute = {
Id:'194413022'
}
myDocument = {
Type:'DELIVERY_PROOF',
Tag:'Created using Mangopay Ruby SDK'
}
createDisputeDocument(myDispute[:Id], myDocument)
using MangoPay.SDK;
using MangoPay.SDK.Core.Enumerations;
using MangoPay.SDK.Entities.POST;
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";
var disputeId = "dispute_m_01J41GEVRQN3W1C4YRK7NC04QT";
DisputeDocumentPostDTO disputeDoc = new DisputeDocumentPostDTO(DisputeDocumentType.INVOICE);
var createDisputeDocument = await api.Disputes.CreateDisputeDocumentAsync(disputeDoc, disputeId);
string prettyPrint = JsonConvert.SerializeObject(createDisputeDocument, Formatting.Indented);
Console.WriteLine(prettyPrint);
}
}
{
"DisputeId": "159102965",
"Type": "DELIVERY_PROOF",
"Id": "159188418",
"Tag": null,
"CreationDate": 1672655973,
"ProcessedDate": null,
"Status": "CREATED",
"RefusedReasonType": null,
"RefusedReasonMessage": null
}
Path parameters
Body parameters
Allowed values:
DELIVERY_PROOF, INVOICE, REFUND_PROOF, USER_CORRESPONDANCE, USER_ACCEPTANCE_PROOF, PRODUCT_REPLACEMENT_PROOF, OTHERThe type of the dispute document.Responses
200
200
Returned values:
DELIVERY_PROOF, INVOICE, REFUND_PROOF, USER_CORRESPONDANCE, USER_ACCEPTANCE_PROOF, PRODUCT_REPLACEMENT_PROOF, OTHERThe type of the dispute document.Max length: 128 characters (see data formats for details)The unique identifier of the object.
Returned values:
CREATED, VALIDATION_ASKED, VALIDATED, REFUSED, OUT_OF_DATEThe status of the dispute document.Returned values: DOCUMENT_DO_NOT_MATCH_USER_DATA, DOCUMENT_FALSIFIED, DOCUMENT_HAS_EXPIRED, DOCUMENT_INCOMPLETE, DOCUMENT_MISSING, DOCUMENT_NOT_ACCEPTED, DOCUMENT_UNREADABLE, SPECIFIC_CASE, UNDERAGE_PERSONThe reason for the dispute document refusal. See the RefusedReasonMessage for more information.
{
"DisputeId": "159102965",
"Type": "DELIVERY_PROOF",
"Id": "159188418",
"Tag": null,
"CreationDate": 1672655973,
"ProcessedDate": null,
"Status": "CREATED",
"RefusedReasonType": null,
"RefusedReasonMessage": null
}
{
"Type": "DELIVERY_PROOF",
"Tag": "Custom meta"
}
<?php
require_once 'vendor/autoload.php';
use MangoPay\MangoPayApi;
use MangoPay\Libraries\ResponseException as MGPResponseException;
use MangoPay\Libraries\Exception as MGPException;
$api = new MangoPayApi();
$api->Config->ClientId = 'your-client-id';
$api->Config->ClientPassword = 'your-api-key';
$api->Config->TemporaryFolder = 'tmp/';
ry {
$disputeId = '199385842';
$document = new \MangoPay\DisputeDocument();
$document->Type = \MangoPay\DisputeDocumentType::DeliveryProof;
$document->Tag = 'Created using Mangopay PHP SDK';
$response = $api->Disputes->CreateDisputeDocument($disputeId, $document);
print_r($response);
} catch(MGPResponseException $e) {
print_r($e);
} catch(MGPException $e) {
print_r($e);
}
const mangopayInstance = require('mangopay4-nodejs-sdk')
const mangopay = new mangopayInstance({
clientId: 'your-client-id',
clientApiKey: 'your-api-key',
})
let myDispute = {
Id: '172969213',
}
let myDisputeDocument = {
Type: 'DELIVERY_PROOF',
Tag: 'Created using Mangopay Node.js SDK',
}
const createDisputeDocument = async (disputeId, disputeDocument) => {
return await mangopay.Disputes.createDisputeDocument(disputeId, disputeDocument)
.then((response) => {
console.info(response)
return response
})
.catch((err) => {
console.log(err)
return false
})
}
createDisputeDocument(myDispute.Id, myDisputeDocument)
import com.google.gson.Gson;
import com.google.gson.GsonBuilder;
import com.mangopay.MangoPayApi;
import com.mangopay.core.enumerations.DisputeDocumentType;
import com.mangopay.entities.DisputeDocument;
public class CreateDisputeDoc {
public static void main(String[] args) throws Exception {
MangoPayApi mangopay = new MangoPayApi();
mangopay.getConfig().setClientId("your-client-id");
mangopay.getConfig().setClientPassword("your-api-key");
var disputeId = "dispute_m_01J354MZ17XZA4DMAQS1766VXM";
DisputeDocument disputeDocument = new DisputeDocument();
disputeDocument.setDisputeId(disputeId);
disputeDocument.setType(DisputeDocumentType.DELIVERY_PROOF);
DisputeDocument createDisputeDoc = mangopay.getDisputeApi().createDisputeDocument(disputeDocument, disputeId);
Gson prettyPrint = new GsonBuilder().setPrettyPrinting().create();
String prettyJson = prettyPrint.toJson(createDisputeDoc);
System.out.println(prettyJson);
}
}
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 createDisputeDocument(disputeId, disputeDocumentObject)
begin
response = MangoPay::Dispute.create_document(disputeId, disputeDocumentObject)
puts response
return response
rescue MangoPay::ResponseError => error
puts "Failed to create Document: #{error.message}"
puts "Error details: #{error.details}"
return false
end
end
myDispute = {
Id:'194413022'
}
myDocument = {
Type:'DELIVERY_PROOF',
Tag:'Created using Mangopay Ruby SDK'
}
createDisputeDocument(myDispute[:Id], myDocument)
using MangoPay.SDK;
using MangoPay.SDK.Core.Enumerations;
using MangoPay.SDK.Entities.POST;
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";
var disputeId = "dispute_m_01J41GEVRQN3W1C4YRK7NC04QT";
DisputeDocumentPostDTO disputeDoc = new DisputeDocumentPostDTO(DisputeDocumentType.INVOICE);
var createDisputeDocument = await api.Disputes.CreateDisputeDocumentAsync(disputeDoc, disputeId);
string prettyPrint = JsonConvert.SerializeObject(createDisputeDocument, Formatting.Indented);
Console.WriteLine(prettyPrint);
}
}
Was this page helpful?