Giter Site home page Giter Site logo

funpdbe-client's Introduction

FunPDBe Deposition Client

Build Status codecov Maintainability

The client can be used to connect to the FunPDBe deposition system API, and perform GET, POST, PUT and DELETE calls. With the exception of GET calls, all other calls require user authentication.

For more information on the FunPDBe initiative, visit https://funpdbe.org

Quick start

These instructions will get you a copy of the project up and running on your local machine for development and testing purposes.

Prerequisites

There are no prerequisites for installing the client, but in order to connect to the FunPDBe deposition system using this client, depositors have to register an account at https://funpdbe.org/register. Activating user accounts in dependent on admin approval.

Installing

The are two main approaches to getting the client up and running.

Checking out this repository

$ git clone https://github.com/funpdbe-consortium/funpdbe-client
$ cd funpdbe-client
$ pip install -r requirements.txt

Installing using PIP

$ pip install funpdbe_client

Usage

Examples of usage:

$ funpdbe_client.py --help

Parameters

  • -h, --help: Help (this is what you see now)
  • -u, --user: FunPDBe user name
  • -p, --pwd: FunPDBe password
  • -m, --mode: Running mode (get, post, delete, put)
  • -i, --pdbid: PDB id of an entry
  • -r, --resource: Name of a resource
  • -f, --path: Path to JSON file (.json ending), or files (folder name)
  • -d, --debug: Enable more detailed logging

Examples

Listing all entries

$ funpdbe_client.py -user=username -pwd=password --mode=get

Listing entries for PDB id 1abc

$ funpdbe_client.py -user=username -pwd=password --mode=get --pdb_id=1abc

Listing entries from funsites

$ funpdbe_client.py -user=username -pwd=password --mode=get --resource=funsites

Listing entry for PDB id 1abc from funsites

$ funpdbe_client.py -user=username -pwd=password --mode=get --pdb_id=1abc --resource=funsites

Posting an entry to funsites

$ funpdbe_client.py -user=username -pwd=password --mode=post --path=path/to/data.json --resource=funsites

Deleting an entry (1abc) from funsites

$ funpdbe_client.py -user=username -pwd=password --mode=delete --pdb_id=1abc --resource=funsites

Updating an entry (1abc) from funsites

$ funpdbe_client.py -user=username -pwd=password --mode=put --path=path/to/data.json --resource=funsites --pdb_id=1abc

Running the tests

Running tests for the client is performed simply by using

$ pytest

Versioning

We use SemVer for versioning. For the versions available, see the tags on this repository.

Authors

  • Mihaly Varadi - Initial work - mvaradi

See also the list of contributors who participated in this project.

License

This project is licensed under the EMBL-EBI License - see the LICENSE file for details

Acknowledgments

We would like to thank the PDBe team for their support and feedback, as well as all the members of the FunPDBe consortium:

funpdbe-client's People

Watchers

James Cloos avatar

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.