├── CODE_OF_CONDUCT.md ├── CONTIBUTUNG.md ├── LICENSE.md ├── README.md ├── api ├── README.md ├── application-interfaces.yaml └── ledger-interfaces.yaml ├── schemas └── README.md └── static ├── create_identity.png └── finternetApiSpec.png /CODE_OF_CONDUCT.md: -------------------------------------------------------------------------------- 1 | # Community Code of Conduct 2 | 3 | ## Our Pledge 4 | 5 | We as members, contributors, and leaders pledge to make participation in our 6 | community a harassment-free experience for everyone, regardless of age, body 7 | size, visible or invisible disability, ethnicity, sex characteristics, gender 8 | identity and expression, level of experience, education, socio-economic status, 9 | nationality, personal appearance, race, religion, or sexual identity 10 | and orientation. 11 | 12 | We pledge to act and interact in ways that contribute to an open, welcoming, 13 | diverse, inclusive, and healthy community. 14 | 15 | ## Our Standards 16 | 17 | Examples of behavior that contributes to a positive environment for our 18 | community include: 19 | 20 | * Demonstrating empathy and kindness toward other people 21 | * Being respectful of differing opinions, viewpoints, and experiences 22 | * Giving and gracefully accepting constructive feedback 23 | * Accepting responsibility and apologizing to those affected by our mistakes, 24 | and learning from the experience 25 | * Focusing on what is best not just for us as individuals, but for the 26 | overall community 27 | 28 | Examples of unacceptable behavior include: 29 | 30 | * The use of sexualized language or imagery, and sexual attention or 31 | advances of any kind 32 | * Trolling, insulting or derogatory comments, and personal or political attacks 33 | * Public or private harassment 34 | * Publishing others' private information, such as a physical or email 35 | address, without their explicit permission 36 | * Other conduct which could reasonably be considered inappropriate in a 37 | professional setting 38 | 39 | ## Enforcement Responsibilities 40 | 41 | Community leaders are responsible for clarifying and enforcing our standards of 42 | acceptable behavior and will take appropriate and fair corrective action in 43 | response to any behavior that they deem inappropriate, threatening, offensive, 44 | or harmful. 45 | 46 | Community leaders have the right and responsibility to remove, edit, or reject 47 | comments, commits, code, wiki edits, issues, and other contributions that are 48 | not aligned to this Code of Conduct, and will communicate reasons for moderation 49 | decisions when appropriate. 50 | 51 | ## Scope 52 | 53 | This Code of Conduct applies within all community spaces, and also applies when 54 | an individual is officially representing the community in public spaces. 55 | Examples of representing our community include using an official e-mail address, 56 | posting via an official social media account, or acting as an appointed 57 | representative at an online or offline event. 58 | 59 | ## Enforcement 60 | 61 | Instances of abusive, harassing, or otherwise unacceptable behavior may be 62 | reported to the community leaders responsible for enforcement at 63 | Issue Tracker. 64 | All complaints will be reviewed and investigated promptly and fairly. 65 | 66 | All community leaders are obligated to respect the privacy and security of the 67 | reporter of any incident. 68 | 69 | ## Enforcement Guidelines 70 | 71 | Community leaders will follow these Community Impact Guidelines in determining 72 | the consequences for any action they deem in violation of this Code of Conduct: 73 | 74 | ### 1. Correction 75 | 76 | **Community Impact**: Use of inappropriate language or other behavior deemed 77 | unprofessional or unwelcome in the community. 78 | 79 | **Consequence**: A private, written warning from community leaders, providing 80 | clarity around the nature of the violation and an explanation of why the 81 | behavior was inappropriate. A public apology may be requested. 82 | 83 | ### 2. Warning 84 | 85 | **Community Impact**: A violation through a single incident or series 86 | of actions. 87 | 88 | **Consequence**: A warning with consequences for continued behavior. No 89 | interaction with the people involved, including unsolicited interaction with 90 | those enforcing the Code of Conduct, for a specified period of time. This 91 | includes avoiding interactions in community spaces as well as external channels 92 | like social media. Violating these terms may lead to a temporary or 93 | permanent ban. 94 | 95 | ### 3. Temporary Ban 96 | 97 | **Community Impact**: A serious violation of community standards, including 98 | sustained inappropriate behavior. 99 | 100 | **Consequence**: A temporary ban from any sort of interaction or public 101 | communication with the community for a specified period of time. No public or 102 | private interaction with the people involved, including unsolicited interaction 103 | with those enforcing the Code of Conduct, is allowed during this period. 104 | Violating these terms may lead to a permanent ban. 105 | 106 | ### 4. Permanent Ban 107 | 108 | **Community Impact**: Demonstrating a pattern of violation of community 109 | standards, including sustained inappropriate behavior, harassment of an 110 | individual, or aggression toward or disparagement of classes of individuals. 111 | 112 | **Consequence**: A permanent ban from any sort of public interaction within 113 | the community. 114 | 115 | ## Attribution 116 | 117 | This Code of Conduct is adapted from the [Contributor Covenant][homepage], 118 | version 2.0, available at 119 | https://www.contributor-covenant.org/version/2/0/code_of_conduct.html. 120 | 121 | Community Impact Guidelines were inspired by [Mozilla's code of conduct 122 | enforcement ladder](https://github.com/mozilla/diversity). 123 | 124 | [homepage]: https://www.contributor-covenant.org 125 | 126 | For answers to common questions about this code of conduct, see the FAQ at 127 | https://www.contributor-covenant.org/faq. Translations are available at 128 | https://www.contributor-covenant.org/translations. 129 | -------------------------------------------------------------------------------- /CONTIBUTUNG.md: -------------------------------------------------------------------------------- 1 | # Contributing to CONTRIBUTING.md 2 | 3 | First off, thanks for taking the time to contribute! ❤️ 4 | 5 | All types of contributions are encouraged and valued. See the [Table of Contents](#table-of-contents) for different ways to help and details about how this project handles them. Please make sure to read the relevant section before making your contribution. It will make it a lot easier for us maintainers and smooth out the experience for all involved. The community looks forward to your contributions. 🎉 6 | 7 | > And if you like the project, but just don't have time to contribute, that's fine. There are other easy ways to support the project and show your appreciation, which we would also be very happy about: 8 | > - Star the project 9 | > - Tweet about it 10 | > - Refer this project in your project's readme 11 | > - Mention the project at local meetups and tell your friends/colleagues 12 | 13 | 14 | ## Table of Contents 15 | 16 | - [Code of Conduct](#code-of-conduct) 17 | - [I Have a Question](#i-have-a-question) 18 | - [I Want To Contribute](#i-want-to-contribute) 19 | - [Reporting Bugs](#reporting-bugs) 20 | - [Suggesting Enhancements](#suggesting-enhancements) 21 | - [Your First Code Contribution](#your-first-code-contribution) 22 | - [Improving The Documentation](#improving-the-documentation) 23 | - [Styleguides](#styleguides) 24 | - [Commit Messages](#commit-messages) 25 | - [Join The Project Team](#join-the-project-team) 26 | 27 | 28 | ## Code of Conduct 29 | 30 | This project and everyone participating in it is governed by the 31 | [CONTRIBUTING.md Code of Conduct](blob/master/CODE_OF_CONDUCT.md). 32 | By participating, you are expected to uphold this code. 33 | 34 | 35 | ## I Have a Question 36 | 37 | > If you want to ask a question, we assume that you have read the available documentation. 38 | 39 | Before you ask a question, it is best to search for existing [Issues](/issues) that might help you. 40 | In case you have found a suitable issue and still need clarification, you can write your question in this issue. 41 | It is also advisable to search within our Discord channel and on the internet for answers first. 42 | 43 | If you then still feel the need to ask a question and need clarification, we recommend the following: 44 | 45 | - Join our Discord and ask under an appropriate channel there 46 | - If it is an issue that is new, open an [Issue](/issues/new). 47 | - Provide as much context as you can about what you're running into. 48 | 49 | This will help the community members to answer you or take care of the issue as soon as possible. 50 | Remeber that community members are people like you and hence respecting their time and effort is important. 51 | 52 | 53 | 54 | ## I Want To Contribute 55 | 56 | > ### Legal Notice 57 | > When contributing to this project, you must agree that you have authored 100% of the content, that you have the necessary rights to the content and that the content you contribute may be provided under the project license. 58 | 59 | ### Reporting Bugs 60 | 61 | 62 | #### Before Submitting a Bug Report 63 | 64 | A good bug report shouldn't leave others needing to chase you up for more information. Therefore, we ask you to investigate carefully, collect information and describe the issue in detail in your report. Please complete the following steps in advance to help us fix any potential bug as fast as possible. 65 | 66 | - Make sure that you are using the latest version. 67 | - Determine if your bug is really a bug and not an error on your side e.g. using incompatible environment components/versions (Make sure that you have read the [documentation](). If you are looking for support, you might want to check [this section](#i-have-a-question)). 68 | - To see if other users have experienced (and potentially already solved) the same issue you are having, check if there is not already a bug report existing for your bug or error in the [bug tracker](issues?q=label%3Abug). 69 | - Also make sure to search the internet (including Stack Overflow) to see if users outside of the GitHub community have discussed the issue. 70 | - Collect information about the bug: 71 | - Stack trace (Traceback) 72 | - specify your environment details and versions (OS, compilers, SDKs, tools, etc.) 73 | - Possibly your input and the output 74 | - Can you reliably reproduce the issue? And can you also reproduce it with older versions? 75 | 76 | 77 | #### How Do I Submit a Good Bug Report? 78 | 79 | > You must never report security related issues, vulnerabilities or bugs including sensitive information to the issue tracker, or elsewhere in public. Instead sensitive bugs must be sent by email to <>. 80 | 81 | 82 | We use GitHub issues to track bugs and errors. If you run into an issue with the project: 83 | 84 | - Open an [Issue](/issues/new). (Since we can't be sure at this point whether it is a bug or not, we ask you not to talk about a bug yet and not to label the issue.) 85 | - Explain the behavior you would expect and the actual behavior. 86 | - Please provide as much context as possible and describe the *reproduction steps* that someone else can follow to recreate the issue on their own. This usually includes your code. For good bug reports you should isolate the problem and create a reduced test case. 87 | - Provide the information you collected in the previous section. 88 | 89 | Once it's filed: 90 | 91 | - The project team will label the issue accordingly. 92 | - A team member will try to reproduce the issue with your provided steps. If there are no reproduction steps or no obvious way to reproduce the issue, the team will ask you for those steps and mark the issue as `needs-repro`. Bugs with the `needs-repro` tag will not be addressed until they are reproduced. 93 | - If the team is able to reproduce the issue, it will be marked `needs-fix`, as well as possibly other tags (such as `critical`), and the issue will be left to be [implemented by someone](#your-first-code-contribution). 94 | 95 | 96 | 97 | 98 | ### Suggesting Enhancements 99 | 100 | This section guides you through submitting an enhancement suggestion for CONTRIBUTING.md, **including completely new features and minor improvements to existing functionality**. Following these guidelines will help maintainers and the community to understand your suggestion and find related suggestions. 101 | 102 | 103 | #### Before Submitting an Enhancement 104 | 105 | - Make sure that you are using the latest version. 106 | - Read the [documentation]() carefully and find out if the functionality is already covered, maybe by an individual configuration. 107 | - Perform a [search](/issues) to see if the enhancement has already been suggested. If it has, add a comment to the existing issue instead of opening a new one. 108 | - Find out whether your idea fits with the scope and aims of the project. It's up to you to make a strong case to convince the project's developers of the merits of this feature. Keep in mind that we want features that will be useful to the majority of our users and not just a small subset. If you're just targeting a minority of users, consider writing an add-on/plugin library. 109 | 110 | 111 | #### How Do I Submit a Good Enhancement Suggestion? 112 | 113 | Enhancement suggestions are tracked as [GitHub issues](/issues). 114 | 115 | - Use a **clear and descriptive title** for the issue to identify the suggestion. 116 | - Provide a **step-by-step description of the suggested enhancement** in as many details as possible. 117 | - **Describe the current behavior** and **explain which behavior you expected to see instead** and why. At this point you can also tell which alternatives do not work for you. 118 | - You may want to **include screenshots and animated GIFs** which help you demonstrate the steps or point out the part which the suggestion is related to. You can use [this tool](https://www.cockos.com/licecap/) to record GIFs on macOS and Windows, and [this tool](https://github.com/colinkeenan/silentcast) or [this tool](https://github.com/GNOME/byzanz) on Linux. 119 | - **Explain why this enhancement would be useful** to most CONTRIBUTING.md users. You may also want to point out the other projects that solved it better and which could serve as inspiration. 120 | 121 | 122 | 123 | ### Your First Code Contribution 124 | 125 | 126 | ### Improving The Documentation 127 | 128 | 129 | ## Styleguides 130 | ### Commit Messages 131 | 132 | 133 | ## Join The Project Team 134 | 135 | 136 | 137 | ## Attribution 138 | This guide is based on the **contributing.md**. [Make your own](https://contributing.md/)! 139 | -------------------------------------------------------------------------------- /LICENSE.md: -------------------------------------------------------------------------------- 1 | ## creative commons 2 | 3 | # Attribution-NonCommercial-ShareAlike 4.0 International 4 | 5 | Creative Commons Corporation (“Creative Commons”) is not a law firm and does not provide legal services or legal advice. Distribution of Creative Commons public licenses does not create a lawyer-client or other relationship. Creative Commons makes its licenses and related information available on an “as-is” basis. Creative Commons gives no warranties regarding its licenses, any material licensed under their terms and conditions, or any related information. Creative Commons disclaims all liability for damages resulting from their use to the fullest extent possible. 6 | 7 | ### Using Creative Commons Public Licenses 8 | 9 | Creative Commons public licenses provide a standard set of terms and conditions that creators and other rights holders may use to share original works of authorship and other material subject to copyright and certain other rights specified in the public license below. The following considerations are for informational purposes only, are not exhaustive, and do not form part of our licenses. 10 | 11 | * __Considerations for licensors:__ Our public licenses are intended for use by those authorized to give the public permission to use material in ways otherwise restricted by copyright and certain other rights. Our licenses are irrevocable. Licensors should read and understand the terms and conditions of the license they choose before applying it. Licensors should also secure all rights necessary before applying our licenses so that the public can reuse the material as expected. Licensors should clearly mark any material not subject to the license. This includes other CC-licensed material, or material used under an exception or limitation to copyright. [More considerations for licensors](http://wiki.creativecommons.org/Considerations_for_licensors_and_licensees#Considerations_for_licensors). 12 | 13 | * __Considerations for the public:__ By using one of our public licenses, a licensor grants the public permission to use the licensed material under specified terms and conditions. If the licensor’s permission is not necessary for any reason–for example, because of any applicable exception or limitation to copyright–then that use is not regulated by the license. Our licenses grant only permissions under copyright and certain other rights that a licensor has authority to grant. Use of the licensed material may still be restricted for other reasons, including because others have copyright or other rights in the material. A licensor may make special requests, such as asking that all changes be marked or described. Although not required by our licenses, you are encouraged to respect those requests where reasonable. [More considerations for the public](http://wiki.creativecommons.org/Considerations_for_licensors_and_licensees#Considerations_for_licensees). 14 | 15 | ## Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License 16 | 17 | By exercising the Licensed Rights (defined below), You accept and agree to be bound by the terms and conditions of this Creative Commons Attribution-NonCommercial-ShareAlike 4.0 International Public License ("Public License"). To the extent this Public License may be interpreted as a contract, You are granted the Licensed Rights in consideration of Your acceptance of these terms and conditions, and the Licensor grants You such rights in consideration of benefits the Licensor receives from making the Licensed Material available under these terms and conditions. 18 | 19 | ### Section 1 – Definitions. 20 | 21 | a. __Adapted Material__ means material subject to Copyright and Similar Rights that is derived from or based upon the Licensed Material and in which the Licensed Material is translated, altered, arranged, transformed, or otherwise modified in a manner requiring permission under the Copyright and Similar Rights held by the Licensor. For purposes of this Public License, where the Licensed Material is a musical work, performance, or sound recording, Adapted Material is always produced where the Licensed Material is synched in timed relation with a moving image. 22 | 23 | b. __Adapter's License__ means the license You apply to Your Copyright and Similar Rights in Your contributions to Adapted Material in accordance with the terms and conditions of this Public License. 24 | 25 | c. __BY-NC-SA Compatible License__ means a license listed at [creativecommons.org/compatiblelicenses](http://creativecommons.org/compatiblelicenses), approved by Creative Commons as essentially the equivalent of this Public License. 26 | 27 | d. __Copyright and Similar Rights__ means copyright and/or similar rights closely related to copyright including, without limitation, performance, broadcast, sound recording, and Sui Generis Database Rights, without regard to how the rights are labeled or categorized. For purposes of this Public License, the rights specified in Section 2(b)(1)-(2) are not Copyright and Similar Rights. 28 | 29 | e. __Effective Technological Measures__ means those measures that, in the absence of proper authority, may not be circumvented under laws fulfilling obligations under Article 11 of the WIPO Copyright Treaty adopted on December 20, 1996, and/or similar international agreements. 30 | 31 | f. __Exceptions and Limitations__ means fair use, fair dealing, and/or any other exception or limitation to Copyright and Similar Rights that applies to Your use of the Licensed Material. 32 | 33 | g. __License Elements__ means the license attributes listed in the name of a Creative Commons Public License. The License Elements of this Public License are Attribution, NonCommercial, and ShareAlike. 34 | 35 | h. __Licensed Material__ means the artistic or literary work, database, or other material to which the Licensor applied this Public License. 36 | 37 | i. __Licensed Rights__ means the rights granted to You subject to the terms and conditions of this Public License, which are limited to all Copyright and Similar Rights that apply to Your use of the Licensed Material and that the Licensor has authority to license. 38 | 39 | h. __Licensor__ means the individual(s) or entity(ies) granting rights under this Public License. 40 | 41 | i. __NonCommercial__ means not primarily intended for or directed towards commercial advantage or monetary compensation. For purposes of this Public License, the exchange of the Licensed Material for other material subject to Copyright and Similar Rights by digital file-sharing or similar means is NonCommercial provided there is no payment of monetary compensation in connection with the exchange. 42 | 43 | j. __Share__ means to provide material to the public by any means or process that requires permission under the Licensed Rights, such as reproduction, public display, public performance, distribution, dissemination, communication, or importation, and to make material available to the public including in ways that members of the public may access the material from a place and at a time individually chosen by them. 44 | 45 | k. __Sui Generis Database Rights__ means rights other than copyright resulting from Directive 96/9/EC of the European Parliament and of the Council of 11 March 1996 on the legal protection of databases, as amended and/or succeeded, as well as other essentially equivalent rights anywhere in the world. 46 | 47 | l. __You__ means the individual or entity exercising the Licensed Rights under this Public License. Your has a corresponding meaning. 48 | 49 | ### Section 2 – Scope. 50 | 51 | a. ___License grant.___ 52 | 53 | 1. Subject to the terms and conditions of this Public License, the Licensor hereby grants You a worldwide, royalty-free, non-sublicensable, non-exclusive, irrevocable license to exercise the Licensed Rights in the Licensed Material to: 54 | 55 | A. reproduce and Share the Licensed Material, in whole or in part, for NonCommercial purposes only; and 56 | 57 | B. produce, reproduce, and Share Adapted Material for NonCommercial purposes only. 58 | 59 | 2. __Exceptions and Limitations.__ For the avoidance of doubt, where Exceptions and Limitations apply to Your use, this Public License does not apply, and You do not need to comply with its terms and conditions. 60 | 61 | 3. __Term.__ The term of this Public License is specified in Section 6(a). 62 | 63 | 4. __Media and formats; technical modifications allowed.__ The Licensor authorizes You to exercise the Licensed Rights in all media and formats whether now known or hereafter created, and to make technical modifications necessary to do so. The Licensor waives and/or agrees not to assert any right or authority to forbid You from making technical modifications necessary to exercise the Licensed Rights, including technical modifications necessary to circumvent Effective Technological Measures. For purposes of this Public License, simply making modifications authorized by this Section 2(a)(4) never produces Adapted Material. 64 | 65 | 5. __Downstream recipients.__ 66 | 67 | A. __Offer from the Licensor – Licensed Material.__ Every recipient of the Licensed Material automatically receives an offer from the Licensor to exercise the Licensed Rights under the terms and conditions of this Public License. 68 | 69 | B. __Additional offer from the Licensor – Adapted Material.__ Every recipient of Adapted Material from You automatically receives an offer from the Licensor to exercise the Licensed Rights in the Adapted Material under the conditions of the Adapter’s License You apply. 70 | 71 | C. __No downstream restrictions.__ You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, the Licensed Material if doing so restricts exercise of the Licensed Rights by any recipient of the Licensed Material. 72 | 73 | 6. __No endorsement.__ Nothing in this Public License constitutes or may be construed as permission to assert or imply that You are, or that Your use of the Licensed Material is, connected with, or sponsored, endorsed, or granted official status by, the Licensor or others designated to receive attribution as provided in Section 3(a)(1)(A)(i). 74 | 75 | b. ___Other rights.___ 76 | 77 | 1. Moral rights, such as the right of integrity, are not licensed under this Public License, nor are publicity, privacy, and/or other similar personality rights; however, to the extent possible, the Licensor waives and/or agrees not to assert any such rights held by the Licensor to the limited extent necessary to allow You to exercise the Licensed Rights, but not otherwise. 78 | 79 | 2. Patent and trademark rights are not licensed under this Public License. 80 | 81 | 3. To the extent possible, the Licensor waives any right to collect royalties from You for the exercise of the Licensed Rights, whether directly or through a collecting society under any voluntary or waivable statutory or compulsory licensing scheme. In all other cases the Licensor expressly reserves any right to collect such royalties, including when the Licensed Material is used other than for NonCommercial purposes. 82 | 83 | ### Section 3 – License Conditions. 84 | 85 | Your exercise of the Licensed Rights is expressly made subject to the following conditions. 86 | 87 | a. ___Attribution.___ 88 | 89 | 1. If You Share the Licensed Material (including in modified form), You must: 90 | 91 | A. retain the following if it is supplied by the Licensor with the Licensed Material: 92 | 93 | i. identification of the creator(s) of the Licensed Material and any others designated to receive attribution, in any reasonable manner requested by the Licensor (including by pseudonym if designated); 94 | 95 | ii. a copyright notice; 96 | 97 | iii. a notice that refers to this Public License; 98 | 99 | iv. a notice that refers to the disclaimer of warranties; 100 | 101 | v. a URI or hyperlink to the Licensed Material to the extent reasonably practicable; 102 | 103 | B. indicate if You modified the Licensed Material and retain an indication of any previous modifications; and 104 | 105 | C. indicate the Licensed Material is licensed under this Public License, and include the text of, or the URI or hyperlink to, this Public License. 106 | 107 | 2. You may satisfy the conditions in Section 3(a)(1) in any reasonable manner based on the medium, means, and context in which You Share the Licensed Material. For example, it may be reasonable to satisfy the conditions by providing a URI or hyperlink to a resource that includes the required information. 108 | 109 | 3. If requested by the Licensor, You must remove any of the information required by Section 3(a)(1)(A) to the extent reasonably practicable. 110 | 111 | b. ___ShareAlike.___ 112 | 113 | In addition to the conditions in Section 3(a), if You Share Adapted Material You produce, the following conditions also apply. 114 | 115 | 1. The Adapter’s License You apply must be a Creative Commons license with the same License Elements, this version or later, or a BY-NC-SA Compatible License. 116 | 117 | 2. You must include the text of, or the URI or hyperlink to, the Adapter's License You apply. You may satisfy this condition in any reasonable manner based on the medium, means, and context in which You Share Adapted Material. 118 | 119 | 3. You may not offer or impose any additional or different terms or conditions on, or apply any Effective Technological Measures to, Adapted Material that restrict exercise of the rights granted under the Adapter's License You apply. 120 | 121 | ### Section 4 – Sui Generis Database Rights. 122 | 123 | Where the Licensed Rights include Sui Generis Database Rights that apply to Your use of the Licensed Material: 124 | 125 | a. for the avoidance of doubt, Section 2(a)(1) grants You the right to extract, reuse, reproduce, and Share all or a substantial portion of the contents of the database for NonCommercial purposes only; 126 | 127 | b. if You include all or a substantial portion of the database contents in a database in which You have Sui Generis Database Rights, then the database in which You have Sui Generis Database Rights (but not its individual contents) is Adapted Material, including for purposes of Section 3(b); and 128 | 129 | c. You must comply with the conditions in Section 3(a) if You Share all or a substantial portion of the contents of the database. 130 | 131 | For the avoidance of doubt, this Section 4 supplements and does not replace Your obligations under this Public License where the Licensed Rights include other Copyright and Similar Rights. 132 | 133 | ### Section 5 – Disclaimer of Warranties and Limitation of Liability. 134 | 135 | a. __Unless otherwise separately undertaken by the Licensor, to the extent possible, the Licensor offers the Licensed Material as-is and as-available, and makes no representations or warranties of any kind concerning the Licensed Material, whether express, implied, statutory, or other. This includes, without limitation, warranties of title, merchantability, fitness for a particular purpose, non-infringement, absence of latent or other defects, accuracy, or the presence or absence of errors, whether or not known or discoverable. Where disclaimers of warranties are not allowed in full or in part, this disclaimer may not apply to You.__ 136 | 137 | b. __To the extent possible, in no event will the Licensor be liable to You on any legal theory (including, without limitation, negligence) or otherwise for any direct, special, indirect, incidental, consequential, punitive, exemplary, or other losses, costs, expenses, or damages arising out of this Public License or use of the Licensed Material, even if the Licensor has been advised of the possibility of such losses, costs, expenses, or damages. Where a limitation of liability is not allowed in full or in part, this limitation may not apply to You.__ 138 | 139 | c. The disclaimer of warranties and limitation of liability provided above shall be interpreted in a manner that, to the extent possible, most closely approximates an absolute disclaimer and waiver of all liability. 140 | 141 | ### Section 6 – Term and Termination. 142 | 143 | a. This Public License applies for the term of the Copyright and Similar Rights licensed here. However, if You fail to comply with this Public License, then Your rights under this Public License terminate automatically. 144 | 145 | b. Where Your right to use the Licensed Material has terminated under Section 6(a), it reinstates: 146 | 147 | 1. automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or 148 | 149 | 2. automatically as of the date the violation is cured, provided it is cured within 30 days of Your discovery of the violation; or 150 | 151 | For the avoidance of doubt, this Section 6(b) does not affect any right the Licensor may have to seek remedies for Your violations of this Public License. 152 | 153 | c. For the avoidance of doubt, the Licensor may also offer the Licensed Material under separate terms or conditions or stop distributing the Licensed Material at any time; however, doing so will not terminate this Public License. 154 | 155 | d. Sections 1, 5, 6, 7, and 8 survive termination of this Public License. 156 | 157 | ### Section 7 – Other Terms and Conditions. 158 | 159 | a. The Licensor shall not be bound by any additional or different terms or conditions communicated by You unless expressly agreed. 160 | 161 | b. Any arrangements, understandings, or agreements regarding the Licensed Material not stated herein are separate from and independent of the terms and conditions of this Public License. 162 | 163 | ### Section 8 – Interpretation. 164 | 165 | a. For the avoidance of doubt, this Public License does not, and shall not be interpreted to, reduce, limit, restrict, or impose conditions on any use of the Licensed Material that could lawfully be made without permission under this Public License. 166 | 167 | b. To the extent possible, if any provision of this Public License is deemed unenforceable, it shall be automatically reformed to the minimum extent necessary to make it enforceable. If the provision cannot be reformed, it shall be severed from this Public License without affecting the enforceability of the remaining terms and conditions. 168 | 169 | c. No term or condition of this Public License will be waived and no failure to comply consented to unless expressly agreed to by the Licensor. 170 | 171 | d. Nothing in this Public License constitutes or may be interpreted as a limitation upon, or waiver of, any privileges and immunities that apply to the Licensor or You, including from the legal processes of any jurisdiction or authority. 172 | 173 | ``` 174 | Creative Commons is not a party to its public licenses. Notwithstanding, Creative Commons may elect to apply one of its public licenses to material it publishes and in those instances will be considered the “Licensor.” Except for the limited purpose of indicating that material is shared under a Creative Commons public license or as otherwise permitted by the Creative Commons policies published at [creativecommons.org/policies](http://creativecommons.org/policies), Creative Commons does not authorize the use of the trademark “Creative Commons” or any other trademark or logo of Creative Commons without its prior written consent including, without limitation, in connection with any unauthorized modifications to any of its public licenses or any other arrangements, understandings, or agreements concerning use of licensed material. For the avoidance of doubt, this paragraph does not form part of the public licenses. 175 | 176 | Creative Commons may be contacted at [creativecommons.org](http://creativecommons.org/). 177 | ``` 178 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | # Finternet API Specs 2 | 3 | Welcome to the Finternet API specs Documentation repository. 4 | 5 | If you wish to learn more about the concept in detail, it is recommended to read the below BIS working paper and the companion technology architecture paper: 6 | 7 | - [The Vision for the Future Financial System](http://bit.ly/finternet-vision) 8 | - [Technology Vision and Architecture](http://bit.ly/finternet-tech) 9 | 10 | Or check out this Fireside Chat at the BIS Innovation Hub: [Fireside Chat](https://www.youtube.com/watch?v=2-ukiKchQsI) 11 | 12 | 13 | # Use Cases 14 | 15 | The Finternet Sandbox is being modeled for the use cases and status as below: 16 | 17 | | Use Case | Sandbox Status | 18 | | -------------------------------------- | -------------- | 19 | | Domestic money transfer | In progress | 20 | | Pledge land and obtain commercial loan | Yet to start | 21 | | Cross Border | Yet to start | 22 | | More use cases will be updated here | Yet to start | 23 | 24 | # Approach 25 | 26 | ![Finternet API Specs](/static/finternetApiSpec.png) 27 | 28 | The specifications are being defined from the perspective of an “Application” which enables users with various use cases by connecting the following parties or entities: 29 | 30 | 1. Application 31 | 2. Higher order workflow layer 32 | 3. Unified asset management platform 33 | 4. Token/Asset manager 34 | 35 | ### Application 36 | 37 | The application layer provides the user interface to the finternet. It enables users with various workflows that can be performed across asset classes 38 | 39 | ### Higher order workflow layer 40 | 41 | This layer facilitates the composability of Finternet ‘verbs’ by enabling new workflows that are made up of foundational asset management verbs. For example, a ‘trade’ operation could be composed of two ‘transfer’ operations. 42 | 43 | ### Unified Asset Management Platform 44 | 45 | The platform comprises the ledger layer and the programmability layer. This facilitates bookkeeping and workflow management of tokenized assets. 46 | 47 | ### Token/Asset manager 48 | 49 | An institution that is responsible for the issuance (tokenisation, detokenisation), management and synchronisation of a token with their private ledger 50 | 51 | ## Ledger Interactions 52 | 53 | There are many interactions a user can have with the ledger. 54 | Some of the capabilities include: 55 | 1. Identity management 56 | 2. Asset tokenization 57 | 3. Anchoring and querying proofs 58 | 59 | ### Identity management 60 | 61 | #### Create identity 62 | 63 | The ledger provides identity management by creating a decentralized identity (DID) and anchoring it on the ledger. 64 | 65 | For example, this is how a token manager can create identity: 66 | 67 | ![create_identity.png](/static/create_identity.png) 68 | -------------------------------------------------------------------------------- /api/README.md: -------------------------------------------------------------------------------- 1 | # Finternet APIs 2 | 3 | This folder contains the API definitions for different layers involved in Finternet implementation. 4 | 5 | 6 | Feel free to contribute by reviewing the APIs, providing feedback on improvements, and bring usecase specific APIs (if any). 7 | -------------------------------------------------------------------------------- /api/application-interfaces.yaml: -------------------------------------------------------------------------------- 1 | openapi: "3.0.3" 2 | info: 3 | title: "Backend Routes - Finternet" 4 | description: |+ 5 | This is the OpenAPI Specification for the backend routes for the Finternet. The Finternet is a decentralized finance platform that allows users to create and manage assets. 6 | version: "0.0.1" 7 | tags: 8 | - name: users 9 | description: "Routes for linking with the token manager" 10 | - name: token manager admin 11 | description: "Routes for the token manager admin" 12 | - name: asset management 13 | description: "Routes for managing assets" 14 | paths: 15 | # ------------------------------------------------------------------------------ 16 | # Users 17 | /v1/users: 18 | post: 19 | tags: 20 | - users 21 | summary: Create a user 22 | description: "" 23 | requestBody: 24 | content: 25 | application/json: 26 | schema: 27 | $ref: "#/components/schemas/User" 28 | responses: 29 | "200": 30 | description: "User created successfully" 31 | /v1/users/{user_id}: 32 | get: 33 | parameters: 34 | - name: user_id 35 | in: path 36 | required: true 37 | description: "The user id" 38 | schema: 39 | type: string 40 | tags: 41 | - users 42 | summary: Get a user 43 | description: "" 44 | responses: 45 | "200": 46 | description: "User found successfully" 47 | content: 48 | application/json: 49 | schema: 50 | $ref: "#/components/schemas/User" 51 | put: 52 | parameters: 53 | - name: user_id 54 | in: path 55 | required: true 56 | description: "The user id" 57 | schema: 58 | type: string 59 | tags: 60 | - users 61 | summary: Update a user 62 | description: "" 63 | requestBody: 64 | content: 65 | application/json: 66 | schema: 67 | $ref: "#/components/schemas/User" 68 | responses: 69 | "200": 70 | description: "User updated successfully" 71 | delete: 72 | parameters: 73 | - name: user_id 74 | in: path 75 | required: true 76 | description: "The user id" 77 | schema: 78 | type: string 79 | tags: 80 | - users 81 | summary: Delete a user 82 | description: "" 83 | responses: 84 | "200": 85 | description: "User deleted successfully" 86 | /v1/users/{user_id}/contacts: 87 | post: 88 | parameters: 89 | - name: user_id 90 | in: path 91 | required: true 92 | description: "The user id" 93 | schema: 94 | type: string 95 | tags: 96 | - users 97 | summary: Create a contact 98 | description: "" 99 | requestBody: 100 | content: 101 | application/json: 102 | schema: 103 | $ref: "#/components/schemas/Contact" 104 | responses: 105 | "200": 106 | description: "Contact created successfully" 107 | get: 108 | parameters: 109 | - name: user_id 110 | in: path 111 | required: true 112 | description: "The user id" 113 | schema: 114 | type: string 115 | tags: 116 | - users 117 | summary: Get all contacts as a list 118 | description: "" 119 | responses: 120 | "200": 121 | description: "Contacts found successfully" 122 | content: 123 | application/json: 124 | schema: 125 | type: array 126 | items: 127 | $ref: "#/components/schemas/Contact" 128 | /v1/users/{user_id}/contacts/{contact_id}: 129 | get: 130 | parameters: 131 | - name: user_id 132 | in: path 133 | required: true 134 | description: "The user id" 135 | schema: 136 | type: string 137 | - name: contact_id 138 | in: path 139 | required: true 140 | description: "The contact id" 141 | schema: 142 | type: string 143 | tags: 144 | - users 145 | summary: Get a contact 146 | description: "" 147 | responses: 148 | "200": 149 | description: "Contact found successfully" 150 | content: 151 | application/json: 152 | schema: 153 | $ref: "#/components/schemas/Contact" 154 | put: 155 | parameters: 156 | - name: user_id 157 | in: path 158 | required: true 159 | description: "The user id" 160 | schema: 161 | type: string 162 | - name: contact_id 163 | in: path 164 | required: true 165 | description: "The contact id" 166 | schema: 167 | type: string 168 | tags: 169 | - users 170 | summary: Update a contact 171 | description: "" 172 | requestBody: 173 | content: 174 | application/json: 175 | schema: 176 | $ref: "#/components/schemas/Contact" 177 | responses: 178 | "200": 179 | description: "Contact updated successfully" 180 | delete: 181 | parameters: 182 | - name: user_id 183 | in: path 184 | required: true 185 | description: "The user id" 186 | schema: 187 | type: string 188 | - name: contact_id 189 | in: path 190 | required: true 191 | description: "The contact id" 192 | schema: 193 | type: string 194 | tags: 195 | - users 196 | summary: Delete a contact 197 | description: "" 198 | responses: 199 | "200": 200 | description: "Contact deleted successfully" 201 | /v1/users/{user_id}/accounts: 202 | post: 203 | parameters: 204 | - name: user_id 205 | in: path 206 | required: true 207 | description: "The user id" 208 | schema: 209 | type: string 210 | tags: 211 | - users 212 | summary: Create an account 213 | description: "" 214 | requestBody: 215 | content: 216 | application/json: 217 | schema: 218 | $ref: "#/components/schemas/Account" 219 | responses: 220 | "200": 221 | description: "Account created successfully" 222 | get: 223 | parameters: 224 | - name: user_id 225 | in: path 226 | required: true 227 | description: "The user id" 228 | schema: 229 | type: string 230 | tags: 231 | - users 232 | summary: Get all accounts as a list 233 | description: "" 234 | responses: 235 | "200": 236 | description: "Accounts found successfully" 237 | content: 238 | application/json: 239 | schema: 240 | type: array 241 | items: 242 | $ref: "#/components/schemas/Account" 243 | /v1/users/{user_id}/accounts/{account_id}: 244 | get: 245 | parameters: 246 | - name: user_id 247 | in: path 248 | required: true 249 | description: "The user id" 250 | schema: 251 | type: string 252 | - name: account_id 253 | in: path 254 | required: true 255 | description: "The account id" 256 | schema: 257 | type: string 258 | tags: 259 | - users 260 | summary: Get an account 261 | description: "" 262 | responses: 263 | "200": 264 | description: "Account found successfully" 265 | content: 266 | application/json: 267 | schema: 268 | $ref: "#/components/schemas/Account" 269 | put: 270 | parameters: 271 | - name: user_id 272 | in: path 273 | required: true 274 | description: "The user id" 275 | schema: 276 | type: string 277 | - name: account_id 278 | in: path 279 | required: true 280 | description: "The account id" 281 | schema: 282 | type: string 283 | tags: 284 | - users 285 | summary: Update an account 286 | description: "" 287 | requestBody: 288 | content: 289 | application/json: 290 | schema: 291 | $ref: "#/components/schemas/Account" 292 | responses: 293 | "200": 294 | description: "Account updated successfully" 295 | delete: 296 | parameters: 297 | - name: user_id 298 | in: path 299 | required: true 300 | description: "The user id" 301 | schema: 302 | type: string 303 | - name: account_id 304 | in: path 305 | required: true 306 | description: "The account id" 307 | schema: 308 | type: string 309 | tags: 310 | - users 311 | summary: Delete an account 312 | description: "" 313 | responses: 314 | "200": 315 | description: "Account deleted successfully" 316 | # ------------------------------------------------------------------------------ 317 | # Token Manager 318 | /v1/token_managers: 319 | post: 320 | tags: 321 | - token manager admin 322 | summary: Create a token manager 323 | description: "" 324 | requestBody: 325 | content: 326 | application/json: 327 | schema: 328 | $ref: "#/components/schemas/TokenManager" 329 | responses: 330 | "200": 331 | description: "Token manager created successfully" 332 | get: 333 | tags: 334 | - token manager admin 335 | summary: Get all token managers as a list 336 | description: "" 337 | responses: 338 | "200": 339 | description: "Token managers found successfully" 340 | content: 341 | application/json: 342 | schema: 343 | type: array 344 | items: 345 | $ref: "#/components/schemas/TokenManager" 346 | /v1/token_managers/{token_manager_id}: 347 | get: 348 | parameters: 349 | - name: token_manager_id 350 | in: path 351 | required: true 352 | description: "The token manager id" 353 | schema: 354 | type: string 355 | tags: 356 | - token manager admin 357 | summary: Get a token manager 358 | description: "" 359 | responses: 360 | "200": 361 | description: "Token manager found successfully" 362 | content: 363 | application/json: 364 | schema: 365 | $ref: "#/components/schemas/TokenManager" 366 | put: 367 | parameters: 368 | - name: token_manager_id 369 | in: path 370 | required: true 371 | description: "The token manager id" 372 | schema: 373 | type: string 374 | tags: 375 | - token manager admin 376 | summary: Update a token manager 377 | description: "" 378 | requestBody: 379 | content: 380 | application/json: 381 | schema: 382 | $ref: "#/components/schemas/TokenManager" 383 | responses: 384 | "200": 385 | description: "Token manager updated successfully" 386 | delete: 387 | parameters: 388 | - name: token_manager_id 389 | in: path 390 | required: true 391 | description: "The token manager id" 392 | schema: 393 | type: string 394 | tags: 395 | - token manager admin 396 | summary: Delete a token manager 397 | description: "" 398 | responses: 399 | "200": 400 | description: "Token manager deleted successfully" 401 | /v1/token_managers/{token_manager_id}/supported_assets: 402 | post: 403 | parameters: 404 | - name: token_manager_id 405 | in: path 406 | required: true 407 | description: "The token manager id" 408 | schema: 409 | type: string 410 | tags: 411 | - token manager admin 412 | summary: Create an asset type 413 | description: "" 414 | requestBody: 415 | content: 416 | application/json: 417 | schema: 418 | $ref: "#/components/schemas/SupportedAsset" 419 | responses: 420 | "200": 421 | description: "Asset type created successfully" 422 | get: 423 | parameters: 424 | - name: token_manager_id 425 | in: path 426 | required: true 427 | description: "The token manager id" 428 | schema: 429 | type: string 430 | tags: 431 | - token manager admin 432 | summary: Get all asset types as a list 433 | description: "" 434 | responses: 435 | "200": 436 | description: "Asset types found successfully" 437 | content: 438 | application/json: 439 | schema: 440 | type: array 441 | items: 442 | $ref: "#/components/schemas/SupportedAsset" 443 | /v1/token_managers/{token_manager_id}/supported_assets/{supported_asset_id}: 444 | get: 445 | parameters: 446 | - name: token_manager_id 447 | in: path 448 | required: true 449 | description: "The token manager id" 450 | schema: 451 | type: string 452 | - name: supported_asset_id 453 | in: path 454 | required: true 455 | description: "The supported asset id" 456 | schema: 457 | type: string 458 | tags: 459 | - token manager admin 460 | summary: Get an asset type 461 | description: "" 462 | responses: 463 | "200": 464 | description: "Asset type found successfully" 465 | content: 466 | application/json: 467 | schema: 468 | $ref: "#/components/schemas/SupportedAsset" 469 | put: 470 | parameters: 471 | - name: token_manager_id 472 | in: path 473 | required: true 474 | description: "The token manager id" 475 | schema: 476 | type: string 477 | - name: supported_asset_id 478 | in: path 479 | required: true 480 | description: "The supported asset id" 481 | schema: 482 | type: string 483 | tags: 484 | - token manager admin 485 | summary: Update an asset type 486 | description: "" 487 | requestBody: 488 | content: 489 | application/json: 490 | schema: 491 | $ref: "#/components/schemas/SupportedAsset" 492 | responses: 493 | "200": 494 | description: "Asset type updated successfully" 495 | delete: 496 | parameters: 497 | - name: token_manager_id 498 | in: path 499 | required: true 500 | description: "The token manager id" 501 | schema: 502 | type: string 503 | - name: supported_asset_id 504 | in: path 505 | required: true 506 | description: "The supported asset id" 507 | schema: 508 | type: string 509 | tags: 510 | - token manager admin 511 | summary: Delete an asset type 512 | description: "" 513 | responses: 514 | "200": 515 | description: "Asset type deleted successfully" 516 | # ------------------------------------------------------------------------------ 517 | # Asset Management 518 | /v1/users/{user_id}/accounts/{account_id}/assets: 519 | post: 520 | parameters: 521 | - name: user_id 522 | in: path 523 | required: true 524 | description: "The user id" 525 | schema: 526 | type: string 527 | - name: account_id 528 | in: path 529 | required: true 530 | description: "The account id" 531 | schema: 532 | type: string 533 | tags: 534 | - asset management 535 | summary: Create a asset 536 | description: "" 537 | requestBody: 538 | content: 539 | application/json: 540 | schema: 541 | $ref: "#/components/schemas/Asset" 542 | responses: 543 | "200": 544 | description: "Asset created successfully" 545 | /v1/users/{user_id}/accounts/{account_id}/assets/{asset_id}: 546 | get: 547 | parameters: 548 | - name: user_id 549 | in: path 550 | required: true 551 | description: "The user id" 552 | schema: 553 | type: string 554 | - name: account_id 555 | in: path 556 | required: true 557 | description: "The account id" 558 | schema: 559 | type: string 560 | - name: asset_id 561 | in: path 562 | required: true 563 | description: "The asset id" 564 | schema: 565 | type: string 566 | tags: 567 | - asset management 568 | summary: Get an asset 569 | description: "" 570 | responses: 571 | "200": 572 | description: "Asset found successfully" 573 | content: 574 | application/json: 575 | schema: 576 | $ref: "#/components/schemas/Asset" 577 | put: 578 | parameters: 579 | - name: user_id 580 | in: path 581 | required: true 582 | description: "The user id" 583 | schema: 584 | type: string 585 | - name: account_id 586 | in: path 587 | required: true 588 | description: "The account id" 589 | schema: 590 | type: string 591 | - name: asset_id 592 | in: path 593 | required: true 594 | description: "The asset id" 595 | schema: 596 | type: string 597 | tags: 598 | - asset management 599 | summary: Update an asset 600 | description: "" 601 | requestBody: 602 | content: 603 | application/json: 604 | schema: 605 | $ref: "#/components/schemas/Asset" 606 | responses: 607 | "200": 608 | description: "Asset updated successfully" 609 | delete: 610 | parameters: 611 | - name: user_id 612 | in: path 613 | required: true 614 | description: "The user id" 615 | schema: 616 | type: string 617 | - name: account_id 618 | in: path 619 | required: true 620 | description: "The account id" 621 | schema: 622 | type: string 623 | - name: asset_id 624 | in: path 625 | required: true 626 | description: "The asset id" 627 | schema: 628 | type: string 629 | tags: 630 | - asset management 631 | summary: Delete an asset 632 | description: "" 633 | responses: 634 | "200": 635 | description: "Asset deleted successfully" 636 | /v1/users/{user_id}/accounts/{account_id}/assets/{asset_id}/asset:transfer: 637 | post: 638 | parameters: 639 | - name: user_id 640 | in: path 641 | required: true 642 | description: "The user id" 643 | schema: 644 | type: string 645 | - name: account_id 646 | in: path 647 | required: true 648 | description: "The account id" 649 | schema: 650 | type: string 651 | - name: asset_id 652 | in: path 653 | required: true 654 | description: "The asset id" 655 | schema: 656 | type: string 657 | tags: 658 | - asset management 659 | summary: transfer an asset 660 | description: "" 661 | requestBody: 662 | content: 663 | application/json: 664 | schema: 665 | type: object 666 | properties: 667 | asset: 668 | $ref: "#/components/schemas/Asset" 669 | responses: 670 | "200": 671 | description: "Asset transferred successfully" 672 | /v1/users/{user_id}/accounts/{account_id}/assets/{asset_id}/asset:nominate: 673 | post: 674 | parameters: 675 | - name: user_id 676 | in: path 677 | required: true 678 | description: "The user id" 679 | schema: 680 | type: string 681 | - name: account_id 682 | in: path 683 | required: true 684 | description: "The account id" 685 | schema: 686 | type: string 687 | - name: asset_id 688 | in: path 689 | required: true 690 | description: "The asset id" 691 | schema: 692 | type: string 693 | tags: 694 | - asset management 695 | summary: nominate an asset 696 | description: "" 697 | requestBody: 698 | content: 699 | application/json: 700 | schema: 701 | type: object 702 | properties: 703 | asset: 704 | $ref: "#/components/schemas/Asset" 705 | responses: 706 | "200": 707 | description: "Asset nominated successfully" 708 | /v1/users/{user_id}/accounts/{account_id}/assets/{asset_id}/asset:lease: 709 | post: 710 | parameters: 711 | - name: user_id 712 | in: path 713 | required: true 714 | description: "The user id" 715 | schema: 716 | type: string 717 | - name: account_id 718 | in: path 719 | required: true 720 | description: "The account id" 721 | schema: 722 | type: string 723 | - name: asset_id 724 | in: path 725 | required: true 726 | description: "The asset id" 727 | schema: 728 | type: string 729 | tags: 730 | - asset management 731 | summary: lease an asset 732 | description: "" 733 | requestBody: 734 | content: 735 | application/json: 736 | schema: 737 | type: object 738 | properties: 739 | asset: 740 | $ref: "#/components/schemas/Asset" 741 | responses: 742 | "200": 743 | description: "Asset leased successfully" 744 | /v1/users/{user_id}/accounts/{account_id}/assets/{asset_id}/asset:pledge: 745 | post: 746 | parameters: 747 | - name: user_id 748 | in: path 749 | required: true 750 | description: "The user id" 751 | schema: 752 | type: string 753 | - name: account_id 754 | in: path 755 | required: true 756 | description: "The account id" 757 | schema: 758 | type: string 759 | - name: asset_id 760 | in: path 761 | required: true 762 | description: "The asset id" 763 | schema: 764 | type: string 765 | tags: 766 | - asset management 767 | summary: pledge an asset 768 | description: "" 769 | requestBody: 770 | content: 771 | application/json: 772 | schema: 773 | type: object 774 | properties: 775 | asset: 776 | $ref: "#/components/schemas/Asset" 777 | responses: 778 | "200": 779 | description: "Asset leased successfully" 780 | components: 781 | schemas: 782 | User: 783 | type: object 784 | properties: 785 | id: 786 | type: "string" 787 | description: "A Unique Account Address to be assigned to the user" 788 | pub_key: 789 | type: byte 790 | description: "The public key the is securely generated on the user side" 791 | name: 792 | type: "string" 793 | description: "The name of the user" 794 | email: 795 | type: "string" 796 | description: "The email of the user" 797 | TokenManager: 798 | type: object 799 | properties: 800 | id: 801 | type: "string" 802 | description: "A Unique Account Address to be assigned to the token manager" 803 | name: 804 | type: "string" 805 | description: "The name of the token manager" 806 | email: 807 | type: "string" 808 | description: "The email of the token manager" 809 | Contact: 810 | type: object 811 | Account: 812 | type: object 813 | Workflow: 814 | type: object 815 | Asset: 816 | type: object 817 | properties: 818 | id: 819 | type: string 820 | description: "A Unique Account Address to be assigned to the asset" 821 | allowed_verbs: 822 | type: string 823 | description: "The allowed verbs for the asset" 824 | issuer_id: 825 | type: string 826 | description: "The issuer of the asset" 827 | asset_type: 828 | $ref: "#/components/schemas/AssetType" 829 | holder_id: 830 | oneOf: 831 | - type: string 832 | - type: array 833 | items: 834 | type: string 835 | SupportedAsset: 836 | type: object 837 | properties: 838 | id: 839 | type: "string" 840 | asset_type: 841 | $ref: "#/components/schemas/AssetType" 842 | AssetType: 843 | type: string 844 | enum: 845 | - property 846 | - currency 847 | -------------------------------------------------------------------------------- /api/ledger-interfaces.yaml: -------------------------------------------------------------------------------- 1 | openapi: "3.0.1" 2 | info: 3 | version: "0.0.1" 4 | title: "Finternet Asset Tokenization API Suite" 5 | description: "A comprehensive suite of APIs for interacting with the CORD, designed to handle asset-related requests." 6 | termsOfService: "http://studio.dhiway.com/page/terms-and-conditions" 7 | contact: 8 | name: "Dhiway Networks" 9 | email: "info@dhiway.com" 10 | url: "https://dhiway.com" 11 | license: 12 | name: "Apache v2.0" 13 | url: "https://www.apache.org/licenses/LICENSE-2.0" 14 | servers: 15 | - url: "http://localhost:4000/" 16 | description: "Local Development Server" 17 | paths: 18 | /v1/identity: 19 | post: 20 | tags: 21 | - "Identity" 22 | summary: "Create a new identity" 23 | description: "Initiate a request to create an identity on the blockchain." 24 | operationId: "createIdentity" 25 | requestBody: 26 | description: "Payload containing data to initiate a create identity request on the blockchain." 27 | content: 28 | application/json: 29 | schema: 30 | type: object 31 | properties: 32 | context: 33 | $ref: "#/components/schemas/Context" 34 | message: 35 | $ref: "#/components/schemas/Message" 36 | responses: 37 | default: 38 | $ref: "#/components/responses/DefaultResponse" 39 | 40 | /v1/identity/{identity}: 41 | delete: 42 | parameters: 43 | - name: identity 44 | in: path 45 | required: true 46 | description: "The identity of the entity" 47 | schema: 48 | type: string 49 | tags: 50 | - "Identity" 51 | summary: "Delete an identity" 52 | description: "Delete an existing identity from the blockchain." 53 | responses: 54 | "200": 55 | description: "Identity deleted successfully" 56 | put: 57 | parameters: 58 | - name: identity 59 | in: path 60 | required: true 61 | description: "The identity of the entity" 62 | schema: 63 | type: string 64 | tags: 65 | - "Identity" 66 | summary: "Rotate the key and sign with the previous private key" 67 | description: "Rotate the key internally and sign with the previous private key." 68 | responses: 69 | "200": 70 | description: "Key rotated and signed successfully" 71 | get: 72 | parameters: 73 | - name: identity 74 | in: path 75 | required: true 76 | description: "The identity of the entity" 77 | schema: 78 | type: string 79 | tags: 80 | - "Identity" 81 | summary: "Get identity details" 82 | description: "Retrieve detailed identity information including the public key and/or any available alias." 83 | responses: 84 | "200": 85 | description: "Identity details retrieved successfully" 86 | 87 | /v1/smart-contract: 88 | post: 89 | tags: 90 | - "Smart Contract" 91 | summary: "Deploy a smart contract" 92 | description: "Deploy a new smart contract on the blockchain." 93 | operationId: "deployContract" 94 | requestBody: 95 | description: "Payload containing the details to deploy a smart contract on the blockchain." 96 | content: 97 | application/json: 98 | schema: 99 | type: object 100 | properties: 101 | context: 102 | $ref: "#/components/schemas/Context" 103 | message: 104 | $ref: "#/components/schemas/Message" 105 | responses: 106 | default: 107 | $ref: "#/components/responses/DefaultResponse" 108 | 109 | /v1/smart-contract/{contract-address}/exec: 110 | post: 111 | parameters: 112 | - name: contract-address 113 | in: path 114 | required: true 115 | description: "The address of the smart contract" 116 | schema: 117 | type: string 118 | tags: 119 | - "Smart Contract" 120 | summary: "Execute a contract method" 121 | description: "Execute a method of the deployed smart contract." 122 | operationId: "executeContractMethod" 123 | requestBody: 124 | description: "Payload containing the details to execute a smart contract method on the blockchain." 125 | content: 126 | application/json: 127 | schema: 128 | type: object 129 | properties: 130 | context: 131 | $ref: "#/components/schemas/Context" 132 | message: 133 | $ref: "#/components/schemas/Message" 134 | responses: 135 | default: 136 | $ref: "#/components/responses/DefaultResponse" 137 | 138 | /v1/smart-contract/estimate-transaction-fee: 139 | post: 140 | tags: 141 | - "Smart Contract" 142 | summary: "Estimate transaction fee" 143 | description: "Estimate the transaction fee for executing a smart contract method." 144 | operationId: "estimateTransactionFee" 145 | requestBody: 146 | description: "Payload containing the details to estimate the transaction fee for a smart contract method." 147 | content: 148 | application/json: 149 | schema: 150 | type: object 151 | properties: 152 | context: 153 | $ref: "#/components/schemas/Context" 154 | message: 155 | $ref: "#/components/schemas/Message" 156 | responses: 157 | default: 158 | $ref: "#/components/responses/DefaultResponse" 159 | 160 | /v1/smart-contract/upgrade: 161 | post: 162 | tags: 163 | - "Smart Contract" 164 | summary: "Upgrade a smart contract" 165 | description: "Upgrade an existing smart contract on the blockchain." 166 | operationId: "upgradeContract" 167 | requestBody: 168 | description: "Payload containing the details to upgrade a smart contract on the blockchain." 169 | content: 170 | application/json: 171 | schema: 172 | type: object 173 | properties: 174 | context: 175 | $ref: "#/components/schemas/Context" 176 | message: 177 | $ref: "#/components/schemas/Message" 178 | responses: 179 | default: 180 | $ref: "#/components/schemas/DefaultResponse" 181 | 182 | components: 183 | securitySchemes: 184 | bearerAuth: 185 | type: "http" 186 | scheme: "bearer" 187 | bearerFormat: "token" 188 | schemas: 189 | Context: 190 | type: string 191 | description: "Context" 192 | 193 | Message: 194 | type: string 195 | description: "Context" 196 | DefaultResponse: 197 | type: object 198 | description: "Response indicating the received message's validation status and any associated errors." 199 | properties: 200 | message: 201 | type: string 202 | description: "A message describing the status of the response." 203 | errors: 204 | type: array 205 | items: 206 | $ref: '#/components/schemas/Error' 207 | 208 | 200_Res: 209 | type: object 210 | properties: 211 | ack: 212 | $ref: "#/components/schemas/Ack" 213 | 214 | Ack: 215 | description: "Acknowledgement response indicating the receipt and validation status of an API call." 216 | type: object 217 | additionalProperties: false 218 | properties: 219 | status: 220 | type: string 221 | description: "Status of the acknowledgement, indicating whether the request passed validation (ACK) or failed (NACK)." 222 | enum: 223 | - ACK 224 | - NACK 225 | tags: 226 | description: "Additional information included with the acknowledgement." 227 | type: array 228 | items: 229 | $ref: '#/components/schemas/TagGroup' 230 | 231 | Descriptor: 232 | description: "Detailed physical description of an entity." 233 | type: object 234 | additionalProperties: false 235 | properties: 236 | name: 237 | type: string 238 | code: 239 | type: string 240 | short_desc: 241 | type: string 242 | long_desc: 243 | type: string 244 | additional_desc: 245 | type: object 246 | additionalProperties: false 247 | properties: 248 | url: 249 | type: string 250 | content_type: 251 | type: string 252 | enum: 253 | - text/plain 254 | - text/html 255 | - application/json 256 | 257 | Error: 258 | description: "Error object provided when a request is unacceptable, often containing detailed error codes and messages." 259 | type: object 260 | additionalProperties: false 261 | properties: 262 | code: 263 | type: string 264 | description: "Standard error code referring to specific error types." 265 | paths: 266 | type: string 267 | description: "JSON schema path generating the error, mainly used during validation errors." 268 | message: 269 | type: string 270 | description: "Human-readable description of the error, primarily for logging purposes." 271 | 272 | Tag: 273 | description: "Metadata tag used to provide extended information, useful for search optimization and display purposes." 274 | type: object 275 | additionalProperties: false 276 | properties: 277 | descriptor: 278 | description: "Detailed descriptor of the tag." 279 | allOf: 280 | - $ref: '#/components/schemas/Descriptor' 281 | value: 282 | description: "Value assigned to the tag, intended to be rendered as-is." 283 | type: string 284 | display: 285 | description: "Indicates if the tag should be displayed." 286 | type: boolean 287 | 288 | TagGroup: 289 | description: "Collection of tags with additional group-level display properties." 290 | type: object 291 | additionalProperties: false 292 | properties: 293 | display: 294 | description: "Group-level display property, indicating if the entire group should be displayed." 295 | type: boolean 296 | default: true 297 | descriptor: 298 | description: "Detailed descriptor of the tag group." 299 | allOf: 300 | - $ref: '#/components/schemas/Descriptor' 301 | 302 | responses: 303 | DefaultResponse: 304 | description: "Default response for all API calls" 305 | content: 306 | application/json: 307 | schema: 308 | $ref: '#/components/schemas/DefaultResponse' -------------------------------------------------------------------------------- /schemas/README.md: -------------------------------------------------------------------------------- 1 | # Token definitions 2 | 3 | This folder contains the schemas 'recommended' for representing different type of assets in the digital way. 4 | 5 | If your digital asset is not found here, feel free to open a PR to add it. 6 | -------------------------------------------------------------------------------- /static/create_identity.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finternet-io/specs/19d8ccfd4068e95c3fb4b9136767d4a955541b10/static/create_identity.png -------------------------------------------------------------------------------- /static/finternetApiSpec.png: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/finternet-io/specs/19d8ccfd4068e95c3fb4b9136767d4a955541b10/static/finternetApiSpec.png --------------------------------------------------------------------------------