The python SDK developed by Voicen allows customers to use speech-to-text service of Voicen.
Project description
# Voicen Python SDK
## Documentation
This is Python SDK to use Speech-to-text service of Voicen. To see more about API visit to [API Documentation](https://voicen.com/en/api/). You are free to develop your own SDK for different languages using Voicen API documentation.
## Installation
You can install SDK direct from pip repository running this command:
pip install –upgrade voicen-python-sdk
You can also install from source code:
python setup.py install –user
### Requirements
Python 2.7+ or Python 3.4+
## Usage
Before using this SDK you must have an Access Token. To get Access Token visit to [API Token](https://voicen.com/en/user/api/) page. There is an Access Token generated for you. Use this Access Token to create your client:
`python from voicen import vcnclient # create your client voicen_client = vcnclient.VoicenClient('ACCESS_TOKEN') `
### Sending a file
Once you have set up your client with your Access Token you can send a file to transcribe. You also must specify language of speech.
`python #send a file to transcribe job = voicen_client.create_job_with_local_file('PATH_TO_FILE', 'LANGUAGE') `
### Sending media url
Once you have set up your client with your Access Token you can send a media URL to transcribe. For example you can use youtube URL as a media URL. You also must specify language of speech.
`python #send a media URL to transcribe job = voicen_client.create_job_with_media_url('MEDIA_URL', 'LANGUAGE') `
### Checking status of job
You can check status of job using its id
`python #get job details job_details = voicen_client.get_job(job.id) `
### Getting list of jobs
You can get list of jobs.
`python #get list of jobs jobs = voicen_client.get_jobs() `
`python #limit number of jobs in the list jobs = voicen_client.get_jobs(limit=50) `
`python #get jobs starting after the certain job id jobs = voicen_client.get_jobs(start_after=1203) `
### Deleting job
You can delete job using its id
`python #delete job voicen_client.delete_job(job.id) `
### Getting your transcription
You can get your transcription in these formats:
json
text
srt(SubRip Text)
Microsoft Word
`python #get your transcription as a json #returns Transcription object transcription = voicen_client.get_transcription(job.id) `
`python #get your transcription as a text #return string transcription_text = voicen_client.get_transcription_as_text(job.id) `
`python #get your transcription as a srt #returns string transcription_srt = voicen_client.get_transcription_as_srt(job.id) `
`python #get your transcription as ms word #returns byte array transcription_msword = voicen_client.get_transcription_as_msword(job.id) `
### Getting account details
You can get you account email and balance in seconds.
`python #get account account = voicen_client.get_account() `
### Getting payment details
You can get your payment details.
`python #get payment details payment = voicen_client.get_payments() `
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Filter files by name, interpreter, ABI, and platform.
If you're not sure about the file name format, learn more about wheel file names.
Copy a direct link to the current filters
File details
Details for the file voicen-1.0.3.tar.gz.
File metadata
- Download URL: voicen-1.0.3.tar.gz
- Upload date:
- Size: 8.4 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.40.2 CPython/3.6.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
d0cfdd5da2903cd4403b2fa4cc530f80e236d830633f5bddea75b89c637a31ba
|
|
| MD5 |
4dcf7f9597054c88afeaa463af779d1b
|
|
| BLAKE2b-256 |
1af9074f4c11ad6a208fcbc0e9bd7cc7fc1e0bf3d36b2441d508c133b2591d59
|
File details
Details for the file voicen-1.0.3-py3-none-any.whl.
File metadata
- Download URL: voicen-1.0.3-py3-none-any.whl
- Upload date:
- Size: 11.7 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/3.1.1 pkginfo/1.5.0.1 requests/2.21.0 setuptools/42.0.2 requests-toolbelt/0.9.1 tqdm/4.40.2 CPython/3.6.9
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
3afe42fe73d77511600a9ee9e0182b0408ce02eeb879693304405c9287d39844
|
|
| MD5 |
96c563067e4ece4571ef050a48e48c22
|
|
| BLAKE2b-256 |
460333815cb0d3155be42d9029aba3edb77944ae61a38697e9c0b691c899d6a8
|