Skip to content

Instantly share code, notes, and snippets.

@muness
Created September 11, 2012 14:54
Show Gist options
  • Save muness/3699385 to your computer and use it in GitHub Desktop.
Save muness/3699385 to your computer and use it in GitHub Desktop.

Start a rest server by running:

bin/rest 8888 myalias "datomic:mem://"

Then interact with it with curl:

curl -i -X PUT http://localhost:8888/db/myalias/seattle # Create a database
curl -H Content-Type: -H "Content-Type:" -X POST -d @- http://localhost:8888/db/myalias/seattle
[              
{:db/id #db/id[:db.part/db]
 :db/ident :community/name
 :db/valueType :db.type/string
 :db/cardinality :db.cardinality/one
 :db/fulltext true
 :db/doc "A community's name"
 :db.install/_attribute :db.part/db}
]
^d
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment