Skip to main content

Moodle Webservice API

Project description

poodle_async_mini

Auto-generated OpenAPI spec for Moodle's Webservice API.

This Python package is automatically generated by the OpenAPI Generator project:

  • API version: 4.5.6 (Build: 20250811)
  • Package version: 4.5.6.post1
  • Generator version: 7.15.0
  • Build package: org.openapitools.codegen.languages.PythonClientCodegen

Requirements.

Python 3.9+

Installation & Usage

pip install

If the python package is hosted on a repository, you can install directly using:

pip install git+https://github.com/bchmnn/poodle.git

(you may need to run pip with root permission: sudo pip install git+https://github.com/bchmnn/poodle.git)

Then import the package:

import poodle_async_mini

Setuptools

Install via Setuptools.

python setup.py install --user

(or sudo python setup.py install to install the package for all users)

Then import the package:

import poodle_async_mini

Tests

Execute pytest to run the tests.

Getting Started

Please follow the installation procedure and then run the following:

import poodle_async_mini
from poodle_async_mini.rest import ApiException
from pprint import pprint

# Defining the host is optional and defaults to https://localhost
# See configuration.py for a list of all supported configuration parameters.
configuration = poodle_async_mini.Configuration(
    host = "https://localhost"
)

# The client must configure the authentication and authorization parameters
# in accordance with the API server security policy.
# Examples for each auth method are provided below, use the example that
# satisfies your auth use case.

# Configure API key authorization: wstoken
configuration.api_key['wstoken'] = os.environ["API_KEY"]

# Uncomment below to setup prefix (e.g. Bearer) for API key, if needed
# configuration.api_key_prefix['wstoken'] = 'Bearer'


# Enter a context with an instance of the API client
async with poodle_async_mini.ApiClient(configuration) as api_client:
    # Create an instance of the API class
    api_instance = poodle_async_mini.DefaultApi(api_client)
    courseid = 56 # int | course id
    options = [poodle_async_mini.CoreCourseGetContentsParametersOptionsInner()] # List[CoreCourseGetContentsParametersOptionsInner] | Options, used since Moodle 2.9 (optional)

    try:
        # Get course contents
        api_response = await api_instance.core_course_get_contents(courseid, options=options)
        print("The response of DefaultApi->core_course_get_contents:\n")
        pprint(api_response)
    except ApiException as e:
        print("Exception when calling DefaultApi->core_course_get_contents: %s\n" % e)

Documentation for API Endpoints

All URIs are relative to https://localhost

Class Method HTTP request Description
DefaultApi core_course_get_contents POST /webservice/rest/server.php#core_course_get_contents Get course contents
DefaultApi core_enrol_get_users_courses POST /webservice/rest/server.php#core_enrol_get_users_courses Get the list of courses where a user is enrolled in
DefaultApi core_group_get_course_groups POST /webservice/rest/server.php#core_group_get_course_groups Returns all groups in specified course.
DefaultApi core_webservice_get_site_info POST /webservice/rest/server.php#core_webservice_get_site_info Return some site info / user info / list web service functions
DefaultApi gradereport_user_get_grade_items POST /webservice/rest/server.php#gradereport_user_get_grade_items Returns the complete list of grade items for users in a course
DefaultApi login_token POST /login/token.php
DefaultApi mod_assign_get_assignments POST /webservice/rest/server.php#mod_assign_get_assignments Returns the courses and assignments for the users capability
DefaultApi mod_assign_get_submissions POST /webservice/rest/server.php#mod_assign_get_submissions Returns the submissions for assignments
DefaultApi mod_assign_list_participants POST /webservice/rest/server.php#mod_assign_list_participants List the participants for a single assignment, with some summary info about their submissions.
DefaultApi tool_mobile_get_public_config GET /lib/ajax/service-nologin.php#tool_mobile_get_public_config Returns a list of the site public settings, those not requiring authentication.

Documentation For Models

Documentation For Authorization

Authentication schemes defined for the API:

wstoken

  • Type: API key
  • API key parameter name: wstoken
  • Location: URL query string

Author

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

poodle_async_mini-4.5.6.post1.tar.gz (58.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

poodle_async_mini-4.5.6.post1-py3-none-any.whl (120.0 kB view details)

Uploaded Python 3

File details

Details for the file poodle_async_mini-4.5.6.post1.tar.gz.

File metadata

  • Download URL: poodle_async_mini-4.5.6.post1.tar.gz
  • Upload date:
  • Size: 58.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.13

File hashes

Hashes for poodle_async_mini-4.5.6.post1.tar.gz
Algorithm Hash digest
SHA256 d5a122a6c55e10b07dfeaf3e15d93582c87efa223d1afc95cc41a826a2098ecb
MD5 b7f89e11916ca1a515f61db6fd1ff00d
BLAKE2b-256 50381c6e5f852298c6beb4136059fdf62c6f7749284b6cc8181c767154aa3cc3

See more details on using hashes here.

File details

Details for the file poodle_async_mini-4.5.6.post1-py3-none-any.whl.

File metadata

File hashes

Hashes for poodle_async_mini-4.5.6.post1-py3-none-any.whl
Algorithm Hash digest
SHA256 2e7ff279ce39755b5b0a4c60c3eff43625c0528ac6c3c44395b141607513105d
MD5 15a0c5c4ca08f1bb0a563112de3fde06
BLAKE2b-256 ff8bafca29d28abf633c9bb0674227b105bf7b5bcafbaadaeb9ae5eef94fa227

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page