From 27be536ad44f4b1f0ad2c37cb384c3cd30a89ec7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?C=C3=A1ssio=20Marcos=20Goulart?= <3228151+CassioMG@users.noreply.github.com> Date: Thu, 5 May 2022 12:26:41 -0300 Subject: [PATCH] Make lang format consistent in all places (#1192) --- ecosystem/sep-0024.md | 17 +++++++++-------- 1 file changed, 9 insertions(+), 8 deletions(-) diff --git a/ecosystem/sep-0024.md b/ecosystem/sep-0024.md index 88cd3d656..6704b009f 100644 --- a/ecosystem/sep-0024.md +++ b/ecosystem/sep-0024.md @@ -7,7 +7,7 @@ Author: SDF Status: Active Created: 2019-09-18 Updated: 2022-05-05 -Version 2.2.2 +Version 2.3.0 ``` ## Simple Summary @@ -184,7 +184,7 @@ Name | Type | Description `memo` | string | (optional) Value of memo to attach to transaction, for `hash` this should be base64-encoded. Because a memo can be specified in the SEP-10 JWT for [Shared Accounts](#shared-omnibus-or-pooled-accounts), this field can be different than the value included in the SEP-10 JWT. For example, a client application could use the value passed for this parameter as a reference number used to match payments made to `account`. `wallet_name` | string | (optional) In communications / pages about the deposit, anchor should display the wallet name to the user to explain where funds are going. `wallet_url` | string | (optional) Anchor should link to this when notifying the user that the transaction has completed. -`lang` | string | (optional) Defaults to `en`. Language code specified using [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1). `error` fields in the response, as well as the interactive flow UI and any other user-facing strings returned for this transaction should be in this language. +`lang` | string | (optional) Defaults to `en`. Language code specified using [RFC 4646](https://datatracker.ietf.org/doc/html/rfc4646) which means it can also accept locale in the format `en-US`. `error` fields in the response, as well as the interactive flow UI and any other user-facing strings returned for this transaction should be in this language. `claimable_balance_supported` | boolean | (optional) True if the client supports receiving deposit transactions as a claimable balance, false otherwise. Additionally, any [SEP-9](sep-0009.md) parameters may be passed as well to make the onboarding experience simpler. @@ -323,7 +323,7 @@ Name | Type | Description `memo_type` | string | (**deprecated**, optional) Type of `memo`. One of `text`, `id` or `hash`. Deprecated because memos used to identify users of the same Stellar account should always be of type of `id`. `wallet_name` | string | (optional) In communications / pages about the withdrawal, anchor should display the wallet name to the user to explain where funds are coming from. `wallet_url` | string | (optional) Anchor can show this to the user when referencing the wallet involved in the withdrawal (ex. in the anchor's transaction history). -`lang` | string | (optional) Defaults to `en`. Language code specified using [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1). `error` fields in the response, as well as the interactive flow UI and any other user-facing strings returned for this transaction should be in this language. +`lang` | string | (optional) Defaults to `en`. Language code specified using [RFC 4646](https://datatracker.ietf.org/doc/html/rfc4646) which means it can also accept locale in the format `en-US`. `error` fields in the response, as well as the interactive flow UI and any other user-facing strings returned for this transaction should be in this language. Additionally, any [SEP-9](sep-0009.md) parameters may be passed as well to make the onboarding experience simpler. @@ -514,7 +514,7 @@ Request parameters: Name | Type | Description -----|------|------------ -`lang` | string | (optional) Defaults to `en`. Language code specified using [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1). `description` fields in the response should be in this language. +`lang` | string | (optional) Defaults to `en`. Language code specified using [RFC 4646](https://datatracker.ietf.org/doc/html/rfc4646) which means it can also accept locale in the format `en-US`. `description` fields in the response should be in this language. ### Response @@ -663,7 +663,7 @@ Name | Type | Description `limit` | int | (optional) The response should contain at most `limit` transactions. `kind` | string | (optional) The kind of transaction that is desired. Should be either `deposit` or `withdrawal`. `paging_id` | string | (optional) The response should contain transactions starting prior to this ID (exclusive). -`lang` | string | (optional) Defaults to `en`. Language code specified using [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1). +`lang` | string | (optional) Defaults to `en`. Language code specified using [RFC 4646](https://datatracker.ietf.org/doc/html/rfc4646) which means it can also accept locale in the format `en-US`. On success the endpoint should return `200 OK` HTTP status code and a JSON object with the following fields: @@ -690,7 +690,7 @@ Name | Type | Description `amount_fee` | string | Amount of fee charged by anchor. `amount_fee_asset` | string | (optional) The asset in which fees are calculated in. Must be present if the deposit/withdraw was made using non-equivalent assets. The value must be in [SEP-38 Asset Identification Format](sep-0038.md#asset-identification-format). See the [Asset Exchanges](#asset-exchanges) section for more information. `started_at` | UTC ISO 8601 string | Start date and time of transaction. -`completed_at` | UTC ISO 8601 string | Completion date and time of transaction. Assigned null for in-progress transactions. +`completed_at` | UTC ISO 8601 string | (optional) Completion date and time of transaction. `stellar_transaction_id` | string | transaction_id on Stellar network of the transfer that either completed the deposit or started the withdrawal. `external_transaction_id` | string | (optional) ID of transaction on external network that either started the deposit or completed the withdrawal. `message` | string | (optional) Human readable explanation of transaction status, if needed. @@ -870,7 +870,7 @@ Name | Type | Description `id` | string | (optional) The id of the transaction. `stellar_transaction_id` | (optional) string | The stellar transaction id of the transaction. `external_transaction_id` | (optional) string | The external transaction id of the transaction. -`lang` | string | (optional) Defaults to `en`. Language code specified using [ISO 639-1](https://en.wikipedia.org/wiki/ISO_639-1). +`lang` | string | (optional) Defaults to `en`. Language code specified using [RFC 4646](https://datatracker.ietf.org/doc/html/rfc4646) which means it can also accept locale in the format `en-US`. One of `id`, `stellar_transaction_id` or `external_transaction_id` is required. @@ -937,5 +937,6 @@ There is a small set of changes when upgrading from SEP-6 to SEP-24. * Solar wallet: https://solarwallet.io ## Changelog - +* `v2.3.0`: Change `lang` format from [ISO639-1] to [RFC4646] which is a superset of [ISO639-1]. Add `lang` field to GET `/transactions` and `/transaction`. ([#1191](https://github.com/stellar/stellar-protocol/pull/1191)) +* `v2.2.1`: Make `completed_at` field optional. ([#1185](https://github.com/stellar/stellar-protocol/pull/1185)) * `v2.2.0`: Deprecate refunded boolean. Add refund object to transaction records. ([#1128](https://github.com/stellar/stellar-protocol/pull/1128))