Coder Social home page Coder Social logo

python-syncope's Introduction

Work in progress

Documentation Status Documentation Status

####Table of Contents

  1. Overview
  2. Requirements
  3. Syncope Version
  4. Installing this role
  5. Some Examples
  6. Documentation
  7. License

#Overview

python-syncope is an python wrapper around the Syncope Rest API. At the moment, only some user specific actions can be executed against an Syncope instance. Also basic python tests are missing and not all documentation is created.

#Requirements

  • requests

#Syncope Versions

At the moment, the python-syncope will only work on the Syncope 1.1.x releases. Goal is that it will support 1.2 too.

Python syncope 1.1 syncope 1.2
2.7 โœ… โŒ

#Installation

pip install python-syncope

#Small example

How to use syncope:

import syncope
syn = syncope.Syncope(syncope_url="http://192.168.10.13:9080", username="admin", password="password")

print syn.suspend_user_by_name("puccini")
print syn.reactivate_user_by_name("puccini")
print syn.reactivate_user_by_name("puccini")

Output:

{u'status': u'suspended', u'username': u'puccini', u'creationDate': 1287572400000, u'derivedAttributes': [], u'failedLogins': 0, u'tokenExpireTime': None, u'memberships': [{u'derivedAttributes': [], u'roleName': u'artDirector', u'virtualAttributes': [], u'resources': [], u'roleId': 14, u'attributes': [], u'id': 7, u'propagationStatusTOs': []}], u'token': None, u'virtualAttributes': [], u'resources': [], u'lastLoginDate': None, u'changePwdDate': None, u'attributes': [{u'readonly': False, u'values': [u'Giacomo'], u'schema': u'firstname'}, {u'readonly': False, u'values': [u'Puccini'], u'schema': u'surname'}, {u'readonly': False, u'values': [u'Giacomo Puccini'], u'schema': u'fullname'}, {u'readonly': False, u'values': [u'[email protected]'], u'schema': u'userId'}], u'password': u'5baa61e4c9b93f3f0682250b6cf8331b7ee68fd8', u'id': 5, u'propagationStatusTOs': []}
{u'status': u'active', u'username': u'puccini', u'creationDate': 1287572400000, u'derivedAttributes': [], u'failedLogins': 0, u'tokenExpireTime': None, u'memberships': [{u'derivedAttributes': [], u'roleName': u'artDirector', u'virtualAttributes': [], u'resources': [], u'roleId': 14, u'attributes': [], u'id': 7, u'propagationStatusTOs': []}], u'token': None, u'virtualAttributes': [], u'resources': [], u'lastLoginDate': None, u'changePwdDate': None, u'attributes': [{u'readonly': False, u'values': [u'Giacomo'], u'schema': u'firstname'}, {u'readonly': False, u'values': [u'Puccini'], u'schema': u'surname'}, {u'readonly': False, u'values': [u'Giacomo Puccini'], u'schema': u'fullname'}, {u'readonly': False, u'values': [u'[email protected]'], u'schema': u'userId'}], u'password': u'5baa61e4c9b93f3f0682250b6cf8331b7ee68fd8', u'id': 5, u'propagationStatusTOs': []}
False

#Documentation

Documentation can be found at readthedocs

#License

python-syncope is licensed under the Apache License 2.0. Check the LICENSE file.

python-syncope'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.