mirror of
https://github.com/Permissionless-Software-Foundation/psf-bch-api.git
synced 2026-09-23 01:22:02 -07:00
Compare commits
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
6fe0e01e8b | ||
|
|
f33b39ef01 | ||
|
|
6d27630393 | ||
|
|
eac4916415 | ||
|
|
baa1170b89 | ||
|
|
23ce276e19 | ||
|
|
f28e2c6a1a |
+1
-1
@@ -161,7 +161,7 @@ class Server {
|
|||||||
|
|
||||||
// Endpoint logging middleware
|
// Endpoint logging middleware
|
||||||
app.use((req, res, next) => {
|
app.use((req, res, next) => {
|
||||||
console.log(`Endpoint called: ${req.method} ${req.path}`)
|
console.log(`Endpoint called: ${req.method} ${req.path} by ${req.ip}`)
|
||||||
res.on('finish', () => {
|
res.on('finish', () => {
|
||||||
console.log(`Endpoint responded: ${req.method} ${req.path} - ${res.statusCode}`)
|
console.log(`Endpoint responded: ${req.method} ${req.path} - ${res.statusCode}`)
|
||||||
})
|
})
|
||||||
|
|||||||
Generated
+521
-489
File diff suppressed because it is too large
Load Diff
+1
-1
@@ -25,7 +25,7 @@
|
|||||||
"slp-token-media": "1.2.10",
|
"slp-token-media": "1.2.10",
|
||||||
"winston": "3.11.0",
|
"winston": "3.11.0",
|
||||||
"winston-daily-rotate-file": "4.7.1",
|
"winston-daily-rotate-file": "4.7.1",
|
||||||
"x402-bch-express": "1.1.1"
|
"x402-bch-express": "1.1.3"
|
||||||
},
|
},
|
||||||
"devDependencies": {
|
"devDependencies": {
|
||||||
"apidoc": "1.2.0",
|
"apidoc": "1.2.0",
|
||||||
|
|||||||
@@ -22,14 +22,16 @@ LOCAL_RESTURL=http://172.17.0.1:5942/v6
|
|||||||
PORT=5942
|
PORT=5942
|
||||||
|
|
||||||
# x402 payments required to access this API?
|
# x402 payments required to access this API?
|
||||||
X402_ENABLED=true
|
X402_ENABLED=false
|
||||||
SERVER_BCH_ADDRESS=bitcoincash:qqlrzp23w08434twmvr4fxw672whkjy0py26r63g3d
|
#X402_ENABLED=true
|
||||||
FACILITATOR_URL=http://localhost:4345/facilitator
|
#SERVER_BCH_ADDRESS=bitcoincash:qqlrzp23w08434twmvr4fxw672whkjy0py26r63g3d
|
||||||
X402_PRICE_SAT=200
|
#FACILITATOR_URL=http://localhost:4345/facilitator
|
||||||
|
#X402_PRICE_SAT=200
|
||||||
|
|
||||||
# Basic Authentication required to access this API?
|
# Basic Authentication required to access this API?
|
||||||
USE_BASIC_AUTH=true
|
USE_BASIC_AUTH=false
|
||||||
BASIC_AUTH_TOKEN=some-random-token
|
#USE_BASIC_AUTH=true
|
||||||
|
#BASIC_AUTH_TOKEN=some-random-token
|
||||||
|
|
||||||
# END ACCESS CONTROL
|
# END ACCESS CONTROL
|
||||||
|
|
||||||
|
|||||||
@@ -51,6 +51,8 @@ RUN git clone https://github.com/Permissionless-Software-Foundation/psf-bch-api
|
|||||||
# and `stage` has the most up-to-date changes.
|
# and `stage` has the most up-to-date changes.
|
||||||
WORKDIR /home/safeuser/psf-bch-api
|
WORKDIR /home/safeuser/psf-bch-api
|
||||||
|
|
||||||
|
RUN git checkout ct-unstable
|
||||||
|
|
||||||
# Install dependencies
|
# Install dependencies
|
||||||
RUN npm install
|
RUN npm install
|
||||||
RUN npm install minimal-slp-wallet
|
RUN npm install minimal-slp-wallet
|
||||||
@@ -58,7 +60,7 @@ RUN npm install minimal-slp-wallet
|
|||||||
# Generate the API docs
|
# Generate the API docs
|
||||||
RUN npm run docs
|
RUN npm run docs
|
||||||
|
|
||||||
COPY .env-local .env
|
COPY .env .env
|
||||||
|
|
||||||
|
|
||||||
CMD ["npm", "start"]
|
CMD ["npm", "start"]
|
||||||
|
|||||||
@@ -1,3 +0,0 @@
|
|||||||
#!/bin/bash
|
|
||||||
|
|
||||||
npm start
|
|
||||||
@@ -1,7 +0,0 @@
|
|||||||
// Simple Node.js app that prints 'hello world' every 10 seconds
|
|
||||||
|
|
||||||
setInterval(() => {
|
|
||||||
console.log('hello world')
|
|
||||||
}, 10000)
|
|
||||||
|
|
||||||
console.log('Timer started. Printing "hello world" every 10 seconds...')
|
|
||||||
Reference in New Issue
Block a user