Skip to content

Commit

Permalink
update refund (#120)
Browse files Browse the repository at this point in the history
  • Loading branch information
haydossian95 authored Dec 12, 2024
1 parent df73c3c commit 8f6c0bd
Show file tree
Hide file tree
Showing 14 changed files with 131 additions and 18 deletions.
10 changes: 5 additions & 5 deletions Conekta.net.sln
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@ Microsoft Visual Studio Solution File, Format Version 12.00
# Visual Studio 14
VisualStudioVersion = 14.0.25420.1
MinimumVisualStudioVersion = 10.0.40219.1
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Conekta.net", "src\Conekta.net\Conekta.net.csproj", "{603464E7-D19E-4B64-B1B1-A0185A58D4A6}"
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Conekta.net", "src\Conekta.net\Conekta.net.csproj", "{F5668AFC-5CB1-4F0A-B50D-7BDE98211B17}"
EndProject
Project("{FAE04EC0-301F-11D3-BF4B-00C04F79EFBC}") = "Conekta.net.Test", "src\Conekta.net.Test\Conekta.net.Test.csproj", "{19F1DEBC-DE5E-4517-8062-F000CD499087}"
EndProject
Expand All @@ -12,10 +12,10 @@ Global
Release|Any CPU = Release|Any CPU
EndGlobalSection
GlobalSection(ProjectConfigurationPlatforms) = postSolution
{603464E7-D19E-4B64-B1B1-A0185A58D4A6}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{603464E7-D19E-4B64-B1B1-A0185A58D4A6}.Debug|Any CPU.Build.0 = Debug|Any CPU
{603464E7-D19E-4B64-B1B1-A0185A58D4A6}.Release|Any CPU.ActiveCfg = Release|Any CPU
{603464E7-D19E-4B64-B1B1-A0185A58D4A6}.Release|Any CPU.Build.0 = Release|Any CPU
{F5668AFC-5CB1-4F0A-B50D-7BDE98211B17}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{F5668AFC-5CB1-4F0A-B50D-7BDE98211B17}.Debug|Any CPU.Build.0 = Debug|Any CPU
{F5668AFC-5CB1-4F0A-B50D-7BDE98211B17}.Release|Any CPU.ActiveCfg = Release|Any CPU
{F5668AFC-5CB1-4F0A-B50D-7BDE98211B17}.Release|Any CPU.Build.0 = Release|Any CPU
{19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.ActiveCfg = Debug|Any CPU
{19F1DEBC-DE5E-4517-8062-F000CD499087}.Debug|Any CPU.Build.0 = Debug|Any CPU
{19F1DEBC-DE5E-4517-8062-F000CD499087}.Release|Any CPU.ActiveCfg = Release|Any CPU
Expand Down
2 changes: 1 addition & 1 deletion VERSION
Original file line number Diff line number Diff line change
@@ -1 +1 @@
6.0.14
6.0.15
31 changes: 30 additions & 1 deletion api/openapi.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13695,6 +13695,11 @@ components:
description: Custom reference
example: custom_reference
type: string
date_of_birth:
description: It is a parameter that allows to identify the date of birth
of the client.
example: 24/07/1992
type: string
default_fiscal_entity_id:
example: fis_ent_2tKqqAfqPi21oCmEJ
nullable: true
Expand Down Expand Up @@ -13725,6 +13730,11 @@ components:
description: Customer's name
example: Felipe
type: string
national_id:
description: It is a parameter that allows to identify the national identification
number of the client.
example: HEGG560427MVZRRL04
type: string
metadata:
additionalProperties: true
maxProperties: 100
Expand Down Expand Up @@ -14953,6 +14963,11 @@ components:
custom_reference:
description: It is an undefined value.
type: string
date_of_birth:
description: It is a parameter that allows to identify the date of birth
of the client.
example: 24/07/1992
type: string
email:
description: "An email address is a series of customizable characters followed\
\ by a universal Internet symbol, the at symbol (@), the name of a host\
Expand Down Expand Up @@ -14982,6 +14997,11 @@ components:
description: Client's name
example: miguel
type: string
national_id:
description: It is a parameter that allows to identify the national identification
number of the client.
example: HEGG560427MVZRRL04
type: string
payment_sources:
description: Contains details of the payment methods that the customer has
active or has used in Conekta
Expand Down Expand Up @@ -15016,6 +15036,11 @@ components:
properties:
antifraud_info:
$ref: '#/components/schemas/update_customer_antifraud_info'
date_of_birth:
description: It is a parameter that allows to identify the date of birth
of the client.
example: 24/07/1992
type: string
default_payment_source_id:
description: "It is a parameter that allows to identify in the response,\
\ the Conekta ID of a payment method (payment_id)"
Expand Down Expand Up @@ -15062,6 +15087,11 @@ components:
additionalProperties: true
maxProperties: 100
type: object
national_id:
description: It is a parameter that allows to identify the national identification
number of the client.
example: HEGG560427MVZRRL04
type: string
payment_sources:
description: Contains details of the payment methods that the customer has
active or has used in Conekta
Expand Down Expand Up @@ -16669,7 +16699,6 @@ components:
expires_at:
example: 1553273553
format: int64
nullable: true
type: integer
reason:
description: Reason for the refund
Expand Down
2 changes: 1 addition & 1 deletion config-netcore.json
Original file line number Diff line number Diff line change
Expand Up @@ -33,5 +33,5 @@
"packageCopyright" : "Conekta",
"PackageReleaseNotes" : "add support for payout orders",
"releaseNote" : "update entity webhook, nuget config",
"packageVersion" : "6.0.14"
"packageVersion" : "6.0.15"
}
2 changes: 2 additions & 0 deletions docs/Customer.md
Original file line number Diff line number Diff line change
Expand Up @@ -8,12 +8,14 @@ Name | Type | Description | Notes
**AntifraudInfo** | [**CustomerAntifraudInfo**](CustomerAntifraudInfo.md) | | [optional]
**Corporate** | **bool** | It is a value that allows identifying if the email is corporate or not. | [optional] [default to false]
**CustomReference** | **string** | It is an undefined value. | [optional]
**DateOfBirth** | **string** | It is a parameter that allows to identify the date of birth of the client. | [optional]
**Email** | **string** | An email address is a series of customizable characters followed by a universal Internet symbol, the at symbol (@), the name of a host server, and a web domain ending (.mx, .com, .org, . net, etc). |
**DefaultPaymentSourceId** | **string** | It is a parameter that allows to identify in the response, the Conekta ID of a payment method (payment_id) | [optional]
**DefaultShippingContactId** | **string** | It is a parameter that allows to identify in the response, the Conekta ID of the shipping address (shipping_contact) | [optional]
**FiscalEntities** | [**List<CustomerFiscalEntitiesRequest>**](CustomerFiscalEntitiesRequest.md) | | [optional]
**Metadata** | **Dictionary<string, Object>** | | [optional]
**Name** | **string** | Client's name |
**NationalId** | **string** | It is a parameter that allows to identify the national identification number of the client. | [optional]
**PaymentSources** | [**List<CustomerPaymentMethodsRequest>**](CustomerPaymentMethodsRequest.md) | Contains details of the payment methods that the customer has active or has used in Conekta | [optional]
**Phone** | **string** | Is the customer's phone number |
**PlanId** | **string** | Contains the ID of a plan, which could together with name, email and phone create a client directly to a subscription | [optional]
Expand Down
2 changes: 2 additions & 0 deletions docs/CustomerResponse.md
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,7 @@ Name | Type | Description | Notes
**Corporate** | **bool** | true if the customer is a company | [optional]
**CreatedAt** | **long** | Creation date of the object |
**CustomReference** | **string** | Custom reference | [optional]
**DateOfBirth** | **string** | It is a parameter that allows to identify the date of birth of the client. | [optional]
**DefaultFiscalEntityId** | **string** | | [optional]
**DefaultShippingContactId** | **string** | | [optional]
**DefaultPaymentSourceId** | **string** | | [optional]
Expand All @@ -17,6 +18,7 @@ Name | Type | Description | Notes
**Id** | **string** | Customer's ID |
**Livemode** | **bool** | true if the object exists in live mode or the value false if the object exists in test mode |
**Name** | **string** | Customer's name |
**NationalId** | **string** | It is a parameter that allows to identify the national identification number of the client. | [optional]
**Metadata** | **Dictionary<string, Object>** | | [optional]
**Object** | **string** | |
**PaymentSources** | [**CustomerPaymentMethodsResponse**](CustomerPaymentMethodsResponse.md) | | [optional]
Expand Down
2 changes: 1 addition & 1 deletion docs/OrderRefundRequest.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**Amount** | **int** | Amount to be refunded in cents |
**ExpiresAt** | **long?** | | [optional]
**ExpiresAt** | **long** | | [optional]
**Reason** | **string** | Reason for the refund |

[[Back to Model list]](../README.md#documentation-for-models) [[Back to API list]](../README.md#documentation-for-api-endpoints) [[Back to README]](../README.md)
Expand Down
2 changes: 2 additions & 0 deletions docs/UpdateCustomer.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@ update customer
Name | Type | Description | Notes
------------ | ------------- | ------------- | -------------
**AntifraudInfo** | [**UpdateCustomerAntifraudInfo**](UpdateCustomerAntifraudInfo.md) | | [optional]
**DateOfBirth** | **string** | It is a parameter that allows to identify the date of birth of the client. | [optional]
**DefaultPaymentSourceId** | **string** | It is a parameter that allows to identify in the response, the Conekta ID of a payment method (payment_id) | [optional]
**Email** | **string** | An email address is a series of customizable characters followed by a universal Internet symbol, the at symbol (@), the name of a host server, and a web domain ending (.mx, .com, .org, . net, etc). | [optional]
**Name** | **string** | Client's name | [optional]
Expand All @@ -16,6 +17,7 @@ Name | Type | Description | Notes
**CustomReference** | **string** | It is an undefined value. | [optional]
**FiscalEntities** | [**List<CustomerFiscalEntitiesRequest>**](CustomerFiscalEntitiesRequest.md) | | [optional]
**Metadata** | **Dictionary<string, Object>** | | [optional]
**NationalId** | **string** | It is a parameter that allows to identify the national identification number of the client. | [optional]
**PaymentSources** | [**List<CustomerPaymentMethodsRequest>**](CustomerPaymentMethodsRequest.md) | Contains details of the payment methods that the customer has active or has used in Conekta | [optional]
**ShippingContacts** | [**List<CustomerShippingContacts>**](CustomerShippingContacts.md) | Contains the detail of the shipping addresses that the client has active or has used in Conekta | [optional]
**Subscription** | [**SubscriptionRequest**](SubscriptionRequest.md) | | [optional]
Expand Down
4 changes: 2 additions & 2 deletions src/Conekta.net/Client/Configuration.cs
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ public class Configuration : IReadableConfiguration
/// Version of the package.
/// </summary>
/// <value>Version of the package.</value>
public const string Version = "6.0.14";
public const string Version = "6.0.15";

/// <summary>
/// Identifier for ISO 8601 DateTime Format
Expand Down Expand Up @@ -536,7 +536,7 @@ public static string ToDebugReport()
report += " OS: " + System.Environment.OSVersion + "\n";
report += " .NET Framework Version: " + System.Environment.Version + "\n";
report += " Version of the API: 2.1.0\n";
report += " SDK Package Version: 6.0.14\n";
report += " SDK Package Version: 6.0.15\n";

return report;
}
Expand Down
2 changes: 1 addition & 1 deletion src/Conekta.net/Conekta.net.csproj
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
<Description>This is a .net library that allows interaction with https://api.conekta.io API.</Description>
<Copyright>Conekta</Copyright>
<RootNamespace>Conekta.net</RootNamespace>
<Version>6.0.14</Version>
<Version>6.0.15</Version>
<DocumentationFile>bin\$(Configuration)\$(TargetFramework)\Conekta.net.xml</DocumentationFile>
<RepositoryUrl>https://github.com/conekta/conekta-.net.git</RepositoryUrl>
<RepositoryType>git</RepositoryType>
Expand Down
28 changes: 27 additions & 1 deletion src/Conekta.net/Model/Customer.cs
Original file line number Diff line number Diff line change
Expand Up @@ -43,18 +43,20 @@ protected Customer() { }
/// <param name="antifraudInfo">antifraudInfo.</param>
/// <param name="corporate">It is a value that allows identifying if the email is corporate or not. (default to false).</param>
/// <param name="customReference">It is an undefined value..</param>
/// <param name="dateOfBirth">It is a parameter that allows to identify the date of birth of the client..</param>
/// <param name="email">An email address is a series of customizable characters followed by a universal Internet symbol, the at symbol (@), the name of a host server, and a web domain ending (.mx, .com, .org, . net, etc). (required).</param>
/// <param name="defaultPaymentSourceId">It is a parameter that allows to identify in the response, the Conekta ID of a payment method (payment_id).</param>
/// <param name="defaultShippingContactId">It is a parameter that allows to identify in the response, the Conekta ID of the shipping address (shipping_contact).</param>
/// <param name="fiscalEntities">fiscalEntities.</param>
/// <param name="metadata">metadata.</param>
/// <param name="name">Client&#39;s name (required).</param>
/// <param name="nationalId">It is a parameter that allows to identify the national identification number of the client..</param>
/// <param name="paymentSources">Contains details of the payment methods that the customer has active or has used in Conekta.</param>
/// <param name="phone">Is the customer&#39;s phone number (required).</param>
/// <param name="planId">Contains the ID of a plan, which could together with name, email and phone create a client directly to a subscription.</param>
/// <param name="shippingContacts">Contains the detail of the shipping addresses that the client has active or has used in Conekta.</param>
/// <param name="subscription">subscription.</param>
public Customer(CustomerAntifraudInfo antifraudInfo = default(CustomerAntifraudInfo), bool corporate = false, string customReference = default(string), string email = default(string), string defaultPaymentSourceId = default(string), string defaultShippingContactId = default(string), List<CustomerFiscalEntitiesRequest> fiscalEntities = default(List<CustomerFiscalEntitiesRequest>), Dictionary<string, Object> metadata = default(Dictionary<string, Object>), string name = default(string), List<CustomerPaymentMethodsRequest> paymentSources = default(List<CustomerPaymentMethodsRequest>), string phone = default(string), string planId = default(string), List<CustomerShippingContacts> shippingContacts = default(List<CustomerShippingContacts>), SubscriptionRequest subscription = default(SubscriptionRequest))
public Customer(CustomerAntifraudInfo antifraudInfo = default(CustomerAntifraudInfo), bool corporate = false, string customReference = default(string), string dateOfBirth = default(string), string email = default(string), string defaultPaymentSourceId = default(string), string defaultShippingContactId = default(string), List<CustomerFiscalEntitiesRequest> fiscalEntities = default(List<CustomerFiscalEntitiesRequest>), Dictionary<string, Object> metadata = default(Dictionary<string, Object>), string name = default(string), string nationalId = default(string), List<CustomerPaymentMethodsRequest> paymentSources = default(List<CustomerPaymentMethodsRequest>), string phone = default(string), string planId = default(string), List<CustomerShippingContacts> shippingContacts = default(List<CustomerShippingContacts>), SubscriptionRequest subscription = default(SubscriptionRequest))
{
// to ensure "email" is required (not null)
if (email == null)
Expand All @@ -77,10 +79,12 @@ protected Customer() { }
this.AntifraudInfo = antifraudInfo;
this.Corporate = corporate;
this.CustomReference = customReference;
this.DateOfBirth = dateOfBirth;
this.DefaultPaymentSourceId = defaultPaymentSourceId;
this.DefaultShippingContactId = defaultShippingContactId;
this.FiscalEntities = fiscalEntities;
this.Metadata = metadata;
this.NationalId = nationalId;
this.PaymentSources = paymentSources;
this.PlanId = planId;
this.ShippingContacts = shippingContacts;
Expand Down Expand Up @@ -110,6 +114,16 @@ protected Customer() { }
[DataMember(Name = "custom_reference", EmitDefaultValue = false)]
public string CustomReference { get; set; }

/// <summary>
/// It is a parameter that allows to identify the date of birth of the client.
/// </summary>
/// <value>It is a parameter that allows to identify the date of birth of the client.</value>
/*
<example>24/07/1992</example>
*/
[DataMember(Name = "date_of_birth", EmitDefaultValue = false)]
public string DateOfBirth { get; set; }

/// <summary>
/// An email address is a series of customizable characters followed by a universal Internet symbol, the at symbol (@), the name of a host server, and a web domain ending (.mx, .com, .org, . net, etc).
/// </summary>
Expand Down Expand Up @@ -162,6 +176,16 @@ protected Customer() { }
[DataMember(Name = "name", IsRequired = true, EmitDefaultValue = true)]
public string Name { get; set; }

/// <summary>
/// It is a parameter that allows to identify the national identification number of the client.
/// </summary>
/// <value>It is a parameter that allows to identify the national identification number of the client.</value>
/*
<example>HEGG560427MVZRRL04</example>
*/
[DataMember(Name = "national_id", EmitDefaultValue = false)]
public string NationalId { get; set; }

/// <summary>
/// Contains details of the payment methods that the customer has active or has used in Conekta
/// </summary>
Expand Down Expand Up @@ -213,12 +237,14 @@ public override string ToString()
sb.Append(" AntifraudInfo: ").Append(AntifraudInfo).Append("\n");
sb.Append(" Corporate: ").Append(Corporate).Append("\n");
sb.Append(" CustomReference: ").Append(CustomReference).Append("\n");
sb.Append(" DateOfBirth: ").Append(DateOfBirth).Append("\n");
sb.Append(" Email: ").Append(Email).Append("\n");
sb.Append(" DefaultPaymentSourceId: ").Append(DefaultPaymentSourceId).Append("\n");
sb.Append(" DefaultShippingContactId: ").Append(DefaultShippingContactId).Append("\n");
sb.Append(" FiscalEntities: ").Append(FiscalEntities).Append("\n");
sb.Append(" Metadata: ").Append(Metadata).Append("\n");
sb.Append(" Name: ").Append(Name).Append("\n");
sb.Append(" NationalId: ").Append(NationalId).Append("\n");
sb.Append(" PaymentSources: ").Append(PaymentSources).Append("\n");
sb.Append(" Phone: ").Append(Phone).Append("\n");
sb.Append(" PlanId: ").Append(PlanId).Append("\n");
Expand Down
Loading

0 comments on commit 8f6c0bd

Please sign in to comment.