Skip to content

Change an enrolment method

Fields absent from the body are left as they are.

Quire permissions

Required capability: enrol/configure_method.

Credential scopes: enrolments:write.

The acting subject must also be allowed to perform this action in the organisation.

PATCH
https://your-organisation.quirelms.com/api/v1/enrolment_methods/{id}

Authorisation

  • apiKeyoptionalHTTP
  • oauth2optionalOAuth 2.0

Path parameters

  • idstringrequired

Header parameters

  • Quire-Versionoptionalstring

    The dated API revision to serve this request at. Omitted, the request is served at the revision the credential was issued against. The response echoes the revision actually applied.

    format: date
  • Idempotency-Keyoptionalstring

    A caller-chosen key making this request safe to retry. A replay of a completed request returns the recorded response with Idempotency-Replayed: true. Reusing a key for a different request is refused.

    maxLength: 255

Request bodyJSONrequired

  • nameoptionalstringornull
    2 variants

    One of the following:

    • string
    • null
  • default_role_idoptionalstring

    A course role other than the method default.

    format: uuid, pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
  • enrol_start_atoptionalstringornull
    2 variants

    One of the following:

    • string
    • null
  • enrol_end_atoptionalstringornull
    2 variants

    One of the following:

    • string
    • null
  • enrol_period_daysoptionalintegerornull
    2 variants

    One of the following:

    • integer
    • null
  • max_enrolledoptionalintegerornull
    2 variants

    One of the following:

    • integer
    • null
  • on_source_removaloptionalsuspendorsuspend_and_unassignorunenrol
  • enrolment_keyoptionalstringornull

    Self enrolment: a new key, or null to remove it. Write-only: it is never returned.

    2 variants

    One of the following:

    • string
    • null
  • group_keysoptionalarray ofobject

    Self enrolment: a key per group. Write-only: never returned.

    2 properties
    • group_idstringrequired
      format: uuid, pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
    • keystringrequired
      maxLength: 200, minLength: 4
  • guest_passwordoptionalstringornull

    Guest access: a new password, or null to remove it. Write-only: never returned.

    2 variants

    One of the following:

    • string
    • null
  • allow_forum_readoptionalboolean
  • source_keyoptionalstring

    The cohort, course or category a source-following method follows.

    maxLength: 500
  • source_role_idoptionalstringornull
    2 variants

    One of the following:

    • string
    • null
  • include_subcategoriesoptionalboolean
  • approval_role_idoptionalstringornull
    2 variants

    One of the following:

    • string
    • null
  • approval_expiry_daysoptionalinteger
    maximum: 365, minimum: 1
  • capacityoptionalinteger
    maximum: 9007199254740991, minimum: 1
  • seat_pool_idoptionalstring
    format: uuid, pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
  • price_idoptionalstring
    format: uuid, pattern: ^([0-9a-fA-F]{8}-[0-9a-fA-F]{4}-[1-8][0-9a-fA-F]{3}-[89abAB][0-9a-fA-F]{3}-[0-9a-fA-F]{12}|00000000-0000-0000-0000-000000000000|ffffffff-ffff-ffff-ffff-ffffffffffff)$
  • externaloptionalmap ofstring

    Settings of an externally fed method. Write-only.

Returns

200

Success.

JSON
  • idstringrequired
  • external_idstring | nullrequired
  • course_idstringrequired
  • kindstringrequired
  • namestring | nullrequired
  • enabledbooleanrequired
  • sort_orderintegerrequired
    maximum: 9007199254740991, minimum: -9007199254740991
  • default_role_idstringrequired
  • enrol_start_atstringornullrequired
    2 variants

    One of the following:

    • string
    • null
  • enrol_end_atstringornullrequired
    2 variants

    One of the following:

    • string
    • null
  • max_enrolledintegerornullrequired
    2 variants

    One of the following:

    • integer
    • null
  • created_atstringrequired

    RFC 3339 timestamp in UTC.

  • updated_atstringrequired

    RFC 3339 timestamp in UTC.

  • deleted_atstringornullrequired
    2 variants

    One of the following:

    • string
    • null

401

The credential is missing, malformed, expired or revoked.

