GithubHelp home page GithubHelp logo

mozilla / galaxy-api-python-client Goto Github PK

View Code? Open in Web Editor NEW
1.0 11.0 4.0 8 KB

INACTIVE - http://mzl.la/ghe-archive - collection of sample Python scripts for consuming Galaxy's REST API

inactive unmaintained

galaxy-api-python-client's Introduction

galaxy-api-python-client

This is a collection of Python scripts demonstrating use of Galaxy's REST API.

Installation

If you don't already have pip installed, do that now:

sudo easy_install pip

If you do have pip installed, make sure you have an up-to-date version installed:

pip install --upgrade pip

Install the required Python packages:

pip install -r requirements.txt

Initialise the local settings:

cp examples/settings_local.py.dist examples/settings_local.py

Any setting specified here overrides the respective setting defined in settings.py.

Examples

Run everything

python examples/play_game.py

Game creation

python examples/create_game.py

User creation

python examples/create_user.py

Leaderboard creation

python examples/create_leaderboard.py

Leaderboard score creation

python examples/create_leaderboard_score.py

Example output

%% python examples/play_game.py


*******************************************************************************


Request body:

{
  "app_url": "http://www.fullscreenpokemon.com/", 
  "slug": "pokemon", 
  "description": "Full Screen Pokemon is an open source HTML5 remake of the original Pokemon games. You can play the original two generations (Red/Blue through Crystal), literally billions of procedurally generated maps, or create your own using the level editor.", 
  "name": "Pok\u00e9mon"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "slug": "pokeballs-collected", 
  "description": "This keeps track of how many pok\u00e9balls a user finds.", 
  "name": "Pok\u00e9balls Collected"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "score": 39, 
  "user": "bill"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "score": 50, 
  "user": "cvan"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "score": 72, 
  "user": "david"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "score": 84, 
  "user": "toby"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "score": 99, 
  "user": "mark"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "score": 101, 
  "user": "rick"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

{
  "score": 4, 
  "user": "wil"
}


Response status code:

200


Response body:

{
  "success": true
}


*******************************************************************************


Request body:

N/A


Response status code:

200


Response body:

[
  {
    "member": "rick", 
    "score": "101"
  }, 
  {
    "member": "mark", 
    "score": "99"
  }, 
  {
    "member": "toby", 
    "score": "84"
  }, 
  {
    "member": "david", 
    "score": "72"
  }, 
  {
    "member": "cvan", 
    "score": "50"
  }, 
  {
    "member": "bill", 
    "score": "39"
  }, 
  {
    "member": "wil", 
    "score": "4"
  }
]


*******************************************************************************


galaxy-api-python-client's People

Contributors

cvan avatar gsathya avatar mozilla-github-standards avatar

Stargazers

 avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

galaxy-api-python-client's Issues

CODE_OF_CONDUCT.md file missing

As of January 1 2019, Mozilla requires that all GitHub projects include this CODE_OF_CONDUCT.md file in the project root. The file has two parts:

  1. Required Text - All text under the headings Community Participation Guidelines and How to Report, are required, and should not be altered.
  2. Optional Text - The Project Specific Etiquette heading provides a space to speak more specifically about ways people can work effectively and inclusively together. Some examples of those can be found on the Firefox Debugger project, and Common Voice. (The optional part is commented out in the raw template file, and will not be visible until you modify and uncomment that part.)

If you have any questions about this file, or Code of Conduct policies and procedures, please see Mozilla-GitHub-Standards or email [email protected].

(Message COC001)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.