Skip to content

Short example of how to use Backbone.js with Node.js. It has been made for the third workshop made at EPITECH Toulouse - 2014.

Notifications You must be signed in to change notification settings

queval-j/workshop

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Workshop 3

==========

Les APIs

Hash reçu en cas d'erreur

Hash reçu :

{
	"error": {
		"reason": "Bad ID."
	}
}

Récupérer les articles

GET - /api/articles

Hash à envoyer :

Aucun

Hash reçu :

{
	"articles": [{
		"name": "Name",
		"author": "Someone",
		"create": 1215468751,
		"content": "I'm the content of this article"
	}]
}

Ajouter un article

POST - /api/articles

Hash à envoyer :

{
	"name": "Name",
	"author": "Someone",
	"content": "I'm the content of this article"
}

Hash reçu :

{
	"ok": true
}

Modifier un article

PUT - /api/articles/:id

Hash à envoyer :

{
	"name": "Name",
	"author": "Someone",
	"content": "I'm the content of this article"
}

Hash reçu :

{
	"ok": true,
	"id": 0,
	"article": {
		"name": "Name",
		"author": "Someone",
		"create": 1215468751,
		"content": "I'm the content of this article"
	}
}

Supprimer un article

DELETE - /api/articles/:id

Hash à envoyer : Rien à envoyer

Hash reçu :

{
	"ok": true
}

About

Short example of how to use Backbone.js with Node.js. It has been made for the third workshop made at EPITECH Toulouse - 2014.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 2

  •  
  •