Skip to content

Commit

Permalink
Changes generated by 4892b2c12379d81b416e147bd7e67f48099968a2
Browse files Browse the repository at this point in the history
This commit was automatically created from gocardless/gocardless-dotnet-template@4892b2c
by the `push-files` action.

Workflow run: https://github.com/gocardless/gocardless-dotnet-template/actions/runs/9268823153
  • Loading branch information
gocardless-ci-robot[bot] committed May 28, 2024
1 parent c8192a2 commit 41aa9f9
Showing 1 changed file with 22 additions and 8 deletions.
30 changes: 22 additions & 8 deletions GoCardless/Services/PayerThemeService.cs
Original file line number Diff line number Diff line change
Expand Up @@ -36,22 +36,18 @@ public PayerThemeService(GoCardlessClient goCardlessClient)
/// Creates a new payer theme associated with a creditor. If a creditor
/// already has payer themes, this will update the existing payer theme
/// linked to the creditor.
/// </summary>
/// <param name="identity">Unique identifier, beginning with "CR".</param>
/// </summary>
/// <param name="request">An optional `PayerThemeCreateForCreditorRequest` representing the body for this create_for_creditor request.</param>
/// <param name="customiseRequestMessage">An optional `RequestSettings` allowing you to configure the request</param>
/// <returns>A single payer theme resource</returns>
public Task<PayerThemeResponse> CreateForCreditorAsync(string identity, PayerThemeCreateForCreditorRequest request = null, RequestSettings customiseRequestMessage = null)
public Task<PayerThemeResponse> CreateForCreditorAsync(PayerThemeCreateForCreditorRequest request = null, RequestSettings customiseRequestMessage = null)
{
request = request ?? new PayerThemeCreateForCreditorRequest();
if (identity == null) throw new ArgumentException(nameof(identity));

var urlParams = new List<KeyValuePair<string, object>>
{
new KeyValuePair<string, object>("identity", identity),
};
{};

return _goCardlessClient.ExecuteAsync<PayerThemeResponse>("POST", "/creditors/:identity/branding/payer_themes", urlParams, request, null, "payer_themes", customiseRequestMessage);
return _goCardlessClient.ExecuteAsync<PayerThemeResponse>("POST", "/branding/payer_themes", urlParams, request, null, "payer_themes", customiseRequestMessage);
}
}

Expand Down Expand Up @@ -87,6 +83,24 @@ public class PayerThemeCreateForCreditorRequest
/// </summary>
[JsonProperty("link_text_colour")]
public string LinkTextColour { get; set; }

/// <summary>
/// Linked resources.
/// </summary>
[JsonProperty("links")]
public PayerThemeLinks Links { get; set; }
/// <summary>
/// Linked resources for a PayerTheme.
/// </summary>
public class PayerThemeLinks
{

/// <summary>
/// ID of the creditor the payer theme belongs to
/// </summary>
[JsonProperty("creditor")]
public string Creditor { get; set; }
}
}

/// <summary>
Expand Down

0 comments on commit 41aa9f9

Please sign in to comment.