Indexes and caches contract data to make the api client application faster and more flexible.
Build source (see below to run without java/maven) from the root directory
./build.sh
or directly..
cd stxeco-api
mvn clean install # or mvn -Dmaven.test.skip=true clean install
cd ..
docker-compose build
docker-compose up -d
Build locally from docker images should be possible as long as the docker images in docker hub are public.
The following may work
docker-compose -f docker-compose-images.yml pull
docker-compose -f docker-compose-images.yml up -d
and to kill the containers..
docker-compose -f docker-compose-images.yml down
Deploy on testnet using
./deploy-stxeco.sh
Deploy on mainnet using
./deploy-stxeco.sh prod
Note: Requires your ssh key to be installed on the server.
The API is written in Java and has no documentation as yet. Quickest way to locate API end points is to search for the annotation;
@RestController
These classes contain all the api mappings. E.g.
@GetMapping(value = "/v2/gh-issues")
// inside
@RestController
public class IssueController { ... }
Is a GET end point for fetching github issues. POST,PUT,DELETE mappings are marked by similar annotations - @PostMapping etc.
Path parameters and post body parameters are marked;
@PathVariable String contractId
@RequestBody Object jsonBean