PECS Data Service
This is a data service for the Pathfinder Excessive Character Sheet. It serves a simple http(s) server for GET and POST queries and performs the necessary operations on either the locally stored data file or a connected MongoDB database in order to manage and retrieve characters. The service also servesexchanges inter-party event triggers ("messages")") between players.
Compatibility
PECS Data Service v1.0.4 requires PECS v1.0.10, and vice versa.
Running the service
If you are running PECS from a release, you don't need this. The PECS application includes all functions of the service. You only need it if you are running PECS directly from Node.js for development purposes.
The config.json file can be configured with the following parameters (see config.json.example for examples):
-
MongoDBConnectionURL
: your mongodb:// connection URL with user and password (if needed) and all configuration parameters -
MongoDBDatabase
: The database on your MongoDB server that contains the PECS collections -
MongoDBCharacterCollection
: The name of the collection that contains the characters. -
HTTPPort
: Your desired HTTP port. Default 8080. -
HTTPSPort
: Your desired HTTP port. Default 8443. -
SSLCertificatePath
: The absolute or relative path to your ssl certificate, starting from the path from which you started node. -
SSLPrivateKeyPath
: The absolute or relative path to your ssl private key matching the certificate, starting from the path from which you started node. -
Password
: An optional password that will be required by PECS before players can use it. -
MongoDBConnectionURL
: your mongodb:// connection URL with user and password (if needed) and all configuration parameters -
MongoDBDatabase
: The database on your MongoDB server that contains the PECS collections -
MongoDBCharacterCollection
: The name of the collection that contains the characters. -
ConvertMongoDBToLocal
: Only used to convert characters from MongoDB to the local data file. Requires MongoDBConnectionURL and MongoDBDatabase, and the service cannot be connected to while all three parameters are configured. It will stop after conversion.