diff --git a/.github/workflows/dependabot.yml b/.github/workflows/dependabot.yml index 18560b57..4b49fa29 100644 --- a/.github/workflows/dependabot.yml +++ b/.github/workflows/dependabot.yml @@ -1,8 +1,8 @@ version: 2 updates: - - package-ecosystem: npm - directory: / - schedule: - interval: weekly - allow: - - dependency-type: direct + - package-ecosystem: npm + directory: / + schedule: + interval: weekly + allow: + - dependency-type: direct diff --git a/.vscode/extensions.json b/.vscode/extensions.json new file mode 100644 index 00000000..2db5ae2f --- /dev/null +++ b/.vscode/extensions.json @@ -0,0 +1,6 @@ +{ + "recommendations": [ + "DavidAnson.vscode-markdownlint", + "esbenp.prettier-vscode" + ] +} diff --git a/docs/orcfax-feeds/CER/_category_.json b/docs/orcfax-feeds/CER/_category_.json new file mode 100644 index 00000000..a0a98932 --- /dev/null +++ b/docs/orcfax-feeds/CER/_category_.json @@ -0,0 +1,5 @@ +{ + "label": "CER", + "position": 2, + "link": null +} diff --git a/docs/orcfax-feeds/CER/cer-intro.md b/docs/orcfax-feeds/CER/cer-intro.md new file mode 100644 index 00000000..9af8b449 --- /dev/null +++ b/docs/orcfax-feeds/CER/cer-intro.md @@ -0,0 +1,12 @@ +--- +id: cer intro +sidebar_position: 1 +slug: /cer-intro +--- + +# Introduction to CER + +Current Exchange Rate feeds represent the most well known feed type offered by +oracle services and are a critical component in a mature DeFi ecosystem. Feeds +are offered for Centralized Exchange (CEX) data and Cardano Native Tokens (CNT) +via liquidity pools hosted by Cardano Decentralized Exchanges (DEX). diff --git a/docs/orcfax-feeds/risk-ratings/_category_.json b/docs/orcfax-feeds/risk-ratings/_category_.json new file mode 100644 index 00000000..ca485ebc --- /dev/null +++ b/docs/orcfax-feeds/risk-ratings/_category_.json @@ -0,0 +1,5 @@ +{ + "label": "Risk Ratings", + "position": 3, + "link": null +} diff --git a/docs/orcfax-feeds/risk-ratings/risk-rating-introduction.md b/docs/orcfax-feeds/risk-ratings/risk-rating-introduction.md new file mode 100644 index 00000000..b0a6e359 --- /dev/null +++ b/docs/orcfax-feeds/risk-ratings/risk-rating-introduction.md @@ -0,0 +1,23 @@ +--- +id: risk rating intro +sidebar_position: 1 +slug: /risk-rating-intro +--- + +# Introduction to Risk Ratings + +Risk Ratings represent additional data that can be used in smart contracts to +trigger specific events (e.g. the risk of a given CNT increasing or decreasing +against a set threshold). A decrease in a token's risk rating could trigger an +investment opportunity, while a decrease in risk ratings could prompt a +liquidation event. + +Orcfax believes that providing these values through its oracle service as inline +datum can better support DeFi use cases. + +:::note + +This feed type is under active development. Additional documentation and +developer resources will be made available as development progresses. + +::: diff --git a/package.json b/package.json index cfcaba06..9931c08c 100644 --- a/package.json +++ b/package.json @@ -16,7 +16,7 @@ "lint": "prettier --check . && eslint .", "format": "prettier --write .", "pre-commit": "pre-commit run --all-files", - "prepare": "husky install" + "prepare": "husky" }, "dependencies": { "@docusaurus/core": "^3.6.1", diff --git a/static/schema/risk-rating/centralized-review/fact-statement-datum.json b/static/schema/risk-rating/centralized-review/fact-statement-datum.json new file mode 100644 index 00000000..820ad6e8 --- /dev/null +++ b/static/schema/risk-rating/centralized-review/fact-statement-datum.json @@ -0,0 +1,16 @@ +{ + "@context": "https://schema.org", + "type": "Message", + "name": "CER/ADA-USD/3", + "identifier": "urn:orcfax:83f5ba93-6bf3-4204-a03b-ab85bd9f955c", + "publisher": { + "@type": "Organization", + "name": "Orcfax", + "url": "https://orcfax.io/" + }, + "dateCreated": "2024-08-28T16:20:35Z", + "messageAttachment": { + "encoding": "application/json:base64", + "text": "ewogICJmZWVkX2lkIjogIkNFUi9BREEtVVNELzMiLAogICJjcmVhdGVkX2F0IjogMTcyNDg2MjAzNTUxMSwKICAiYm9keSI6IHsKICAgICJudW1lcmF0b3IiOiA2ODQ5MywKICAgICJkZW5vbWluYXRvciI6IDIwMDAwMAogIH0KfQ==" + } +} diff --git a/static/schema/risk-rating/centralized-review/fact-statement.json b/static/schema/risk-rating/centralized-review/fact-statement.json new file mode 100644 index 00000000..3768a9cb --- /dev/null +++ b/static/schema/risk-rating/centralized-review/fact-statement.json @@ -0,0 +1,35 @@ +{ + "context": "https://schema.org", + "type": "Review", + "reviewBody": { + "@type": "CreativeWork", + "creator": "Xerberus Node: 1.0.0rc23", + "about": "The Xerberus review of the {ASSET-NAME} risk rating", + "identifier": "urn:", + "dateCreated": "2024-08-28T16:20:14Z", + "license": "https://creativecommons.org/licenses/by/4.0/", + "description": { + "@type": "Claim", + "appearance": "message-{ASSET-NAME}-xerberus.tick_generic.json", + "claimInterpreter": { + "@type": "Organization", + "name": "Orcfax", + "url": "https://orcfax.io/" + } + } + }, + "itemReviewed": { + "additionalType": "CardanoNativeToken", + "name": "{ASSET-NAME", + "description": "{ASSET-SUBJECT}", + "identifier": "{ASSET-FINGERPRINT}" + }, + "reviewRating": { + "@type": "Rating", + "author": "Xerberus", + "ratingValue": "{AAA}", + "worstRating": "D", + "bestRating": "AAA", + "reviewAspect": "Risk" + } +} diff --git a/static/schema/risk-rating/centralized-review/message.json b/static/schema/risk-rating/centralized-review/message.json new file mode 100644 index 00000000..6d6456f5 --- /dev/null +++ b/static/schema/risk-rating/centralized-review/message.json @@ -0,0 +1,19 @@ +{ + "@context": "https://schema.org", + "type": "Message", + "name": "ADA-USD", + "isBasedOn": { + "@type": "MediaObject", + "name": "Exchange data", + "additionalType": "Central Exchange Data", + "description": "the raw information received by an Orcfax collector from a central exchange (CEX) API" + }, + "sender": "https://api.pro.coinbase.com/products/ADA-USD/ticker", + "recipient": "coinbase.tick_generic_jq.0.4.0-rc.4.b637b854f875a71de2ce18a57a8e576cff1d468e", + "identifier": "urn:orcfax:e4e54362-4c14-49f6-9d80-08617d81243e", + "dateReceived": "2024-08-28T16:20:20Z", + "messageAttachment": { + "encoding": "application/json;base64", + "text": "eyJyZXF1ZXN0X3VybCI6ICJodHRwczovL2FwaS5wcm8uY29pbmJhc2UuY29tL3Byb2R1Y3RzL0FEQS1VU0QvdGlja2VyIiwgInJlc3BvbnNlIjogeyJib2R5IjogeyJhc2siOiAiMC4zND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cnZlciI6IFsiY2xvdWRmbGFyZSJdLCAiU2V0LUNvb2tpZSI6IFsiX19jZl9ibT1aeklRV185bWhjWjFyaE1JWG9lcXBvMF8zd1lqcXRHT205ZVFjZ1ROT2F3LTE3MjQ4NjIwMjYtMS4wLjEuMS1CeDJjTFBQQVllYWtsOS5VT3NldndGRGZDd3JNbE1LMXZmVkE0aVJvNTFMRDdBRmZtSUNPSzJ2NEZqWS5VQThOT3dHRHdXZm5RbktXemgwSTltdk9zQTsgcGF0aD0vOyBleHBpcmVzPVdlZCwgMjgtQXVnLTI0IDE2OjUwOjI2IEdNVDsgZG9tYWluPS5wcm8uY29pbmJhc2UuY29tOyBIdHRwT25seTsgU2VjdXJlOyBTYW1lU2l0ZT1Ob25lIl0sICJTdHJpY3QtVHJhbnNwb3J0LVNlY3VyaXR5IjogWyJtYXgtYWdlPTE1NTUyMDAwOyBpbmNsdWRlU3ViRG9tYWlucyJdLCAiVmFyeSI6IFsiQWNjZXB0LUVuY29kaW5nIl0sICJYLUNvbnRlbnQtVHlwZS1PcHRpb25zIjogWyJub3NuaWZmIl0sICJYLURucy1QcmVmZXRjaC1Db250cm9sIjogWyJvZmYiXSwgIlgtRG93bmxvYWQtT3B0aW9ucyI6IFsibm9vcGVuIl0sICJYLUZyYW1lLU9wdGlvbnMiOiBbIlNBTUVPUklHSU4iXSwgIlgtWHNzLVByb3RlY3Rpb24iOiBbIjE7IG1vZGU9YmxvY2siXX19fQ==" + } +} diff --git a/static/schema/risk-rating/centralized-review/validation.json b/static/schema/risk-rating/centralized-review/validation.json new file mode 100644 index 00000000..c9f2abb8 --- /dev/null +++ b/static/schema/risk-rating/centralized-review/validation.json @@ -0,0 +1,93 @@ +{ + "@context": "https://schema.org", + "type": "MediaObject", + "identifier": "urn:orcfax:11ceadf4-69d6-4b96-9401-c0a1e7e5d3eb", + "isBasedOn": { + "@type": "MediaObject", + "name": "the raw information sent to an Orcfax validator by an Orcfax node", + "identifier": "urn:orcfax:node:2a531a7e-4961-4895-985d-1fa9aaaf50a2" + }, + "contributor": { + "@type": "Organization", + "name": "AS14061 DigitalOcean, LLC", + "locationCreated": { + "address": { + "@type": "PostalAddress", + "addressLocality": "London", + "addressRegion": "England, GB,", + "geo": "51.5085,-0.1257" + } + } + }, + "additionalType": [ + { + "@type": "Event", + "description": "successful content signature generation for Orcfax node data", + "startDate": "2024-08-28T16:20:35Z", + "recordedIn": { + "@type": "CreativeWork", + "description": { + "@type": "TextObject", + "comment": "an Orcfax content signature is a sha256 digest of a node's 'collected timestamp', 'data-points' in-order and the 'node identifier' (uuid)", + "sha256": "33ac6c61317e8909871a759e025c82f8155a1739d7e4128f9231e527e1584572" + }, + "hasPart": [ + { + "@type": "CreativeWork", + "description": "collecting timestamp", + "text": "2024-08-28T16:20:26Z" + }, + { + "@type": "CreativeWork", + "description": "data points for ADA-USD", + "text": [ + "0.34541", + "0.3423", + "0.342465", + "0.3420342", + "0.34335" + ] + }, + { + "@type": "CreativeWork", + "description": "node identifier (uuid)", + "text": "2a531a7e-4961-4895-985d-1fa9aaaf50a2" + } + ] + } + }, + { + "@type": "Event", + "description": "selection of median value from collected node data", + "startDate": "2024-08-28T16:20:35Z", + "about": { + "@type": "StatisticalVariable", + "measurementMethod": "median calculation of a minimum of three data sources from the selected collector node", + "measurementTechnique": [ + { + "@type": "PropertyValue", + "name": "SoftwareApplication", + "value": "Python 3.11.6 (main, Apr 10 2024, 17:26:07) [GCC 13.2.0] on Linux-6.5.0-44-generic-x86_64-with-glibc2.38" + }, + { + "@type": "PropertyValue", + "name": "SoftwarePackage", + "value": "statistics" + } + ], + "variableMeasured": { + "@type": "Observation", + "measurementMethod": "median value", + "value": 0.342465, + "valueReference": [ + "0.34541", + "0.3423", + "0.342465", + "0.3420342", + "0.34335" + ] + } + } + } + ] +} diff --git a/static/schema/risk-rating/decentralized-review/fact-statement-datum.json b/static/schema/risk-rating/decentralized-review/fact-statement-datum.json new file mode 100644 index 00000000..600554f5 --- /dev/null +++ b/static/schema/risk-rating/decentralized-review/fact-statement-datum.json @@ -0,0 +1,4 @@ +{ + "context": "https://schema.org", + "TBD": "TBD" +} diff --git a/static/schema/risk-rating/decentralized-review/fact-statement.json b/static/schema/risk-rating/decentralized-review/fact-statement.json new file mode 100644 index 00000000..600554f5 --- /dev/null +++ b/static/schema/risk-rating/decentralized-review/fact-statement.json @@ -0,0 +1,4 @@ +{ + "context": "https://schema.org", + "TBD": "TBD" +} diff --git a/static/schema/risk-rating/decentralized-review/message.json b/static/schema/risk-rating/decentralized-review/message.json new file mode 100644 index 00000000..600554f5 --- /dev/null +++ b/static/schema/risk-rating/decentralized-review/message.json @@ -0,0 +1,4 @@ +{ + "context": "https://schema.org", + "TBD": "TBD" +} diff --git a/static/schema/risk-rating/decentralized-review/validation.json b/static/schema/risk-rating/decentralized-review/validation.json new file mode 100644 index 00000000..600554f5 --- /dev/null +++ b/static/schema/risk-rating/decentralized-review/validation.json @@ -0,0 +1,4 @@ +{ + "context": "https://schema.org", + "TBD": "TBD" +}