<commit_before># README #

This library implements a client for the REST API of the virtualskeletondatabase (www.virtualskeleton.ch). It supports authentication, general queries, and specific requests such as image upload/download, object linking and right management. Examples are provided in the examples directory. Please use 'demo.virtualskeleton.ch' for testing purposes.

## What is in this Fork
- Pyhton 3 (3.4.3)
- usage of **requests** package instead of urllib2
- usage of **pathlib** instead of os.path
- usage of **PyJWT** for jwt.io authentication [PyJWT](https://github.com/jpadilla/pyjwt)
- support file poster.py removed (no needed with requests)
- introduction of API classes

## Recent updates
- Added SAML auth 
- Added chunk Upload (upload files > 500 MB) 
- Added JWT auth

### What is this repository for? ###

* Quick summary: connect to vsd
* Version: 0.2

### How do I get set up? ###
1. install dependencies    
    
    pip install requests
    pip install PyJWT

2. get the code and 
3. Just add the source directory to your PYTHONPATH

### Contribution guidelines ###

* Write exception handling
* Writing tests
* Code review
* Adding sockets/timeouts/retries
* Adding more stable support for pagination
* Add general file upload
* Write some sort of GUI example

### Who do I talk to? ###

* Repo owner or admin
* Other community or team contact

## Get Started

import connectVSD

api = connectVSD.connectVSD()
obj = api.getObject(21)
print(obj.selfUrl, obj.name)


<commit_msg>added remark about folders<commit_after># README #

This library implements a client for the REST API of the virtualskeletondatabase (www.virtualskeleton.ch). It supports authentication, general queries, and specific requests such as image upload/download, object linking and right management. Examples are provided in the examples directory. Please use 'demo.virtualskeleton.ch' for testing purposes.

## What is in this Fork
- Pyhton 3 (3.4.3)
- usage of **requests** package instead of urllib2
- usage of **pathlib** instead of os.path
- usage of **PyJWT** for jwt.io authentication [PyJWT](https://github.com/jpadilla/pyjwt)
- support file poster.py removed (no needed with requests)
- introduction of API classes

## Recent updates
- Added SAML auth 
- Added chunk Upload (upload files > 500 MB) 
- Added JWT auth

### What is this repository for? ###

* Quick summary: connect to vsd
* Version: 0.2

### How do I get set up? ###
1. install dependencies    
    
    pip install requests
    pip install PyJWT

2. get the code and 
3. Just add the source directory to your PYTHONPATH

### Contribution guidelines ###

* Write exception handling
* Writing tests
* Code review
* Adding sockets/timeouts/retries
* Adding more stable support for pagination
* Add general file upload
* Write some sort of GUI example

### Who do I talk to? ###

* Repo owner or admin
* Other community or team contact

## Problems
* The server response is very slow if you have 50+ folders. VSD-connect makes a request to the server for each folder. Therefore, I will be slow if you have a lot of folders and use the folder methods. You should then use the getRequest function and create your APIFolder object locally.

## Get Started

import connectVSD

api = connectVSD.connectVSD()
obj = api.getObject(21)
print(obj.selfUrl, obj.name)



{'fraction_non_alphanumeric': 0.08043217286914765, 'fraction_numerical': 0.009603841536614645, 'mean_word_length': 4.004504504504505, 'pattern_counts': {'":': 0, '<': 3, '<?xml version=': 0, '>': 5, 'https://': 2, 'lorem ipsum': 0, 'www.': 2, 'xml': 0}, 'pii_count': 0, 'substrings_counts': 0, 'word_list_counts': {'cursed_substrings.json': 2, 'profanity_word_list.json': 0, 'sexual_word_list.json': 0, 'zh_pornsignals.json': 0}}
{'dir': 'git-commits-cleaned', 'id': '3761134', 'n_tokens_mistral': 973, 'n_tokens_neox': 937, 'n_words': 439}