Hit the Etherpad-lite API with Python

Introduction

When I was looking for a tool that allows multiple people to edit the minutes of a meeting at the same time, I arrived at Etherpad-lite. Since it is open source, it can be operated on an in-house server, so unlike Google Docs, there is no risk of exposing in-house information to the outside.

Reference: Introducing some memo tools that support simultaneous editing so that everyone can take notes

However, with the plain Etherpad-lite, it is not possible to refer to the list of Pads and the UI is a little rugged, so in order to operate it as it can be used, it is necessary to create a Web service that hits the API.

First of all, in order to learn the basic operation method, I decided to hit the API from Python.

How to hit the API

The wrapper for hitting the Etherpad-lite API with Python is Changaco / python-etherpad_lite .

The folder structure in this description is as follows.

root/
    etherpad-lite/
        APIKEY.txt
          :
          :
    py_api.py

With Etherpad-lite running, you can hit the API as follows.

As c.api_version = '1.2.13', you cannot execute the latest API functions published at the moment unless you explicitly specify the API version.

py_api.py


from etherpad_lite import EtherpadLiteClient

f = open('./etherpad-lite/APIKEY.txt')
apikey = f.readline()
f.close()
c = EtherpadLiteClient(base_params={'apikey': apikey})
c.api_version = '1.2.13'

#Creating a pad
c.createPad(padID='hoge')

#Get pad list
c.listAllPads()
# => {'padIDs': ['hoge']}

#Delete pad
c.deletePad(padID='hoge')

I tried to make a web service with Django

I tried to create a Web service that can create, list, and delete Pads by referring to Introduction to Python Django (1).

gkmaro634/etherminutes

image.png

Although it could not be implemented as of April 12, 2017, I would like to try expanding functions such as full-text search in Pad and user authentication.

Recommended Posts

Hit the Etherpad-lite API with Python
Call the API with python3.
Hit the Sesami API in Python
[Python] Hit the Google Translation API
Hit the web API in Python
Hit the Firebase Dynamic Links API in Python
Hit a method of a class instance with the Python Bottle Web API
Hit Mastodon's API in Python
Use Trello API with python
Use Twitter API with Python
Web API with Python + Falcon
Play RocketChat with API / Python
Use subsonic API with python3
Hit the Twitter API after Oauth authentication with Django
PHP and Python samples that hit the ChatWork API
Note calling the CUDA Driver API with Python ctypes
I moved the automatic summarization API "summpy" with python3.
I tried hitting the API with echonest's python client
Try hitting the Twitter API quickly and easily with Python
Extract the xz file with python
Create Awaitable with Python / C API
The first API to make with python Djnago REST framework
Quine Post with Qiita API (Python)
Get the weather with Python requests
Get the weather with Python requests 2
Find the Levenshtein Distance with python
Let's touch the API of Netatmo Weather Station with Python. #Python #Netatmo
Install the Python plugin with Netbeans 8.0.2
[python] Read information with Redmine API
I liked the tweet with python. ..
Use the Flickr API from Python
Master the type with Python [Python 3.9 compatible]
Hit the top command with htop
Access the Twitter API in Python
Hit ISE's ERS API with PowerShell
An easy way to hit the Amazon Product API in Python
Hit the New Relic API in Python to get the server status
How to send a request to the DMM (FANZA) API with python
Python beginners hit the unofficial API of Google Play Music to play music
Make the Python console covered with UNKO
Collecting information from Twitter with Python (Twitter API)
Access the Docker Remote API with Requests
Try using the Wunderlist API in Python
[Python] Set the graph range with matplotlib
Try using the Kraken API in Python
Behind the flyer: Using Docker with Python
Retrieving food data with Amazon API (Python)
Check the existence of the file with python
[Python] Get the variable name with str
[Python] Round up with just the operator
Display Python 3 in the browser with MAMP
Tweet using the Twitter API in Python
Search the maze with the python A * algorithm
Let's read the RINEX file with Python ①
Working with OpenStack using the Python SDK
Download files on the web with Python
[Azure] Hit Custom Vision Service with Python
[Python] Quickly create an API with Flask
Get holidays with the Google Calendar API
Learn the design pattern "Singleton" with Python
[Python] Automatically operate the browser with Selenium