Skip to content

Commit

Permalink
Update to Plaid v1.394.0
Browse files Browse the repository at this point in the history
  • Loading branch information
viceroypenguin committed Jul 24, 2023
1 parent cb47d81 commit 4a69dde
Show file tree
Hide file tree
Showing 66 changed files with 627 additions and 65 deletions.
2 changes: 1 addition & 1 deletion plaid-openapi
Submodule plaid-openapi updated 2 files
+791 −56 2020-09-14.yml
+72 −0 CHANGELOG.md
8 changes: 7 additions & 1 deletion src/Plaid/AssetReport/AssetReportGetRequest.cs
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,13 @@ public partial class AssetReportGetRequest : RequestBase
/// <para>A token that can be provided to endpoints such as <c>/asset_report/get</c> or <c>/asset_report/pdf/get</c> to fetch or update an Asset Report.</para>
/// </summary>
[JsonPropertyName("asset_report_token")]
public string AssetReportToken { get; set; } = default!;
public string? AssetReportToken { get; set; } = default!;

/// <summary>
/// <para>The user token associated with the User for which to create an asset report for. The latest asset report associated with the User will be returned</para>
/// </summary>
[JsonPropertyName("user_token")]
public string? UserToken { get; set; } = default!;

/// <summary>
/// <para><c>true</c> if you would like to retrieve the Asset Report with Insights, <c>false</c> otherwise. This field defaults to <c>false</c> if omitted.</para>
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/AssetReport/PlaidClient.cs
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@ public sealed partial class PlaidClient
{
/// <summary>
/// <para>The <c>/asset_report/create</c> endpoint initiates the process of creating an Asset Report, which can then be retrieved by passing the <c>asset_report_token</c> return value to the <c>/asset_report/get</c> or <c>/asset_report/pdf/get</c> endpoints.</para>
/// <para>The Asset Report takes some time to be created and is not available immediately after calling <c>/asset_report/create</c>. When the Asset Report is ready to be retrieved using <c>/asset_report/get</c> or <c>/asset_report/pdf/get</c>, Plaid will fire a <c>PRODUCT_READY</c> webhook. For full details of the webhook schema, see <a href="https://plaid.com/docs/api/products/assets/#webhooks">Asset Report webhooks</a>.</para>
/// <para>The Asset Report takes some time to be created and is not available immediately after calling <c>/asset_report/create</c>. The exact amount of time to create the report will vary depending on how many days of history are requested and will typically range from a few seconds to about one minute. When the Asset Report is ready to be retrieved using <c>/asset_report/get</c> or <c>/asset_report/pdf/get</c>, Plaid will fire a <c>PRODUCT_READY</c> webhook. For full details of the webhook schema, see <a href="https://plaid.com/docs/api/products/assets/#webhooks">Asset Report webhooks</a>.</para>
/// <para>The <c>/asset_report/create</c> endpoint creates an Asset Report at a moment in time. Asset Reports are immutable. To get an updated Asset Report, use the <c>/asset_report/refresh</c> endpoint.</para>
/// </summary>
/// <remarks><see href="https://plaid.com/docs/api/products/assets/#asset_reportcreate" /></remarks>
Expand Down
13 changes: 7 additions & 6 deletions src/Plaid/Converters/WebhookBaseConverter.Map.cs
Original file line number Diff line number Diff line change
Expand Up @@ -13,13 +13,13 @@ public partial class WebhookBaseConverter : JsonConverter<WebhookBase>
[(WebhookType.IdentityVerification, WebhookCode.StepUpdated)] = typeof(IdentityVerificationStepUpdatedWebhook),
[(WebhookType.IdentityVerification, WebhookCode.Retried)] = typeof(IdentityVerificationRetriedWebhook),
[(WebhookType.IdentityVerification, WebhookCode.StatusUpdated)] = typeof(IdentityVerificationStatusUpdatedWebhook),
[(WebhookType.Transactions, WebhookCode.TransactionsRemoved)] = typeof(TransactionsRemovedWebhook),
[(WebhookType.Transactions, WebhookCode.DefaultUpdate)] = typeof(DefaultUpdateWebhook),
[(WebhookType.Transactions, WebhookCode.SyncUpdatesAvailable)] = typeof(SyncUpdatesAvailableWebhook),
[(WebhookType.Transactions, WebhookCode.RecurringTransactionsUpdate)] = typeof(RecurringTransactionsUpdateWebhook),
[(WebhookType.Transactions, WebhookCode.TransactionsRemoved)] = typeof(ProcessorTransactionsRemovedWebhook),
[(WebhookType.Transactions, WebhookCode.DefaultUpdate)] = typeof(ProcessorDefaultUpdateWebhook),
[(WebhookType.Transactions, WebhookCode.SyncUpdatesAvailable)] = typeof(ProcessorSyncUpdatesAvailableWebhook),
[(WebhookType.Transactions, WebhookCode.RecurringTransactionsUpdate)] = typeof(ProcessorRecurringTransactionsUpdateWebhook),
[(WebhookType.Identity, WebhookCode.DefaultUpdate)] = typeof(IdentityDefaultUpdateWebhook),
[(WebhookType.Transactions, WebhookCode.HistoricalUpdate)] = typeof(HistoricalUpdateWebhook),
[(WebhookType.Transactions, WebhookCode.InitialUpdate)] = typeof(InitialUpdateWebhook),
[(WebhookType.Transactions, WebhookCode.HistoricalUpdate)] = typeof(ProcessorHistoricalUpdateWebhook),
[(WebhookType.Transactions, WebhookCode.InitialUpdate)] = typeof(ProcessorInitialUpdateWebhook),
[(WebhookType.Auth, WebhookCode.AutomaticallyVerified)] = typeof(FallbackAuthMicrodepositAutoVerifiedWebhook),
[(WebhookType.Auth, WebhookCode.VerificationExpired)] = typeof(FallbackAuthMicrodepositVerificationExpiredWebhook),
[(WebhookType.Item, WebhookCode.WebhookUpdateAcknowledged)] = typeof(WebhookUpdateAcknowledgedWebhook),
Expand All @@ -35,6 +35,7 @@ public partial class WebhookBaseConverter : JsonConverter<WebhookBase>
[(WebhookType.Transfer, WebhookCode.RecurringTransferSkipped)] = typeof(RecurringTransferSkippedWebhook),
[(WebhookType.Transfer, WebhookCode.RecurringCancelled)] = typeof(RecurringCancelledWebhook),
[(WebhookType.InvestmentsTransactions, WebhookCode.DefaultUpdate)] = typeof(InvestmentsDefaultUpdateWebhook),
[(WebhookType.InvestmentsTransactions, WebhookCode.HistoricalUpdate)] = typeof(InvestmentsHistoricalUpdateWebhook),
[(WebhookType.Holdings, WebhookCode.DefaultUpdate)] = typeof(HoldingsDefaultUpdateWebhook),
[(WebhookType.Partner, WebhookCode.EndCustomerOauthStatusUpdated)] = typeof(PartnerEndCustomerOAuthStatusUpdatedWebhook),
[(WebhookType.Liabilities, WebhookCode.DefaultUpdate)] = typeof(LiabilitiesDefaultUpdateWebhook),
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/AccountAssetsVerificationStatusEnum.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public enum AccountAssetsVerificationStatusEnum
PendingAutomaticVerification,

/// <summary>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the two amounts.</para>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the micro-deposit.</para>
/// </summary>
[EnumMember(Value = "pending_manual_verification")]
PendingManualVerification,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public enum AccountIdentityMatchScoreVerificationStatusEnum
PendingAutomaticVerification,

/// <summary>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the two amounts.</para>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the micro-deposit.</para>
/// </summary>
[EnumMember(Value = "pending_manual_verification")]
PendingManualVerification,
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/AccountIdentityVerificationStatusEnum.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public enum AccountIdentityVerificationStatusEnum
PendingAutomaticVerification,

/// <summary>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the two amounts.</para>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the micro-deposit.</para>
/// </summary>
[EnumMember(Value = "pending_manual_verification")]
PendingManualVerification,
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/AccountVerificationStatusEnum.cs
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,7 @@ public enum AccountVerificationStatusEnum
PendingAutomaticVerification,

/// <summary>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the two amounts.</para>
/// <para>The Item is pending manual micro-deposit verification. Items remain in this state until the user successfully verifies the micro-deposit.</para>
/// </summary>
[EnumMember(Value = "pending_manual_verification")]
PendingManualVerification,
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/AddressMatchScore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Going.Plaid.Entity;
public record AddressMatchScore
{
/// <summary>
/// <para>Match score for address. The score can range from 0 to 100 where 100 is a perfect match and 0 is a no match. If the address is missing from either the API or financial institution, this is null.</para>
/// <para>Match score for address. 100 is a perfect match, 99-90 is a strong match, 89-80 is a partial match, anything below 80 is considered a weak match. Typically, the match threshold should be set to a score of 80 or higher. If the address is missing from either the API or financial institution, this is null.</para>
/// </summary>
[JsonPropertyName("score")]
public int? Score { get; init; } = default!;
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/AssetReportTransaction.cs
Original file line number Diff line number Diff line change
Expand Up @@ -98,7 +98,7 @@ public record AssetReportTransaction

/// <summary>
/// <para>Transaction information specific to inter-bank transfers. If the transaction was not an inter-bank transfer, all fields will be <c>null</c>.</para>
/// <para>If the <c>transactions</c> object was returned by a Transactions endpoint such as <c>/transactions/get</c>, the <c>payment_meta</c> key will always appear, but no data elements are guaranteed. If the <c>transactions</c> object was returned by an Assets endpoint such as <c>/asset_report/get/</c> or <c>/asset_report/pdf/get</c>, this field will only appear in an Asset Report with Insights.</para>
/// <para>If the <c>transactions</c> object was returned by a Transactions endpoint such as <c>/transactions/sync or </c>/transactions/get<c>, the </c>payment_meta<c> key will always appear, but no data elements are guaranteed. If the </c>transactions<c> object was returned by an Assets endpoint such as </c>/asset_report/get/<c> or </c>/asset_report/pdf/get`, this field will only appear in an Asset Report with Insights.</para>
/// </summary>
[JsonPropertyName("payment_meta")]
public Entity.PaymentMeta? PaymentMeta { get; init; } = default!;
Expand Down
3 changes: 3 additions & 0 deletions src/Plaid/Entity/CreditDocumentMetadata.cs
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,9 @@ public record CreditDocumentMetadata

/// <summary>
/// <para>The processing status of the document.</para>
/// <para><c>PROCESSING_COMPLETE</c>: The document was successfully processed.</para>
/// <para><c>DOCUMENT_ERROR</c>: The document could not be processed. Possible causes include: The document was an unacceptable document type such as an offer letter or bank statement, the document image was cropped or blurry, or the document was corrupted.</para>
/// <para><c>UNKNOWN</c> or <c>null</c>: An internal error occurred. If this happens repeatedly, contact support or your Plaid account manager.</para>
/// </summary>
[JsonPropertyName("status")]
public string? Status { get; init; } = default!;
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/EmailAddressMatchScore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Going.Plaid.Entity;
public record EmailAddressMatchScore
{
/// <summary>
/// <para>Match score for normalized email. 100 is a perfect match and 0 is a no match. If the email is missing from either the API or financial institution, this is null.</para>
/// <para>Match score for normalized email. 100 is a perfect match, 99-70 is a partial match (matching the same email with different '+' extensions), anything below 70 is considered a mismatch. Typically, the match threshold should be set to a score of 70 or higher. If the email is missing from either the API or financial institution, this is null.</para>
/// </summary>
[JsonPropertyName("score")]
public int? Score { get; init; } = default!;
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/IdentityVerificationCreateRequestUser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -40,7 +40,7 @@ public class IdentityVerificationCreateRequestUser
public Entity.IdentityVerificationRequestUserName? Name { get; set; } = default!;

/// <summary>
/// <para>Home address for the user.</para>
/// <para>Home address for the user. For more context on this field, see <a href="https://plaid.com/docs/identity-verification/hybrid-input-validation/#input-validation-by-country">Input Validation by Country</a>.</para>
/// </summary>
[JsonPropertyName("address")]
public Entity.UserAddress? Address { get; set; } = default!;
Expand Down
41 changes: 41 additions & 0 deletions src/Plaid/Entity/IdentityVerificationDocumentAddressResponse.cs
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
namespace Going.Plaid.Entity;

/// <summary>
/// <para>The address extracted from the document. The address must at least contain the following fields to be a valid address: <c>street</c>, <c>city</c>, <c>country</c>. If any are missing or unable to be extracted, the address will be null.</para>
/// <para><c>region</c>, and <c>postal_code</c> may be null based on the addressing system. For example:</para>
/// <para>Addresses from the United Kingdom will not include a region</para>
/// <para>Addresses from Hong Kong will not include postal code</para>
/// <para>Note: Optical Character Recognition (OCR) technology may sometimes extract incorrect data from a document.</para>
/// </summary>
public record IdentityVerificationDocumentAddressResponse
{
/// <summary>
/// <para>The full street address extracted from the document.</para>
/// </summary>
[JsonPropertyName("street")]
public string Street { get; init; } = default!;

/// <summary>
/// <para>City extracted from the document.</para>
/// </summary>
[JsonPropertyName("city")]
public string City { get; init; } = default!;

/// <summary>
/// <para>An ISO 3166-2 subdivision code extracted from the document. Related terms would be "state", "province", "prefecture", "zone", "subdivision", etc.</para>
/// </summary>
[JsonPropertyName("region")]
public string? Region { get; init; } = default!;

/// <summary>
/// <para>The postal code extracted from the document. Between 2 and 10 alphanumeric characters. For US-based addresses this must be 5 numeric digits.</para>
/// </summary>
[JsonPropertyName("postal_code")]
public string? PostalCode { get; init; } = default!;

/// <summary>
/// <para>Valid, capitalized, two-letter ISO code representing the country extracted from the document. Must be in ISO 3166-1 alpha-2 form.</para>
/// </summary>
[JsonPropertyName("country")]
public string Country { get; init; } = default!;
}
2 changes: 1 addition & 1 deletion src/Plaid/Entity/IdentityVerificationRequestUser.cs
Original file line number Diff line number Diff line change
Expand Up @@ -39,7 +39,7 @@ public class IdentityVerificationRequestUser
public Entity.IdentityVerificationRequestUserName? Name { get; set; } = default!;

/// <summary>
/// <para>Home address for the user.</para>
/// <para>Home address for the user. For more context on this field, see <a href="https://plaid.com/docs/identity-verification/hybrid-input-validation/#input-validation-by-country">Input Validation by Country</a>.</para>
/// </summary>
[JsonPropertyName("address")]
public Entity.UserAddress? Address { get; set; } = default!;
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/IncomeVerificationCreateRequestOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Going.Plaid.Entity;
public class IncomeVerificationCreateRequestOptions
{
/// <summary>
/// <para>An array of access tokens corresponding to the Items that will be cross-referenced with the product data. Plaid will attempt to correlate transaction history from these Items with data from the user's paystub, such as date and amount. The <c>verification</c> status of the paystub as returned by <c>/income/verification/paystubs/get</c> will indicate if the verification status was successful, or, if not, why it failed. If the <c>transactions</c> product was not initialized for the Items during Link, it will be initialized after this Link session.</para>
/// <para>An array of access tokens corresponding to the Items that will be cross-referenced with the product data. Plaid will attempt to correlate transaction history from these Items with data from the user's paystub, such as date and amount. If the <c>transactions</c> product was not initialized for the Items during Link, it will be initialized after this Link session.</para>
/// </summary>
[JsonPropertyName("access_tokens")]
public IReadOnlyList<string>? AccessTokens { get; set; } = default!;
Expand Down
4 changes: 2 additions & 2 deletions src/Plaid/Entity/Institution.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,13 +6,13 @@ namespace Going.Plaid.Entity;
public record Institution
{
/// <summary>
/// <para>Unique identifier for the institution</para>
/// <para>Unique identifier for the institution. Note that the same institution may have multiple records, each with different institution IDs; for example, if the institution has migrated to OAuth, there may be separate <c>institution_id</c>s for the OAuth and non-OAuth versions of the institution. Institutions that operate in different countries or with multiple login portals may also have separate <c>institution_id</c>s for each country or portal.</para>
/// </summary>
[JsonPropertyName("institution_id")]
public string InstitutionId { get; init; } = default!;

/// <summary>
/// <para>The official name of the institution</para>
/// <para>The official name of the institution.</para>
/// </summary>
[JsonPropertyName("name")]
public string Name { get; init; } = default!;
Expand Down
6 changes: 6 additions & 0 deletions src/Plaid/Entity/InvestmentsTransactionsGetRequestOptions.cs
Original file line number Diff line number Diff line change
Expand Up @@ -22,4 +22,10 @@ public class InvestmentsTransactionsGetRequestOptions
/// </summary>
[JsonPropertyName("offset")]
public int? Offset { get; set; } = default!;

/// <summary>
/// <para>If the Item was not initialized with the investments product via the <c>products</c> array when calling <c>/link/token/create</c>, and <c>async_update</c> is set to true, the initial Investments extraction will happen asynchronously. Plaid will subsequently fire a <c>HISTORICAL_UPDATE</c> webhook when the extraction completes. When <c>false</c>, Plaid will wait to return a response until extraction completion and no <c>HISTORICAL_UPDATE</c> webhook will fire. Note that while the extraction is happening asynchronously, calls to <c>/investments/transactions/get</c> and <c>/investments/refresh</c> will return <c>PRODUCT_NOT_READY</c> errors until the extraction completes.</para>
/// </summary>
[JsonPropertyName("async_update")]
public bool? AsyncUpdate { get; set; } = default!;
}
6 changes: 6 additions & 0 deletions src/Plaid/Entity/LinkDeliverySessionStatus.cs
Original file line number Diff line number Diff line change
Expand Up @@ -17,6 +17,12 @@ public enum LinkDeliverySessionStatus
[EnumMember(Value = "OPENED")]
Opened,

/// <summary>
/// <para>The session has been exited by the user</para>
/// </summary>
[EnumMember(Value = "EXITED")]
Exited,

/// <summary>
/// <para>The session has been completed by the user</para>
/// </summary>
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/LinkTokenCreateRequestUpdate.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Going.Plaid.Entity;
public class LinkTokenCreateRequestUpdate
{
/// <summary>
/// <para>If <c>true</c>, enables <a href="https://plaid.com/docs/link/update-mode/#using-update-mode-to-request-new-accounts">update mode with Account Select</a>.</para>
/// <para>If <c>true</c>, enables <a href="https://plaid.com/docs/link/update-mode/#using-update-mode-to-request-new-accounts">update mode with Account Select</a> for institutions that do not use OAuth, or that use OAuth but do not have their own account selection flow. For institutions that have an OAuth account selection flow (i.e. most OAuth-enabled institutions), update mode with Account Select will always be enabled, regardless of the value of this field.</para>
/// </summary>
[JsonPropertyName("account_selection_enabled")]
public bool? AccountSelectionEnabled { get; set; } = default!;
Expand Down
2 changes: 1 addition & 1 deletion src/Plaid/Entity/NameMatchScore.cs
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ namespace Going.Plaid.Entity;
public record NameMatchScore
{
/// <summary>
/// <para>Represents the match score for name. 100 is a perfect score, 85-99 means a strong match, 50-84 is a partial match, less than 50 is a weak match and 0 is a complete mismatch. If the name is missing from either the API or financial institution, this is null.</para>
/// <para>Match score for name. 100 is a perfect score, 85-99 means a strong match, 84-70 is a partial match, any score less than 70 is a mismatch. Typically, the match threshold should be set to a score of 70 or higher. If the name is missing from either the API or financial institution, this is null.</para>
/// </summary>
[JsonPropertyName("score")]
public int? Score { get; init; } = default!;
Expand Down
Loading

0 comments on commit 4a69dde

Please sign in to comment.