Skip to content

madkumamon/DataVault

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

7 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

+ Test project DataVault

1.Unzip project:

~$ unzip DataVault.zip -d destination_folder

2.Enter projec folder:

~$ cd ../DataVault

3.Use .rvmrc:

Do you wish to trust this .rvmrc file? (/home/sedzen/work/ruby-blog/.rvmrc)
y[es], n[o], v[iew], c[ancel]> y

4.Install gems:

gem install bundler
bundle install

5.Install Postgresql:

http://blog.lot24media.co.za/2012/11/14/how-to-install-postgresql-9-1-on-ubuntu-12-10-linux/

6.Configure database.yml:

rename database.yml.example to database.yml
change username and password.

7.Create database:

rake db:create:all
rake db:setup

8.Run server:

rails s
"-p other port" for change port.

9.Enter the site :

In your browser go to "http://localhost:3000/"
Sign up or Sign in.
Create Application with unique access_token.

10.Test with HTTPRequestor plug-in in Firefox:

GET data from the site:
  url: "http://localhost:3000/api/v1/stored_data?access_token=APPLICATION_ACCESS_TOKEN"
POST data to the site:
  url: "http://localhost:3000/api/v1/stored_data?access_token=APPLICATION_ACCESS_TOKEN&stored_datum%5Bkey%5D=admin&stored_datum%5Bvalue%5D=admin%40mail.com"

use "rails c" for generating params for POST request:
  1.9.3p327 :008 > [{"stored_datum"=>{"key"=>"admin", "value"=>"[email protected]"}}].to_param
   => "stored_datum%5Bkey%5D=admin&stored_datum%5Bvalue%5D=admin%40mail.com"
make url:
   url: "http://localhost:3000/api/v1/stored_data?access_token=APPLICATION_ACCESS_TOKEN" + "&stored_datum%5Bkey%5D=admin&stored_datum%5Bvalue%5D=admin%40mail.com"
  1. Your opportunities:

Sign_up or Sign_in with unique email and password.
Add Application and see list of all yours applications.
See the data collected for each application.

Using curl or HTTPRequestor you can take or create all data for application using access_token.

About

Test application.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published