From c56bef1788a0155096e60884390ebb5e169d358d Mon Sep 17 00:00:00 2001 From: Christian Weiss Date: Mon, 9 Dec 2019 22:17:25 +0100 Subject: [PATCH 1/3] resolves #152, true draft-03 schema files (no wrapper, no "empty schema"), draft-07 will follow --- specs/README.md | 20 + specs/draft-03/0.1.json | 382 ++++++++++++ specs/draft-03/0.2.0.json | 426 +++++++++++++ specs/draft-03/0.2.1.json | 481 +++++++++++++++ specs/draft-03/0.3.0.json | 492 +++++++++++++++ specs/draft-03/0.3.1.json | 533 ++++++++++++++++ specs/draft-03/0.3.2.json | 543 ++++++++++++++++ specs/draft-03/0.4.0.json | 797 ++++++++++++++++++++++++ specs/draft-03/0.4.1.json | 798 ++++++++++++++++++++++++ specs/draft-03/0.4.10.json | 973 +++++++++++++++++++++++++++++ specs/draft-03/0.4.11.json | 1000 ++++++++++++++++++++++++++++++ specs/draft-03/0.4.12.json | 1001 ++++++++++++++++++++++++++++++ specs/draft-03/0.4.13.json | 1016 ++++++++++++++++++++++++++++++ specs/draft-03/0.4.14.json | 1018 ++++++++++++++++++++++++++++++ specs/draft-03/0.4.2.json | 876 ++++++++++++++++++++++++++ specs/draft-03/0.4.3.json | 915 +++++++++++++++++++++++++++ specs/draft-03/0.4.4.json | 923 ++++++++++++++++++++++++++++ specs/draft-03/0.4.5.json | 925 ++++++++++++++++++++++++++++ specs/draft-03/0.4.6.json | 933 ++++++++++++++++++++++++++++ specs/draft-03/0.4.7.json | 935 ++++++++++++++++++++++++++++ specs/draft-03/0.4.8.json | 936 ++++++++++++++++++++++++++++ specs/draft-03/0.4.9.json | 938 ++++++++++++++++++++++++++++ specs/draft-03/README.md | 12 + specs/draft-03/development.json | 1019 +++++++++++++++++++++++++++++++ specs/draft-07/README.md | 20 + 25 files changed, 17912 insertions(+) create mode 100644 specs/README.md create mode 100644 specs/draft-03/0.1.json create mode 100644 specs/draft-03/0.2.0.json create mode 100644 specs/draft-03/0.2.1.json create mode 100644 specs/draft-03/0.3.0.json create mode 100644 specs/draft-03/0.3.1.json create mode 100644 specs/draft-03/0.3.2.json create mode 100644 specs/draft-03/0.4.0.json create mode 100644 specs/draft-03/0.4.1.json create mode 100644 specs/draft-03/0.4.10.json create mode 100644 specs/draft-03/0.4.11.json create mode 100644 specs/draft-03/0.4.12.json create mode 100644 specs/draft-03/0.4.13.json create mode 100644 specs/draft-03/0.4.14.json create mode 100644 specs/draft-03/0.4.2.json create mode 100644 specs/draft-03/0.4.3.json create mode 100644 specs/draft-03/0.4.4.json create mode 100644 specs/draft-03/0.4.5.json create mode 100644 specs/draft-03/0.4.6.json create mode 100644 specs/draft-03/0.4.7.json create mode 100644 specs/draft-03/0.4.8.json create mode 100644 specs/draft-03/0.4.9.json create mode 100644 specs/draft-03/README.md create mode 100644 specs/draft-03/development.json create mode 100644 specs/draft-07/README.md diff --git a/specs/README.md b/specs/README.md new file mode 100644 index 0000000..5c7af3e --- /dev/null +++ b/specs/README.md @@ -0,0 +1,20 @@ +# WARNING: draft-03 is DEPRECATED +JSON meta schema draft-03 has been deprecated by json-schema.org please migrate to a newer draft version as soon as +possible. + +# Why files in this folder are bad (draft-03 with wrapper) +Files in /specs/*.json are, so called, "empty schema" files, where typical schema elements are missing +at root level of that JSON. Instead, these typical elements are below the "schema" key +(which is NOT an offical schema element). This key acts as a "wrapper". If you want to validate a JSON instance file +against these schema files, then you need to extract the JSON schema from "schema" key. If you do not extract, then +your JSON Instance will be evaluated against an "empty schema". Every possible JSON Instance would be valid against +these "empty schema" files, rendering the validation process useless. + +# Update your implementation +As draft-03 is deprecated you should no longer use it. Update your implementation to use e.g. draft-07. You may update +to a newer library version or to other lib, validator, form UI vendors that support draft-07 schema files. See [draft-07](draft-07) + +# If you are not able to migrate now +If you can not change your implementation to use a lib/validator/formUI that supports draft-07, then you should at +least switch to the files in /specs/draft-03/ which are true schema files (no wrapper / no "empty schema"). +If your code did "schema"-key-extraction then change your code and access schema directly at root level. \ No newline at end of file diff --git a/specs/draft-03/0.1.json b/specs/draft-03/0.1.json new file mode 100644 index 0000000..92382d7 --- /dev/null +++ b/specs/draft-03/0.1.json @@ -0,0 +1,382 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.1", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1" + ], + "default": "0.1", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "description": "Email address to which other people can contact your community", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "description": "URL to your community's facebook account", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "description": "URL to your community's identica account", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "description": "your community's irc channel", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "description": "a jabber account someone reads", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address of your mailing list. If you use google groups then the email looks like your-group@googlegroups.com", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "description": "URL to your community's twitter account", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "description": "The main website", + "required": true + }, + "events": { + "type": "array", + "description": "These are events something like 'X has entered/triggered/did Y at timestamp Z'", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "extra": { + "title": "Extra information", + "type": "string", + "description": "An custom text field", + "required": false + }, + "title": { + "title": "Title", + "type": "string", + "description": "name of the event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "number", + "description": "Unix timestamp when the event happens", + "required": false + }, + "location": { + "title": "Location", + "type": "string", + "description": "location of the event", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "number", + "description": "At what (unix) timestamp has your community status lastly changed?", + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "stoererhaftung": { + "title": "Störerhaftung", + "description": "how the German störerhaftung is handled", + "required": false, + "type": "string" + }, + "bootstrap": { + "title": "Bootstrap", + "type": "string", + "description": "how to deal with fresh routers", + "required": false + }, + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download and docs", + "type": "string", + "description": "link to your firmware images or docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "keyexchange": { + "type": "string", + "description": "needs to be defined", + "required": false + }, + "networks": { + "title": "Networks", + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "prefixlength": { + "type": "integer", + "description": "prefix length", + "required": false + }, + "prefix": { + "type": "string", + "description": "ipv6 network prefix", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "netmask": { + "type": "integer", + "description": "the netmask valid for this network", + "required": false + }, + "network": { + "type": "string", + "description": "network name (e.g. 10.63.x.y)", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocol", + "description": "routing protocol used within your community", + "required": false, + "enum": [ + "", + "OLSR", + "BATMAN", + "Babel", + "802.11s" + ], + "default": "" + }, + "splashpage": { + "title": "Splash Page", + "type": "string", + "description": "what kind of splashpage does your community use?", + "required": false + }, + "topodata": { + "title": "Topology data", + "type": "string", + "description": "link to your topology data (dot-files? needs to be defined)", + "required": false + }, + "updatemode": { + "title": "Updatemode", + "type": "string", + "description": "how do you deploy firmware updates?", + "required": false + }, + "vpn": { + "title": "VPN", + "type": "string", + "description": "implementation of inner city vpn", + "required": false + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.2.0.json b/specs/draft-03/0.2.0.json new file mode 100644 index 0000000..dea545e --- /dev/null +++ b/specs/draft-03/0.2.0.json @@ -0,0 +1,426 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.2.0", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0" + ], + "default": "0.2.0", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "description": "Email address to which other people can contact your community", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "description": "URL to your community's facebook account", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "description": "URL to your community's identica account", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "description": "your community's irc channel", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "description": "a jabber account someone reads", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address of your mailing list. If you use google groups then the email looks like your-group@googlegroups.com", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "description": "URL to your community's twitter account", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "description": "The main website", + "required": true + }, + "events": { + "title": "Events", + "type": "string", + "description": "URL to your calendar ics file that can be imported to a global calendar", + "required": false + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "number", + "description": "At what (unix) timestamp has your community status lastly changed?", + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "olsr-dot", + "openwifimap" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "stoererhaftung": { + "title": "Störerhaftung", + "description": "how the German störerhaftung is handled", + "required": false, + "type": "string" + }, + "bootstrap": { + "title": "Bootstrap", + "type": "string", + "description": "how to deal with fresh routers", + "required": false + }, + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download and docs", + "type": "string", + "description": "link to your firmware images or docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "keyexchange": { + "type": "string", + "description": "needs to be defined", + "required": false + }, + "networks": { + "title": "Networks", + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "prefixlength": { + "type": "integer", + "description": "prefix length", + "required": false + }, + "prefix": { + "type": "string", + "description": "ipv6 network prefix", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "netmask": { + "type": "integer", + "description": "the netmask valid for this network", + "required": false + }, + "network": { + "type": "string", + "description": "network name (e.g. 10.63.x.y)", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocol", + "description": "routing protocol used within your community", + "required": false, + "enum": [ + "", + "OLSR", + "BATMAN", + "Babel", + "802.11s" + ], + "default": "" + }, + "splashpage": { + "title": "Splash Page", + "type": "string", + "description": "what kind of splashpage does your community use?", + "required": false + }, + "topodata": { + "title": "Topology data", + "type": "string", + "description": "link to your topology data (dot-files? needs to be defined)", + "required": false + }, + "updatemode": { + "title": "Updatemode", + "type": "string", + "description": "how do you deploy firmware updates?", + "required": false + }, + "vpn": { + "title": "VPN", + "type": "string", + "description": "implementation of inner city vpn", + "required": false + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.2.1.json b/specs/draft-03/0.2.1.json new file mode 100644 index 0000000..ee8fa99 --- /dev/null +++ b/specs/draft-03/0.2.1.json @@ -0,0 +1,481 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.2.1", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1" + ], + "default": "0.2.1", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "description": "URL to your community's identica account", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "description": "your community's irc channel", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "description": "a jabber account someone reads", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address of your mailing list or a link to the mailinglist info page ", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed?", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "olsr-dot", + "openwifimap" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "stoererhaftung": { + "title": "Störerhaftung", + "description": "how the German störerhaftung is handled", + "required": false, + "type": "string" + }, + "bootstrap": { + "title": "Bootstrap", + "type": "string", + "description": "how to deal with fresh routers", + "required": false + }, + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download and docs", + "type": "string", + "description": "link to your firmware images or docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "keyexchange": { + "type": "string", + "description": "needs to be defined", + "required": false + }, + "tld": { + "title": "Top Level Domain", + "description": "the top level domain used by your community", + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the top level domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z]{2,}$", + "required": false, + "title": "Top Level Domain Name" + }, + "nameserver": { + "type": "array", + "title": "TLD Nameserver", + "description": "Nameservers servings zones of your top level domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]*$", + "required": false + } + } + } + }, + "networks": { + "title": "Networks", + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocol", + "description": "routing protocol used within your community", + "required": false, + "enum": [ + "", + "OLSR", + "BATMAN", + "Babel", + "802.11s" + ], + "default": "" + }, + "splashpage": { + "title": "Splash Page", + "type": "string", + "description": "what kind of splashpage does your community use?", + "required": false + }, + "topodata": { + "title": "Topology data", + "type": "string", + "description": "link to your topology data (dot-files? needs to be defined)", + "required": false + }, + "updatemode": { + "title": "Updatemode", + "type": "string", + "description": "how do you deploy firmware updates?", + "required": false + }, + "vpn": { + "title": "VPN", + "type": "string", + "description": "implementation of inner city vpn", + "required": false + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.3.0.json b/specs/draft-03/0.3.0.json new file mode 100644 index 0000000..bb45ded --- /dev/null +++ b/specs/draft-03/0.3.0.json @@ -0,0 +1,492 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.3.0", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0" + ], + "default": "0.3.0", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "description": "URL to your community's identica account", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "description": "a jabber account someone reads", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "olsr-dot", + "openwifimap" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "stoererhaftung": { + "title": "Störerhaftung", + "description": "how the German störerhaftung is handled", + "required": false, + "type": "string" + }, + "bootstrap": { + "title": "Bootstrap", + "type": "string", + "description": "how to deal with fresh routers", + "required": false + }, + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download and docs", + "type": "string", + "description": "link to your firmware images or docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "keyexchange": { + "type": "string", + "description": "needs to be defined", + "required": false + }, + "tld": { + "title": "Top Level Domain", + "description": "the top level domain used by your community", + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the top level domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z]{2,}$", + "required": false, + "title": "Top Level Domain Name" + }, + "nameserver": { + "type": "array", + "title": "TLD Nameserver", + "description": "Nameservers servings zones of your top level domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]*$", + "required": false + } + } + } + }, + "networks": { + "title": "Networks", + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocol", + "description": "routing protocol used within your community", + "required": false, + "enum": [ + "", + "OLSR", + "BATMAN", + "Babel", + "802.11s", + "batman-adv", + "bmx", + "OLSRv2" + ], + "default": "" + }, + "splashpage": { + "title": "Splash Page", + "type": "string", + "description": "what kind of splashpage does your community use?", + "required": false + }, + "topodata": { + "title": "Topology data", + "type": "string", + "description": "link to your topology data (dot-files? needs to be defined)", + "required": false + }, + "updatemode": { + "title": "Updatemode", + "type": "string", + "description": "how do you deploy firmware updates?", + "required": false + }, + "vpn": { + "title": "VPN", + "type": "string", + "description": "implementation of inner city vpn", + "required": false + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.3.1.json b/specs/draft-03/0.3.1.json new file mode 100644 index 0000000..10d0097 --- /dev/null +++ b/specs/draft-03/0.3.1.json @@ -0,0 +1,533 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.3.1", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1" + ], + "default": "0.3.1", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened (format yyyy-mm-dd)", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "stoererhaftung": { + "title": "Störerhaftung", + "description": "how the German störerhaftung is handled", + "required": false, + "type": "string" + }, + "bootstrap": { + "title": "Bootstrap", + "type": "string", + "description": "how to deal with fresh routers", + "required": false + }, + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download and docs", + "type": "string", + "description": "link to your firmware images or docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "keyexchange": { + "type": "string", + "description": "needs to be defined", + "required": false + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]*$", + "required": false + } + } + } + } + }, + "networks": { + "title": "Networks", + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocol", + "description": "routing protocol used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "splashpage": { + "title": "Splash Page", + "type": "string", + "description": "what kind of splashpage does your community use?", + "required": false + }, + "updatemode": { + "title": "Updatemode", + "type": "string", + "description": "how do you deploy firmware updates?", + "required": false + }, + "vpn": { + "title": "VPN", + "type": "string", + "description": "implementation of inner city vpn", + "required": false + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.3.2.json b/specs/draft-03/0.3.2.json new file mode 100644 index 0000000..2a73439 --- /dev/null +++ b/specs/draft-03/0.3.2.json @@ -0,0 +1,543 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.3.2", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2" + ], + "default": "0.3.2", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened (format yyyy-mm-dd)", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "stoererhaftung": { + "title": "Störerhaftung", + "description": "how the German störerhaftung is handled", + "required": false, + "type": "string" + }, + "bootstrap": { + "title": "Bootstrap", + "type": "string", + "description": "how to deal with fresh routers", + "required": false + }, + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download and docs", + "type": "string", + "description": "link to your firmware images or docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "keyexchange": { + "type": "string", + "description": "needs to be defined", + "required": false + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]*$", + "required": false + } + } + } + } + }, + "networks": { + "title": "Networks", + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocol", + "description": "routing protocol used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "splashpage": { + "title": "Splash Page", + "type": "string", + "description": "what kind of splashpage does your community use?", + "required": false + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + }, + "vpn": { + "title": "VPN", + "type": "string", + "description": "implementation of inner city vpn", + "required": false + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.0.json b/specs/draft-03/0.4.0.json new file mode 100644 index 0000000..977cc1e --- /dev/null +++ b/specs/draft-03/0.4.0.json @@ -0,0 +1,797 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.0", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0" + ], + "default": "0.4.0", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened (format yyyy-mm-dd)", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.1.json b/specs/draft-03/0.4.1.json new file mode 100644 index 0000000..8db2792 --- /dev/null +++ b/specs/draft-03/0.4.1.json @@ -0,0 +1,798 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.1", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1" + ], + "default": "0.4.1", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, ISO-2, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened (format yyyy-mm-dd)", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.10.json b/specs/draft-03/0.4.10.json new file mode 100644 index 0000000..d721c18 --- /dev/null +++ b/specs/draft-03/0.4.10.json @@ -0,0 +1,973 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.10", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8", + "0.4.9", + "0.4.10" + ], + "default": "0.4.10", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist", + "meshviewer" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "vpnaccess": { + "title": "VPN Access", + "type": "string", + "enum": [ + "", + "automatic", + "fwimage", + "mail", + "webform", + "else" + ], + "default": "", + "description": "How to access your VPN services", + "required": false + }, + "registrationurl": { + "title": "VPN Registration URL", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your website to request a new VPN key", + "required": false + }, + "orgrestrictions": { + "title": "Organizational Restrictions", + "type": "string", + "description": "Are there any organizational restrictions when using/installing your firmware?", + "required": false + }, + "techrestrictions": { + "title": "Technical Restrictions", + "type": "string", + "description": "Are there any technical restrictions like hardware?", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.11.json b/specs/draft-03/0.4.11.json new file mode 100644 index 0000000..7f16271 --- /dev/null +++ b/specs/draft-03/0.4.11.json @@ -0,0 +1,1000 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.11", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8", + "0.4.9", + "0.4.10", + "0.4.11" + ], + "default": "0.4.11", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist", + "meshviewer" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "socialprojects": { + "title": "Refugees and social support projects", + "type": "object", + "required": false, + "properties": { + "number": { + "title": "Number of projects", + "type": "number", + "description": "Number of projects supported by your Community", + "required": false + }, + "website": { + "title": "URL of your infopage", + "type": "string", + "description": "A link to a web site where people can find an overview over your projects", + "required": false + }, + "contact": { + "title": "Contact email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Please provide an email address to contact you on refugees and social projects", + "required": false + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "vpnaccess": { + "title": "VPN Access", + "type": "string", + "enum": [ + "", + "automatic", + "fwimage", + "mail", + "webform", + "else" + ], + "default": "", + "description": "How to access your VPN services", + "required": false + }, + "registrationurl": { + "title": "VPN Registration URL", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your website to request a new VPN key", + "required": false + }, + "orgrestrictions": { + "title": "Organizational Restrictions", + "type": "string", + "description": "Are there any organizational restrictions when using/installing your firmware?", + "required": false + }, + "techrestrictions": { + "title": "Technical Restrictions", + "type": "string", + "description": "Are there any technical restrictions like hardware?", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.12.json b/specs/draft-03/0.4.12.json new file mode 100644 index 0000000..2054ac4 --- /dev/null +++ b/specs/draft-03/0.4.12.json @@ -0,0 +1,1001 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.12", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8", + "0.4.9", + "0.4.10", + "0.4.11", + "0.4.12" + ], + "default": "0.4.12", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9_\\-]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist", + "meshviewer" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "socialprojects": { + "title": "Refugees and social support projects", + "type": "object", + "required": false, + "properties": { + "number": { + "title": "Number of projects", + "type": "number", + "description": "Number of projects supported by your Community", + "required": false + }, + "website": { + "title": "URL of your infopage", + "type": "string", + "description": "A link to a web site where people can find an overview over your projects", + "required": false + }, + "contact": { + "title": "Contact email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Please provide an email address to contact you on refugees and social projects", + "required": false + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "vpnaccess": { + "title": "VPN Access", + "type": "string", + "enum": [ + "", + "automatic", + "fwimage", + "mail", + "webform", + "else" + ], + "default": "", + "description": "How to access your VPN services", + "required": false + }, + "registrationurl": { + "title": "VPN Registration URL", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your website to request a new VPN key", + "required": false + }, + "orgrestrictions": { + "title": "Organizational Restrictions", + "type": "string", + "description": "Are there any organizational restrictions when using/installing your firmware?", + "required": false + }, + "techrestrictions": { + "title": "Technical Restrictions", + "type": "string", + "description": "Are there any technical restrictions like hardware?", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.13.json b/specs/draft-03/0.4.13.json new file mode 100644 index 0000000..fdbd7b3 --- /dev/null +++ b/specs/draft-03/0.4.13.json @@ -0,0 +1,1016 @@ +{ + "type": "object", + "description": "Freifunk Community API X.X.X", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8", + "0.4.9", + "0.4.10", + "0.4.11", + "0.4.12", + "0.4.13" + ], + "default": "0.4.13", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9_\\-]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist", + "meshviewer" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "socialprojects": { + "title": "Refugees and social support projects", + "type": "object", + "required": false, + "properties": { + "number": { + "title": "Number of projects", + "type": "number", + "description": "Number of projects supported by your Community", + "required": false + }, + "website": { + "title": "URL of your infopage", + "type": "string", + "description": "A link to a web site where people can find an overview over your projects", + "required": false + }, + "contact": { + "title": "Contact email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Please provide an email address to contact you on refugees and social projects", + "required": false + } + } + }, + "privacy": { + "title": "Privacy Policy", + "type": "object", + "required": false, + "properties": { + "policyurl": { + "title": "Privacy Policy URL", + "description": "URL to your privacy policy description", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "vpnaccess": { + "title": "VPN Access", + "type": "string", + "enum": [ + "", + "automatic", + "fwimage", + "mail", + "webform", + "else" + ], + "default": "", + "description": "How to access your VPN services", + "required": false + }, + "registrationurl": { + "title": "VPN Registration URL", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your website to request a new VPN key", + "required": false + }, + "orgrestrictions": { + "title": "Organizational Restrictions", + "type": "string", + "description": "Are there any organizational restrictions when using/installing your firmware?", + "required": false + }, + "techrestrictions": { + "title": "Technical Restrictions", + "type": "string", + "description": "Are there any technical restrictions like hardware?", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers serving zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.14.json b/specs/draft-03/0.4.14.json new file mode 100644 index 0000000..d9d82c7 --- /dev/null +++ b/specs/draft-03/0.4.14.json @@ -0,0 +1,1018 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.14", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8", + "0.4.9", + "0.4.10", + "0.4.11", + "0.4.12", + "0.4.13", + "0.4.14" + ], + "default": "0.4.14", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community, if your local community belongs to a bigger one", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "Name of your city", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "The name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "The street address of your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "The zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "Your community's ICR channel; starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "A jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "If your community has a phone number (e.g. +49 1234 567890 based on the E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9_\\-]{1,15}", + "description": "Your community's Twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "Description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp of the event's date (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "URL to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "Name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "Category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "Type of the feed like RSS, Atom, XML", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "URL of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "Number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what ISO 8601 timestamp has your community status lastly changed?", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "Maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "URL of the map", + "type": "string", + "description": "The URL where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "How often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "The kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist", + "meshviewer", + "hopglass" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "The kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "Services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "Name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "Describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from Freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "Support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, Betterplace-IDs are multiple digits and can be found within the URL", + "required": false + } + } + } + } + } + } + } + }, + "socialprojects": { + "title": "Refugees and social support projects", + "type": "object", + "required": false, + "properties": { + "number": { + "title": "Number of projects", + "type": "number", + "description": "Number of projects supported by your Community", + "required": false + }, + "website": { + "title": "URL of your infopage", + "type": "string", + "description": "A link to a web site where people can find an overview over your projects", + "required": false + }, + "contact": { + "title": "Contact email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Please provide an email address to contact you on refugees and social projects", + "required": false + } + } + }, + "privacy": { + "title": "Privacy Policy", + "type": "object", + "required": false, + "properties": { + "policyurl": { + "title": "Privacy Policy URL", + "description": "URL to your privacy policy description", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "Technical details of your community's Freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "Link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "Link to your firmware docs", + "required": false + }, + "vpnaccess": { + "title": "VPN Access", + "type": "string", + "enum": [ + "", + "automatic", + "fwimage", + "mail", + "webform", + "else" + ], + "default": "", + "description": "How to access your VPN services", + "required": false + }, + "registrationurl": { + "title": "VPN Registration URL", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your website to request a new VPN key", + "required": false + }, + "orgrestrictions": { + "title": "Organizational Restrictions", + "type": "string", + "description": "Are there any organizational restrictions when using/installing your firmware?", + "required": false + }, + "techrestrictions": { + "title": "Technical Restrictions", + "type": "string", + "description": "Are there any technical restrictions like hardware?", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "Name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "DNS servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "The domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "Networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "IPv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "IPv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "IPv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "IPv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "Routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "How do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.2.json b/specs/draft-03/0.4.2.json new file mode 100644 index 0000000..91469c1 --- /dev/null +++ b/specs/draft-03/0.4.2.json @@ -0,0 +1,876 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.2", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2" + ], + "default": "0.4.2", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened (format yyyy-mm-dd)", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "array", + "title": "Donations", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.3.json b/specs/draft-03/0.4.3.json new file mode 100644 index 0000000..af63e1e --- /dev/null +++ b/specs/draft-03/0.4.3.json @@ -0,0 +1,915 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.3", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3" + ], + "default": "0.4.3", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "decription": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "description": "ISO timestamp when the event happened (format yyyy-mm-dd)", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.4.json b/specs/draft-03/0.4.4.json new file mode 100644 index 0000000..03e3fa3 --- /dev/null +++ b/specs/draft-03/0.4.4.json @@ -0,0 +1,923 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.4", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4" + ], + "default": "0.4.4", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.5.json b/specs/draft-03/0.4.5.json new file mode 100644 index 0000000..bd2b86b --- /dev/null +++ b/specs/draft-03/0.4.5.json @@ -0,0 +1,925 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.5", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5" + ], + "default": "0.4.5", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.6.json b/specs/draft-03/0.4.6.json new file mode 100644 index 0000000..16c29ec --- /dev/null +++ b/specs/draft-03/0.4.6.json @@ -0,0 +1,933 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.6", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6" + ], + "default": "0.4.6", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.7.json b/specs/draft-03/0.4.7.json new file mode 100644 index 0000000..a123774 --- /dev/null +++ b/specs/draft-03/0.4.7.json @@ -0,0 +1,935 @@ +{ + "type": "object", + "description": "Freifunk Community API X.X.X", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7" + ], + "default": "0.4.7", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^irc://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.8.json b/specs/draft-03/0.4.8.json new file mode 100644 index 0000000..dd4aa89 --- /dev/null +++ b/specs/draft-03/0.4.8.json @@ -0,0 +1,936 @@ +{ + "type": "object", + "description": "Freifunk Community API X.X.X", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8" + ], + "default": "0.4.8", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/0.4.9.json b/specs/draft-03/0.4.9.json new file mode 100644 index 0000000..c4d45f3 --- /dev/null +++ b/specs/draft-03/0.4.9.json @@ -0,0 +1,938 @@ +{ + "type": "object", + "description": "Freifunk Community API 0.4.9", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8", + "0.4.9" + ], + "default": "0.4.9", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community. if you local community belongs to a bigger community", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "name of your city or region", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "the name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "the street your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "the zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "your community's irc channel, starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "a jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "if your community has a phone number (e.g. +49 1234 567890 based on E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9]{1,15}", + "description": "Your community's twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp when the event happened (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "type of the feed like rss, atom, xml", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "url of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what iso timestamp has your community status lastly changed? (ISO 8601 timestamp)", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Url of the map", + "type": "string", + "description": "the url where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "how often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "the kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist", + "meshviewer" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "the kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, betterplace ids are multiple digits and can be found within the url", + "required": false + } + } + } + } + } + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "technical details of your community's freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your firmware docs", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "dns servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "the domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "ipv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "ipv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "ipv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "how do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-03/README.md b/specs/draft-03/README.md new file mode 100644 index 0000000..4fda581 --- /dev/null +++ b/specs/draft-03/README.md @@ -0,0 +1,12 @@ +# WARNING: draft-03 is DEPRECATED +JSON meta schema `draft-03` has been deprecated by json-schema.org please migrate to a newer draft version as soon as +possible. + +# Update your implementation +As `draft-03` is deprecated you should no longer use it. Update your implementation to use e.g. `draft-07`. +You may update to a newer library version or to other lib, validator, form UI vendors that support `draft-07` schema +files. + +# More details on draft-03 +See [old Freifunk API Schema (draft-03) with wrapper](../README.md) for explanation why `/specs/draft-03/*.json` is better then `/specs/*.json` +(if you want to stay at draft-03). diff --git a/specs/draft-03/development.json b/specs/draft-03/development.json new file mode 100644 index 0000000..0f3a9e8 --- /dev/null +++ b/specs/draft-03/development.json @@ -0,0 +1,1019 @@ +{ + "type": "object", + "description": "Freifunk Community API X.X.X", + "required": false, + "properties": { + "api": { + "title": "API", + "type": "string", + "description": "The Freifunk Community API version you use", + "enum": [ + "0.1", + "0.2.0", + "0.2.1", + "0.3.0", + "0.3.1", + "0.3.2", + "0.4.0", + "0.4.1", + "0.4.2", + "0.4.3", + "0.4.4", + "0.4.5", + "0.4.6", + "0.4.7", + "0.4.8", + "0.4.9", + "0.4.10", + "0.4.11", + "0.4.12", + "0.4.13", + "0.4.14", + "X.X.X" + ], + "default": "X.X.X", + "required": true + }, + "name": { + "title": "Name", + "type": "string", + "description": "The name of your community", + "required": true + }, + "metacommunity": { + "title": "Metacommunity", + "type": "string", + "description": "The name of your meta community, if your local community belongs to a bigger one", + "required": false + }, + "location": { + "title": "Location", + "type": "object", + "description": "Position data such as a postal address or geographic coordinates", + "required": true, + "properties": { + "city": { + "title": "City", + "type": "string", + "description": "Name of your city", + "required": true + }, + "country": { + "title": "Country", + "type": "string", + "description": "Your country, list taken from http://countrylist.net/de/", + "enum": [ + "", + "AF", + "AX", + "AL", + "DZ", + "AS", + "AD", + "AO", + "AI", + "AQ", + "AG", + "AR", + "AM", + "AW", + "AC", + "AU", + "AT", + "AZ", + "BS", + "BH", + "BD", + "BB", + "BY", + "BE", + "BZ", + "BJ", + "BM", + "BT", + "BO", + "BA", + "BW", + "BV", + "BR", + "IO", + "BN", + "BG", + "BF", + "BI", + "KH", + "CM", + "CA", + "IC", + "CV", + "KY", + "CF", + "TD", + "CL", + "CN", + "CX", + "CC", + "CO", + "KM", + "CG", + "CD", + "CK", + "CR", + "CI", + "HR", + "CU", + "CY", + "CZ", + "DK", + "DG", + "DJ", + "DM", + "DO", + "EC", + "EG", + "SV", + "GQ", + "ER", + "EE", + "ET", + "EU", + "FK", + "FO", + "FJ", + "FI", + "FR", + "GF", + "PF", + "TF", + "GA", + "GM", + "GE", + "DE", + "GH", + "GI", + "GR", + "GL", + "GD", + "GP", + "GU", + "GT", + "GG", + "GN", + "GW", + "GY", + "HT", + "HM", + "VA", + "HN", + "HK", + "HU", + "IS", + "IN", + "ID", + "IR", + "IQ", + "IE", + "IM", + "IL", + "IT", + "JM", + "JP", + "JE", + "JO", + "KZ", + "KE", + "KI", + "KP", + "KR", + "KW", + "KG", + "LA", + "LV", + "LB", + "LS", + "LR", + "LY", + "LI", + "LT", + "LU", + "MO", + "MK", + "MG", + "MW", + "MY", + "MV", + "ML", + "MT", + "MH", + "MQ", + "MR", + "MU", + "YT", + "MX", + "FM", + "MD", + "MC", + "MN", + "ME", + "MS", + "MA", + "MZ", + "MM", + "NA", + "NR", + "NP", + "NL", + "AN", + "NC", + "NZ", + "NI", + "NE", + "NG", + "NU", + "NF", + "MP", + "NO", + "OM", + "PK", + "PW", + "PS", + "PA", + "PG", + "PY", + "PE", + "PH", + "PN", + "PL", + "PT", + "PR", + "QA", + "RE", + "RO", + "RU", + "RW", + "SH", + "KN", + "LC", + "PM", + "VC", + "WS", + "SM", + "ST", + "SA", + "NT", + "SN", + "CS", + "SC", + "SL", + "SG", + "SK", + "SI", + "SB", + "SO", + "ZA", + "GS", + "SU", + "ES", + "LK", + "SD", + "SR", + "SJ", + "SZ", + "SE", + "CH", + "SY", + "TW", + "TJ", + "TZ", + "TH", + "TL", + "TG", + "TK", + "TO", + "TT", + "TA", + "TN", + "TR", + "TM", + "TC", + "TV", + "UG", + "UA", + "AE", + "GB", + "US", + "UY", + "UZ", + "VU", + "VE", + "VN", + "VG", + "VI", + "WF", + "EH", + "YE", + "ZM", + "ZW" + ], + "default": "", + "required": false + }, + "address": { + "type": "object", + "description": "The address of the place you meet", + "required": false, + "properties": { + "Name": { + "title": "Name of your place", + "type": "string", + "description": "The name of place you meet", + "required": false + }, + "Street": { + "title": "Street", + "type": "string", + "description": "The street address of your meeting place", + "required": false + }, + "Zipcode": { + "title": "ZIP", + "type": "string", + "description": "The zip code of your meeting place", + "required": false + } + } + }, + "lat": { + "title": "Latitude", + "type": "number", + "description": "Latitude of your city in decimal degrees (e.g. 51.12345)", + "required": true + }, + "lon": { + "title": "Longitude", + "type": "number", + "description": "Longitude of your city in decimal degrees (e.g. 11.6789)", + "required": true + } + } + }, + "contact": { + "type": "object", + "required": true, + "properties": { + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to which other people can contact your community (user@domain.com)", + "required": false + }, + "facebook": { + "title": "facebook", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)facebook\\.com/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's facebook account (https://facebook.com/...)", + "required": false + }, + "identica": { + "title": "Identica", + "type": "string", + "pattern": "^(http|https)://([a-z\\-]*\\.|)identi\\.ca/[A-Za-z0-9ÄÖÜäöüß\\-_\\.]+", + "description": "URL to your community's identica account (https://identi.ca/...)", + "required": false + }, + "irc": { + "title": "IRC", + "type": "string", + "pattern": "^(irc|ircs)://.*", + "description": "Your community's ICR channel; starts with irc://", + "required": false + }, + "jabber": { + "title": "Jabber", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}(\\?join){0,1}$", + "description": "A jabber account someone reads (account@jabberserver.tld)", + "required": false + }, + "ml": { + "title": "Mailinglist", + "type": "string", + "description": "The email address (user@domain.com) of your mailing list or a link to the mailinglist info page (http{s}://...)", + "pattern": "^([A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}|(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+)$", + "required": false + }, + "phone": { + "title": "Phone", + "type": "string", + "description": "If your community has a phone number (e.g. +49 1234 567890 based on the E.123 notation)", + "required": false + }, + "googleplus": { + "title": "Google+", + "type": "string", + "description": "URL to your community's g+ account (https://plus.google.com/...)", + "pattern": "^(http|https)://plus\\.google\\.com/[A-Za-z0-9ÄÖÜäöüß\\+\\-\\./_]+", + "required": false + }, + "twitter": { + "title": "Twitter", + "type": "string", + "pattern": "^@[A-Za-z0-9_\\-]{1,15}", + "description": "Your community's Twitter name (starts with @)", + "required": false + }, + "webform": { + "title": "Webform", + "type": "string", + "description": "URL to your community's contact form (http{s}://...)", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The main website (http{s}://...)", + "required": true + }, + "timeline": { + "type": "array", + "description": "These are lifetime events something like date of birth (and rebirth :-) of your community or other important milestones ", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "description": { + "title": "Description", + "type": "string", + "description": "Description of your lifetime event", + "required": false + }, + "timestamp": { + "title": "Timestamp", + "type": "string", + "pattern": "^([0-9]{4})(?:-?W([0-9]+)(?:-?([0-9]+)D?)?|(?:-([0-9]+))?-([0-9]+))(?:[T ]([0-9]+):([0-9]+)(?::([0-9]+)(?:\\.([0-9]+))?)?)?(?:Z(-?[0-9]*))?", + "description": "ISO 8601 timestamp of the event's date (format yyyy-mm-dd)", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "URL to details of this timeline-element", + "required": false + } + } + } + }, + "feeds": { + "type": "array", + "description": "Feeds you provide your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Feed name", + "type": "string", + "description": "Name of the feed", + "required": false + }, + "category": { + "title": "Feed category", + "type": "string", + "enum": [ + "blog", + "forum", + "ics", + "podcast", + "wiki", + "others", + "" + ], + "default": "", + "description": "Category of the feed like blog entries, calendars, forum messages, wiki articles, ...", + "required": false + }, + "type": { + "title": "Feed type", + "type": "string", + "description": "Type of the feed like RSS, Atom, XML", + "required": false + }, + "url": { + "title": "URL", + "type": "string", + "description": "URL of the feed", + "required": false + } + } + } + }, + "state": { + "type": "object", + "description": "A collection of status-related data. Actual open/closed status, icons, last change timestamp etc.", + "required": true, + "properties": { + "nodes": { + "title": "Active Nodes", + "type": "integer", + "description": "Number of active nodes. This field is predestined to be updated regularly, please see sample solutions for Gluon or OLSR", + "required": false + }, + "lastchange": { + "title": "Last Change", + "type": "string", + "description": "At what ISO 8601 timestamp has your community status lastly changed?", + "default": 0, + "required": true + }, + "message": { + "title": "Message", + "type": "string", + "description": "A free-form string something like 'open for public', 'members only' or whatever you want it to be)", + "required": false + }, + "description": { + "title": "Description", + "type": "string", + "description": "Describe your community in a few lines", + "required": false + }, + "focus": { + "title": "Focus", + "type": "array", + "description": "What's the focus of your local community?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "infrastructure/backbone", + "Public Free Wifi", + "Social Community Building", + "Local services and content", + "Free internet access" + ] + } + } + } + }, + "nodeMaps": { + "type": "array", + "description": "Maps of nodes or topology your community provides", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "URL of the map", + "type": "string", + "description": "The URL where the map is located", + "required": false + }, + "interval": { + "title": "interval", + "type": "string", + "description": "How often the map will be refreshed", + "required": false + }, + "technicalType": { + "title": "map technical type", + "type": "string", + "description": "The kind of map is used", + "enum": [ + "", + "ffmap", + "ffsomething", + "olsr-dot", + "openwifimap", + "netmon", + "libremap", + "nodewatcher", + "kml", + "nodelist", + "meshviewer", + "hopglass" + ], + "default": "", + "required": false + }, + "mapType": { + "title": "map type human readable", + "type": "string", + "description": "The kind of data the map provides", + "enum": [ + "", + "geographical", + "structural", + "list/status" + ], + "default": "", + "required": false + } + } + } + }, + "services": { + "type": "array", + "description": "Services provided by your community", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "serviceName": { + "title": "Service Name", + "type": "string", + "description": "Name of your service (e.g. jabber...)", + "required": false + }, + "serviceDescription": { + "title": "Service Description", + "type": "string", + "description": "Describe your service", + "required": false + }, + "externalUri": { + "title": "External URI", + "type": "string", + "description": "URI to use your service from the internet", + "required": false + }, + "internalUri": { + "title": "Internal URI", + "type": "string", + "description": "URI to use your service from Freifunk or icvpn-networks", + "required": false + } + } + } + }, + "support": { + "type": "object", + "description": "Support for your community, e.g. by a local club, and donations via campaigns e.g. by betterplace.de", + "required": false, + "properties": { + "club": { + "title": "Supporting Club", + "type": "object", + "required": false, + "properties": { + "name": { + "title": "Club Name", + "type": "string", + "description": "Name of the Club", + "required": false + }, + "street": { + "title": "Street", + "type": "string", + "description": "Address - Street", + "required": false + }, + "zip": { + "title": "zip", + "type": "string", + "description": "Address - ZIP", + "required": false + }, + "city": { + "title": "City", + "type": "string", + "description": "Address - City", + "required": false + }, + "url": { + "title": "Homepage", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "The club's website (http{s}://...)", + "required": false + }, + "email": { + "title": "Email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Email address to contact the club (user@domain.com)", + "required": false + }, + "board": { + "title": "Board Members", + "type": "array", + "description": "Who are board members of the club?", + "required": false, + "items": { + "type": "string", + "title": "name", + "required": false + } + } + } + }, + "donations": { + "type": "object", + "title": "Donations", + "required": false, + "properties": { + "bankaccount": { + "type": "object", + "title": "Bank Account", + "required": false, + "properties": { + "IBAN": { + "type": "string", + "title": "IBAN", + "required": false + }, + "BIC": { + "type": "string", + "title": "BIC", + "required": false + }, + "usage": { + "type": "string", + "title": "Usage of the donation", + "description": "Please use this string as transfer-purpose to define a special usage of your donation.", + "required": false + } + } + }, + "campaigns": { + "title": "Campagins", + "type": "array", + "required": false, + "items": { + "type": "object", + "required": false, + "properties": { + "provider": { + "title": "Campaign Provider", + "type": "string", + "description": "Where do you host your donations?", + "enum": [ + "", + "betterplace", + "boost" + ], + "default": "", + "required": false + }, + "projectid": { + "title": "Project ID", + "type": "string", + "description": "ID of your project, Betterplace-IDs are multiple digits and can be found within the URL", + "required": false + } + } + } + } + } + } + } + }, + "socialprojects": { + "title": "Refugees and social support projects", + "type": "object", + "required": false, + "properties": { + "number": { + "title": "Number of projects", + "type": "number", + "description": "Number of projects supported by your Community", + "required": false + }, + "website": { + "title": "URL of your infopage", + "type": "string", + "description": "A link to a web site where people can find an overview over your projects", + "required": false + }, + "contact": { + "title": "Contact email", + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖUß_\\-\\.]+@[A-Za-z0-9äöüÄÖUß_\\-\\.]+\\.[A-Za-z]{2,}$", + "description": "Please provide an email address to contact you on refugees and social projects", + "required": false + } + } + }, + "privacy": { + "title": "Privacy Policy", + "type": "object", + "required": false, + "properties": { + "policyurl": { + "title": "Privacy Policy URL", + "description": "URL to your privacy policy description", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "required": false + } + } + }, + "techDetails": { + "type": "object", + "id": "http://wiki.freifunk.net/Freifunk_Firmware/%C3%9Cbersicht_Communities", + "description": "Technical details of your community's Freifunk implementation", + "required": false, + "properties": { + "firmware": { + "type": "object", + "required": false, + "properties": { + "url": { + "title": "Firmware download", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "Link to your firmware images", + "required": false + }, + "docs": { + "title": "Firmware Documents", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "Link to your firmware docs", + "required": false + }, + "vpnaccess": { + "title": "VPN Access", + "type": "string", + "enum": [ + "", + "automatic", + "fwimage", + "mail", + "webform", + "else" + ], + "default": "", + "description": "How to access your VPN services", + "required": false + }, + "registrationurl": { + "title": "VPN Registration URL", + "type": "string", + "pattern": "^(http|https)://[A-Za-z0-9ÄÖÜäöüß\\-_\\./]+", + "description": "link to your website to request a new VPN key", + "required": false + }, + "orgrestrictions": { + "title": "Organizational Restrictions", + "type": "string", + "description": "Are there any organizational restrictions when using/installing your firmware?", + "required": false + }, + "techrestrictions": { + "title": "Technical Restrictions", + "type": "string", + "description": "Are there any technical restrictions like hardware?", + "required": false + }, + "name": { + "title": "Firmware Name", + "type": "string", + "description": "Name of your firmware", + "required": false + } + } + }, + "dns": { + "title": "DNS Servers", + "descripition": "DNS servers for domains used by your community", + "type": "array", + "items": { + "type": "object", + "required": false, + "properties": { + "domainname": { + "type": "string", + "description": "The domain name (e.g. ffhh, ffol)", + "pattern": "^[A-Za-z0-9äöüÄÖÜß\\.\\-\\_]{2,}$", + "required": false, + "title": "Domain Name" + }, + "nameserver": { + "type": "array", + "title": "Nameserver", + "description": "Nameservers servings zones of your domain", + "required": false, + "items": { + "type": "string", + "pattern": "^[A-Za-z0-9äöüÄÖÜß_\\-\\.:]*$", + "required": false + } + } + } + } + }, + "networks": { + "type": "object", + "description": "Networks used by your community", + "required": false, + "properties": { + "ipv6": { + "type": "array", + "title": "IPv6 networks", + "description": "IPv6 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv6 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "IPv6 network network (e.g.2620:0:2d0:200::7/32) in CIDR notation", + "pattern": "^\\s*((([0-9A-Fa-f]{1,4}:){7}([0-9A-Fa-f]{1,4}|:))|(([0-9A-Fa-f]{1,4}:){6}(:[0-9A-Fa-f]{1,4}|((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){5}(((:[0-9A-Fa-f]{1,4}){1,2})|:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3})|:))|(([0-9A-Fa-f]{1,4}:){4}(((:[0-9A-Fa-f]{1,4}){1,3})|((:[0-9A-Fa-f]{1,4})?:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){3}(((:[0-9A-Fa-f]{1,4}){1,4})|((:[0-9A-Fa-f]{1,4}){0,2}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){2}(((:[0-9A-Fa-f]{1,4}){1,5})|((:[0-9A-Fa-f]{1,4}){0,3}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(([0-9A-Fa-f]{1,4}:){1}(((:[0-9A-Fa-f]{1,4}){1,6})|((:[0-9A-Fa-f]{1,4}){0,4}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:))|(:(((:[0-9A-Fa-f]{1,4}){1,7})|((:[0-9A-Fa-f]{1,4}){0,5}:((25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)(\\.(25[0-5]|2[0-4]\\d|1\\d\\d|[1-9]?\\d)){3}))|:)))(%.+)?\\s*(\\/(\\d|\\d\\d|1[0-1]\\d|12[0-8]))$", + "required": false + } + } + } + }, + "ipv4": { + "type": "array", + "description": "IPv4 networks used by your community", + "required": false, + "items": { + "type": "object", + "title": "ipv4 network object", + "required": false, + "properties": { + "network": { + "type": "string", + "description": "IPv4 network name (e.g. 10.w.x.y/z) in CIDR notation", + "pattern": "^(([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])\\.){3}([0-9]|[1-9][0-9]|1[0-9]{2}|2[0-4][0-9]|25[0-5])(\\/(\\d|[1-2]\\d|3[0-2]))$", + "required": false + } + } + } + } + } + }, + "routing": { + "title": "Routing protocols", + "description": "Routing protocols used within your community", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "802.11s", + "Babel", + "batman-adv", + "bmx6", + "bmxd", + "cjdns", + "OLSR", + "OLSRv2" + ] + } + }, + "legals": { + "title": "Legal Issues", + "description": "What do you use to handle legal issues, e.g. the German Störerhaftung or restrictions in your country?", + "required": false, + "type": "array", + "items": { + "type": "string", + "title": "option", + "enum": [ + "nothing", + "vpnnational", + "vpninternational", + "zappscript", + "p2pblock", + "splashpage", + "termsconditions", + "anonymizer", + "institutions" + ] + } + }, + "updatemode": { + "title": "Updatemode", + "type": "array", + "description": "How do you deploy firmware updates?", + "required": false, + "items": { + "type": "string", + "title": "option", + "enum": [ + "none", + "manual", + "autoupdate" + ] + } + } + } + } + }, + "$schema": "http://json-schema.org/draft-03/schema#" +} diff --git a/specs/draft-07/README.md b/specs/draft-07/README.md new file mode 100644 index 0000000..8f331bd --- /dev/null +++ b/specs/draft-07/README.md @@ -0,0 +1,20 @@ +# Official Freifunk API Schema Files (draft-07) +JSON meta schema `draft-03` has been deprecated by json-schema.org please migrate to `draft-07` schema as soon as +possible. + +# Available Freifunk API Schema (draft-07) +Folder `/specs/draft-07/` starts with Freifunk API version `0.4.14`. Older versions are not available as `draft-07`. +If you have an older Freifunk Community API file (JSON instance) please update your file by following the migration path. + +# Migration Path +* `0.*.json` (draft-03) to `0.4.14.json` (draft-03) +* `0.4.14.json` (draft-03) to `0.4.14.json` (draft-07) +* `0.4.14.json` (draft-07) to latest Freifunk API Schema (draft-07) + +# Tools and libs +Known validators that support `draft-07` are: + - [ajv](https://github.com/epoberezkin/ajv) + - [jsonschema](https://github.com/Julian/jsonschema) + + Kwown formUI that support `draft-07` are: + - [jsonforms.io](https://jsonforms.io/) \ No newline at end of file From 0bd1176405d561e2224b08dcbd4455485de2c287 Mon Sep 17 00:00:00 2001 From: Christian Weiss Date: Tue, 10 Dec 2019 22:56:14 +0100 Subject: [PATCH 2/3] resolves #159, github workflow for QA process --- .github/workflows/main.yml | 55 +++++++++++++++++++++++++++++++++ pipeline/extractJsonSchema.sh | 26 ++++++++++++++++ pipeline/lintShellScripts.sh | 8 +++++ pipeline/validateJsonSchema.sh | 56 ++++++++++++++++++++++++++++++++++ 4 files changed, 145 insertions(+) create mode 100644 .github/workflows/main.yml create mode 100644 pipeline/extractJsonSchema.sh create mode 100644 pipeline/lintShellScripts.sh create mode 100644 pipeline/validateJsonSchema.sh diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml new file mode 100644 index 0000000..4c9da0d --- /dev/null +++ b/.github/workflows/main.yml @@ -0,0 +1,55 @@ +name: Freifunk-QA + +on: [push] + +jobs: + schemaValidation: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v1 + - name: Lint all shell scripts + run: ./pipeline/lintShellScripts.sh + - name: Extract `draft-03` schema (from "empty schema) + run: ./pipeline/extractJsonSchema.sh + env: + SOURCE_PATTERN: "./specs/*.json" + - name: Validate `draft-03` schema (extracted schema) + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/bash + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-03" + SOURCE_PATTERN: "./specs_clean/*.json" + - name: Validate `draft-03` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/bash + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-03" + SOURCE_PATTERN: "./specs/draft-03/*.json" + - name: Validate `draft-04` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/bash + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-04" + SOURCE_PATTERN: "./specs/draft-04/*.json" + - name: Validate `draft-06` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/bash + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-06" + SOURCE_PATTERN: "./specs/draft-06/*.json" + - name: Validate `draft-07` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/bash + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-07" + SOURCE_PATTERN: "./specs/draft-07/*.json" diff --git a/pipeline/extractJsonSchema.sh b/pipeline/extractJsonSchema.sh new file mode 100644 index 0000000..c7ffbf1 --- /dev/null +++ b/pipeline/extractJsonSchema.sh @@ -0,0 +1,26 @@ +#!/bin/bash + +if [ -z "$SOURCE_PATTERN" ]; then + echo "Please define SOURCE_PATTERN environment variable" + exit 1 +fi + +if [ ! -d "$(dirname "$SOURCE_PATTERN")" ]; then + echo "Directory $(dirname "$SOURCE_PATTERN") do not exists!" + exit 1 +fi + +echo "Validating schema files for pattern: $SOURCE_PATTERN" + +mkdir -p specs_clean/ + +for filename in $SOURCE_PATTERN; do + + # extract "freifunk schema" from "emtpy schema" + # shellcheck disable=SC2094 + jq '.schema' < "$filename" > "specs_clean/$(basename "$filename")" + filename="specs_clean/$(basename "$filename")" + echo "Extracted schema saved in: $filename" + +done + diff --git a/pipeline/lintShellScripts.sh b/pipeline/lintShellScripts.sh new file mode 100644 index 0000000..665b1ed --- /dev/null +++ b/pipeline/lintShellScripts.sh @@ -0,0 +1,8 @@ +#!/bin/bash +set -e + +for filename in **/*.sh; do + echo "Linted shell scripts: $filename" + shellcheck "$filename" +done + diff --git a/pipeline/validateJsonSchema.sh b/pipeline/validateJsonSchema.sh new file mode 100644 index 0000000..84d3f45 --- /dev/null +++ b/pipeline/validateJsonSchema.sh @@ -0,0 +1,56 @@ +#!/bin/bash + +if [ -z "$SOURCE_PATTERN" ]; then + echo "Please define SOURCE_PATTERN environment variable" + exit 1 +fi + +if [ ! -d "$(dirname "$SOURCE_PATTERN")" ]; then + echo "Directory $(dirname "$SOURCE_PATTERN") do not exists!" + exit 1 +fi + +echo "Validating schema files for pattern: $SOURCE_PATTERN" + +case $DRAFT in + draft-03) + VALIDATOR="Draft3Validator" + ;; + draft-04) + VALIDATOR="Draft4Validator" + ;; + draft-06) + VALIDATOR="Draft6Validator" + ;; + draft-07) + VALIDATOR="Draft7Validator" + ;; + *) + echo "Please define DRAFT environment variable. Supported values: draft-03, draft-04, draft-06, draft-07" + exit 1 + ;; +esac + +echo "Draft: $DRAFT" +echo "Validator = $VALIDATOR" + +PROBLEM=false + +mkdir -p specs_clean/ + +for filename in $SOURCE_PATTERN; do + VALIDATIONERROR="" + VALIDATIONERROR=$(jsonschema --validator $VALIDATOR "$filename" 2>&1) + EXITCODE=$? + if [ $EXITCODE -eq 0 ]; then + echo "OK $filename" + else + echo "ERROR $filename $VALIDATIONERROR" + PROBLEM=true + fi +done + +if [ $PROBLEM = true ]; then + echo "VALIDATION FAILED!" + exit 1 +fi \ No newline at end of file From 7d59bf5c562503ac7dca52368a9f8fd274528e13 Mon Sep 17 00:00:00 2001 From: Christian Weiss Date: Wed, 11 Dec 2019 00:04:33 +0100 Subject: [PATCH 3/3] Override docker entrypoint (/bin/sh) --- .github/workflows/main.yml | 100 ++++++++++++++++++++----------------- 1 file changed, 53 insertions(+), 47 deletions(-) diff --git a/.github/workflows/main.yml b/.github/workflows/main.yml index 4c9da0d..a16c9dc 100644 --- a/.github/workflows/main.yml +++ b/.github/workflows/main.yml @@ -6,50 +6,56 @@ jobs: schemaValidation: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v1 - - name: Lint all shell scripts - run: ./pipeline/lintShellScripts.sh - - name: Extract `draft-03` schema (from "empty schema) - run: ./pipeline/extractJsonSchema.sh - env: - SOURCE_PATTERN: "./specs/*.json" - - name: Validate `draft-03` schema (extracted schema) - uses: docker://freifunkhamm/jsonschema:3.2.0 - with: - entrypoint: /bin/bash - args: ./pipeline/validateJsonSchema.sh - env: - DRAFT: "draft-03" - SOURCE_PATTERN: "./specs_clean/*.json" - - name: Validate `draft-03` schema - uses: docker://freifunkhamm/jsonschema:3.2.0 - with: - entrypoint: /bin/bash - args: ./pipeline/validateJsonSchema.sh - env: - DRAFT: "draft-03" - SOURCE_PATTERN: "./specs/draft-03/*.json" - - name: Validate `draft-04` schema - uses: docker://freifunkhamm/jsonschema:3.2.0 - with: - entrypoint: /bin/bash - args: ./pipeline/validateJsonSchema.sh - env: - DRAFT: "draft-04" - SOURCE_PATTERN: "./specs/draft-04/*.json" - - name: Validate `draft-06` schema - uses: docker://freifunkhamm/jsonschema:3.2.0 - with: - entrypoint: /bin/bash - args: ./pipeline/validateJsonSchema.sh - env: - DRAFT: "draft-06" - SOURCE_PATTERN: "./specs/draft-06/*.json" - - name: Validate `draft-07` schema - uses: docker://freifunkhamm/jsonschema:3.2.0 - with: - entrypoint: /bin/bash - args: ./pipeline/validateJsonSchema.sh - env: - DRAFT: "draft-07" - SOURCE_PATTERN: "./specs/draft-07/*.json" + - uses: actions/checkout@v1 + - name: Lint all shell scripts + run: ./pipeline/lintShellScripts.sh + + - name: Extract `draft-03` schema (from "empty schema) + run: ./pipeline/extractJsonSchema.sh + env: + SOURCE_PATTERN: "./specs/*.json" + + - name: Validate `draft-03` schema (extracted schema) + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/sh + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-03" + SOURCE_PATTERN: "./specs_clean/*.json" + + - name: Validate `draft-03` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/sh + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-03" + SOURCE_PATTERN: "./specs/draft-03/*.json" + + - name: Validate `draft-04` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/sh + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-04" + SOURCE_PATTERN: "./specs/draft-04/*.json" + + - name: Validate `draft-06` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/sh + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-06" + SOURCE_PATTERN: "./specs/draft-06/*.json" + + - name: Validate `draft-07` schema + uses: docker://freifunkhamm/jsonschema:3.2.0 + with: + entrypoint: /bin/sh + args: ./pipeline/validateJsonSchema.sh + env: + DRAFT: "draft-07" + SOURCE_PATTERN: "./specs/draft-07/*.json"