JSON
  • typestringrequired
    format: uri
  • titlestringrequired
  • statusintegerrequired
  • codestringrequired
  • categoryvalidationorauthenticationorauthorizationornot_foundorconflictorprecondition+4 morerequired
  • detailstringrequired
  • request_idstringrequired
  • docs_urlstringrequired
    format: uri
  • errorsoptionalarray ofobject
    3 properties
    • pathstringrequired

      RFC 6901 JSON Pointer into the request body.

    • codestringrequired
    • detailstringrequired
  • retry_afteroptionalinteger | null

403

The credential lacks the scope this operation requires, or the acting subject lacks the capability.

JSON
  • typestringrequired
    format: uri
  • titlestringrequired
  • statusintegerrequired
  • codestringrequired
  • categoryvalidationorauthenticationorauthorizationornot_foundorconflictorprecondition+4 morerequired
  • detailstringrequired
  • request_idstringrequired
  • docs_urlstringrequired
    format: uri
  • errorsoptionalarray ofobject
    3 properties
    • pathstringrequired

      RFC 6901 JSON Pointer into the request body.

    • codestringrequired
    • detailstringrequired
  • retry_afteroptionalinteger | null

404

No such resource, or none this credential is permitted to know about.

JSON
  • typestringrequired
    format: uri
  • titlestringrequired
  • statusintegerrequired
  • codestringrequired
  • categoryvalidationorauthenticationorauthorizationornot_foundorconflictorprecondition+4 morerequired
  • detailstringrequired
  • request_idstringrequired
  • docs_urlstringrequired
    format: uri
  • errorsoptionalarray ofobject
    3 properties
    • pathstringrequired

      RFC 6901 JSON Pointer into the request body.

    • codestringrequired
    • detailstringrequired
  • retry_afteroptionalinteger | null

409

The request conflicts with the current state, with a previous use of the same idempotency key, or with a concurrent write.

JSON
  • typestringrequired
    format: uri
  • titlestringrequired
  • statusintegerrequired
  • codestringrequired
  • categoryvalidationorauthenticationorauthorizationornot_foundorconflictorprecondition+4 morerequired
  • detailstringrequired
  • request_idstringrequired
  • docs_urlstringrequired
    format: uri
  • errorsoptionalarray ofobject
    3 properties
    • pathstringrequired

      RFC 6901 JSON Pointer into the request body.

    • codestringrequired
    • detailstringrequired
  • retry_afteroptionalinteger | null

422

The request was understood and its content is not valid. errors names each field.

JSON
  • typestringrequired
    format: uri
  • titlestringrequired
  • statusintegerrequired
  • codestringrequired
  • categoryvalidationorauthenticationorauthorizationornot_foundorconflictorprecondition+4 morerequired
  • detailstringrequired
  • request_idstringrequired
  • docs_urlstringrequired
    format: uri
  • errorsoptionalarray ofobject
    3 properties
    • pathstringrequired

      RFC 6901 JSON Pointer into the request body.

    • codestringrequired
    • detailstringrequired
  • retry_afteroptionalinteger | null

429

A rate limit or a concurrency cap was reached. Retry-After says when to try again.

JSON
  • typestringrequired
    format: uri
  • titlestringrequired
  • statusintegerrequired
  • codestringrequired
  • categoryvalidationorauthenticationorauthorizationornot_foundorconflictorprecondition+4 morerequired
  • detailstringrequired
  • request_idstringrequired
  • docs_urlstringrequired
    format: uri
  • errorsoptionalarray ofobject
    3 properties
    • pathstringrequired

      RFC 6901 JSON Pointer into the request body.

    • codestringrequired
    • detailstringrequired
  • retry_afteroptionalinteger | null

500

Something failed at our end. Quote request_id when reporting it.

JSON
  • typestringrequired
    format: uri
  • titlestringrequired
  • statusintegerrequired
  • codestringrequired
  • categoryvalidationorauthenticationorauthorizationornot_foundorconflictorprecondition+4 morerequired
  • detailstringrequired
  • request_idstringrequired
  • docs_urlstringrequired
    format: uri
  • errorsoptionalarray ofobject
    3 properties
    • pathstringrequired

      RFC 6901 JSON Pointer into the request body.

    • codestringrequired
    • detailstringrequired
  • retry_afteroptionalinteger | null
Navigation

Type to search…

↑↓ navigate↵ selectEsc close