aboutsummaryrefslogtreecommitdiffstats
path: root/src/lib/samples.js
diff options
context:
space:
mode:
Diffstat (limited to 'src/lib/samples.js')
-rw-r--r--src/lib/samples.js8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/lib/samples.js b/src/lib/samples.js
index c8a60c71..6624064b 100644
--- a/src/lib/samples.js
+++ b/src/lib/samples.js
@@ -1,3 +1,9 @@
+import { PUBLIC_DOMAIN, PUBLIC_COINOS_URL } from "$env/static/public";
+
+let api = PUBLIC_DOMAIN.includes("localhost")
+ ? `${PUBLIC_COINOS_URL}`
+ : `https://${PUBLIC_DOMAIN}/api`;
+
export default {
register: `curl "https://swapee.me/api/register" -H "content-type: application/json" -d '{
"user": {
@@ -24,7 +30,7 @@ export default {
-H "Authorization: Bearer $token"
-d '{
"amount": 5000,
- "hash": "bc1q3unh97w4rmelflrm2hvdwz37d8kray3vn4d5ca"
+ "address": "bc1q3unh97w4rmelflrm2hvdwz37d8kray3vn4d5ca"
}'`,
internal: `HASH=$(curl "https://swapee.me/api/invoice"
-H "content-type: application/json"