-
Notifications
You must be signed in to change notification settings - Fork 1
Upload GML to 000000book
jamiew edited this page Sep 11, 2010
·
2 revisions
Sending your application’s GML data to blackbook is simple, and authenticating or registering your app is optional
Send an HTTP POST request to http://000000book.com/data with a data payload containing:
- gml (text)* — the complete GML data. this will be validated for required GML fields, e.g. at least one x/y point — see GML Minimum Specs — maximum functional size is approx. 1MB
- application (string)* — the name of your application; required, should be unique
If you are on Mac OS or Linux you can test uploading GML just using `curl`:
curl -A curlwriter -d application=curlwriter&gml="<gml><stroke><pt><x>1</x><y>1</y><t>1</t></pt></stroke></gml>" http://000000book.com/data
- -A = specify a user-agent
- -d = the POST data to send – just need ‘application’ & ‘gml’
The following fields can be specified either in the GML or via HTTP POST to #000000book, which will write them into the GML for you.
- keywords (string) [comma-separated list of keywords (‘tags’, not to be confused w/ graf tags)]
- location (string) [name like ‘NYC’, lat/long coordinates, or even a URL]
- uniqueKey (string) [a unique device id for device pairing, e.g. iPhone UUID or computer MAC address] (NOTE: currently this field must be in the GML, it is not accepted via POST)
- username (string) [a 000000book user’s login]
- author (string) [the person who was actually writing]
The “uniqueKey” payload can also be provided in order to uniquely identify the uploading device, e.g. an iPhone. User’s can later pair their 000000book account with a specified uniqueKey — see Device Pairing