# Changes in the release on 23/05/2023

Below you can find manuals regarding two main functionality enhancements in the upcoming release:

* [Fee enhancements](#fee-enhancements)
* [Charges](#charges)

## Fee enhancements

{% hint style="warning" %}
These enhancements have impact on current implementation, so please make sure to get acquainted with it thoroughly. We encourage you to focus on the 'Use cases' section and to prepare/create the data ASAP to validate them later after migration run on Staging on Wednesday afternoon (17/05/2023).
{% endhint %}

**Changes:**

1. "CURRENCY\_MARKUP" is renamed to "PURCHASE\_FOREIGN\_CURRENCY"&#x20;
2. "PURCHASE\_FOREIGN\_CURRENCY" is applicable to "PURCHASES" in foreign currencies&#x20;
3. &#x20;Introduced a new enum "WITHDRAWAL\_FOREIGN\_CURRENCY" for transaction type in Fees APIs and it is applicable to "WITHDRAWALS" in foreign currencies
4. Allowed definition of fee with currency value as \*\*\* (\*\*\* stands for any currency other than the one(s) supported by the card product)
5. Added description in "transaction\_origin" field that this field is applicable for transaction types WITHDRAWALS, PURCHASES, PURCHASE\_FOREIGN\_CURRENCY & WITHDRAWAL\_FOREIGN\_CURRENCY&#x20;
6. Added description in "currency" field that \*\*\* is applicable for transaction type "PURCHASE\_FOREIGN\_CURRENCY" & WITHDRAWAL\_FOREIGN\_CURRENCY&#x20;

{% code title="Example:" overflow="wrap" %}

```
Single currency card product with base currency of AED.

Fee plan of "transaction_type": "PURCHASE_FOREING_CURRENCY" is linked to the card product, where:
"currency": "***" , 
"type": "FLAT", 
"amount": 5,
"transaction_origin": "ANY".

PURCHASE transaction of amount USD 50 is received.

Transaction amount (USD 50) is converted into AED and deducted from the AED account. Similarly, fee amount (USD 5) is converted into AED and deducted from the AED account.
```

{% endcode %}

What to expect after **migration** run:

1. "CURRENCY\_MARKUP" enum will be changed to "PURCHASE\_FOREIGN\_CURRENCY". It will take on the default currency of \*\*\*.
2. A new fee plan (unique ID) of type "WITHDRAWAL\_FOREIGN\_CURRENCY" is created and linked to the same product to which "PURCHASE\_FOREIGN\_CURRENCY" is initially linked to. It will take on the default currency of \*\*\*.
3. The new fee plan "WITHDRAWAL\_FOREIGN\_CURRENCY" will inherit the same details as that of the existing fee plan "PURCHASE\_FOREIGN\_CURRENCY" except that the fee plan corresponding to "WITHDRAWALS" will have an extra string "\_WITHDRAWAL" in the description field.

&#x20;

**Use cases**:

* A card product with fee plan of type PURCHASE linked to it

After the migration: no impact (fee will be applied on PURCHASE transactions done in base currency - business as usual)

* A card product with multiple fee plans linked to it among which are PURCHASE and CURRENCY\_MARKUP

After the migration:&#x20;

\- CURRENCY\_MARKUP is updated to PURCHASE\_FOREIGN\_CURRENCY

\- a new fee plan of type "WITHDRAWAL\_FOREIGN\_CURRENCY is created and linked to the same card product

\- perform PURCHASE transactions in base currency and confirm the correct fee is being applied \[speaking of "PURCHASE" fee plan]

\- perform PURCHASE transactions in foreign currencies and confirm the correct fee is being applied \[speaking of PURHCASE\_FOREIGN\_CURRENCY]

\- perform WITHDRAWAL transactions in foreign currencies and confirm the correct fee is being applied \[speaking of WITHDRAWAL\_FOREIGN\_CURRENCY]

* "CURRENCY\_MARKUP" is linked to more than one product

After the migration: everything will continue to work normally except that different fee plans of type "WITHDRAWAL\_FOREIGN\_CURRENCY" will be created and linked to the different card products

## Charges

{% hint style="info" %}
This is new functionality, so it does not have impact on current implementation.
{% endhint %}

We added an ability to post card issuance charges so that it can be applied to respective cardholder's account. This will be applied one time only for every new card that is issued.

In Scope:

1\) Personalized physical card is issued first time

2\) Personalized virtual card is issued first time

3\) Bulk card is linked to the user&#x20;

Out of Scope:

If card is replaced then issuance charges shall not be considered.

API Catalog:

The below APIs are exposed in API Catalog:

* [Create charge](https://nymcard.com/docs/api#tag/Charges/operation/createCharges)
* [Update charge](https://nymcard.com/docs/api#tag/Charges/operation/updateCharges)
* [Get a specific charge](https://nymcard.com/docs/api#tag/Charges/operation/getCharges)
* [Get list of charges](https://nymcard.com/docs/api#tag/Charges/operation/listCharges)
* [Link charges to card product](https://nymcard.com/docs/api#tag/Card-Products/operation/linkCharges) (you can link multiple charges at once)
* [Unlink charges from card product](https://nymcard.com/docs/api#tag/Card-Products/operation/unlinkCharges) (you can unlink multiple charges at once)
* [Get list of charges related to card product](https://nymcard.com/docs/api#tag/Card-Products/operation/getCharges)

Note, that supported enums for 'charge\_type' are "PHYSICAL\_CARD\_ISSUANCE" & "VIRTUAL\_CARD\_ISSUANCE".

Webhooks

New [webhook](https://docs.nymcard.com/get-started/webhooks/webhooks-samples#charges-webhook) event/enum "CHARGE\_APPLIED" is addded. Below you can find webhook sample:

```
{
  "event": "CHARGE_APPLIED",
  "charge_applied": {
    "id": "0fcf8c07-ae35-4243-890d-0a39b2618578",
    "description": "charges dev 28",
    "currency": "AED",
    "amount": 2,
    "card_id": "f3bd66fd-80d5-4c7c-90e2-ac062c923ff0",
    "account_id": "f3bd66fd-80d5-4c7c-90e2-ac062c923ff0",
    "charge_id": "CHARGEAHSAN19",
    "charge_type": "PHYSICAL_CARD_ISSUANCE"
  }
}
```

Cron Job:

A cron will run on a daily basis to pick up those charges in "PENDING" status and apply the charge amount to cardholders' accounts.


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://docs.nymcard.com/get-started/release-announcements/changes-in-the-release-on-23-05-2023.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
