foliolib.folio.api.notes.Notes
- class foliolib.folio.api.notes.Notes(tenant: str)
Bases:
foliolib.folio.FolioApiNotes API
Base class of the Folio API
- Parameters
tenant (str) – Tenant id
Methods
createnote(note)Create a new note.
createnotetype(noteType)Create a new note type.
deletenote(id_)Delete note with given ID
deletenotetype(id_)Delete note type with given ID
getnote(id_)Retrieve note with given ID
getnotecollection(**kwargs)Return a list of notes
getnotecollectionbylink(domain, objectType, ...)Return a list of notes by status.
getnotetype(id_)Retrieve note type with given ID
getnotetypecollection(**kwargs)Return a list of note types
updatelinks(noteLinkUpdateCollection, ...)Add or delete links to specified list of notes
updatenote(note, id_)Update note with given ID
updatenotetype(noteType, id_)Update note type with given ID
- createnote(note)
Create a new note.
POST /notes- Parameters
note (dict) – See Schema below.
- Returns
See Schema below.
- Return type
dict
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestUnprocessableEntity – Validation errors
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "description": "Notes about all kind of objects", "properties": { "id": { "type": "string", "format": "uuid" }, "typeId": { "type": "string", "format": "uuid" }, "type": { "type": "string", "description": "Type of note (configured in settings)" }, "title": { "type": "string", "description": "Note title" }, "domain": { "type": "string", "description": "Domain associated with this note" }, "content": { "type": "string", "description": "Content of the note" }, "popUpOnCheckOut": { "type": "boolean", "description": "Flag that specify need of pop-up on check-out app" }, "popUpOnUser": { "type": "boolean", "description": "Flag that specify need of pop-up on users app" }, "links": { "type": "array", "description": "Collection of links to associated objects", "items": { "type": "object", "title": "Note link", "description": "Link to object associated with a note", "properties": { "id": { "type": "string", "description": "Id of object linked to note" }, "type": { "type": "string", "description": "Type of object linked to note" } }, "required": [ "id", "type" ], "example": { "id": "1234-5678", "type": "package" } } }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "typeId", "domain", "title" ] }
- createnotetype(noteType)
Create a new note type.
POST /note-types- Parameters
noteType (dict) – See Schema below.
- Returns
See Schema below.
- Return type
dict
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestUnprocessableEntity – Validation errors
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "title": "Note Type", "description": "Defines type of note", "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string", "description": "The unique name of this type", "maxLength": 255 }, "usage": { "type": "object", "readOnly": true, "description": "Type usage statistics", "properties": { "isAssigned": { "type": "boolean", "readOnly": true, "description": "Is this note type assigned to any note" } }, "required": [ "noteTotal" ] }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "name" ], "example": { "id": "118dbd8c-5ba0-47a9-a850-34bbb1dbf3b7", "name": "Important Note" } }
- deletenote(id_)
Delete note with given ID
DELETE /notes/{id}- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestNotFound – Resource with a given ID not found
OkapiRequestFatalError – Unexpected error
- deletenotetype(id_)
Delete note type with given ID
DELETE /note-types/{id}- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestNotFound – Resource with a given ID not found
OkapiRequestFatalError – Unexpected error
- getnote(id_)
Retrieve note with given ID
GET /notes/{id}- Returns
See Schema below.
- Return type
dict
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestNotFound – Resource with a given ID not found
OkapiRequestUnprocessableEntity – Validation errors
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "description": "Notes about all kind of objects", "properties": { "id": { "type": "string", "format": "uuid" }, "typeId": { "type": "string", "format": "uuid" }, "type": { "type": "string", "description": "Type of note (configured in settings)" }, "title": { "type": "string", "description": "Note title" }, "domain": { "type": "string", "description": "Domain associated with this note" }, "content": { "type": "string", "description": "Content of the note" }, "popUpOnCheckOut": { "type": "boolean", "description": "Flag that specify need of pop-up on check-out app" }, "popUpOnUser": { "type": "boolean", "description": "Flag that specify need of pop-up on users app" }, "links": { "type": "array", "description": "Collection of links to associated objects", "items": { "type": "object", "title": "Note link", "description": "Link to object associated with a note", "properties": { "id": { "type": "string", "description": "Id of object linked to note" }, "type": { "type": "string", "description": "Type of object linked to note" } }, "required": [ "id", "type" ], "example": { "id": "1234-5678", "type": "package" } } }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "typeId", "domain", "title" ] }
- getnotecollection(**kwargs)
Return a list of notes
GET /notes- Keyword Arguments
query (str) – A query expressed as a CQL string, for details see [Notes API](https://github.com/folio-org/mod-notes/blob/master/docs/api-guide.md#notes-api) (default: cql.allRecords=1)
offset (int) – Skip over a number of elements by specifying an offset value for the query (default: 0, minimum: 0, maximum: 2147483647)
limit (int) – Limit the number of elements returned in the response (default: 1000, minimum: 1, maximum: 2147483647)
- Returns
See Schema below.
- Return type
dict
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestUnprocessableEntity – Validation errors
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "title": "Collection of notes", "description": "Collection of notes", "properties": { "notes": { "type": "array", "items": { "type": "object", "description": "Notes about all kind of objects", "properties": { "id": { "type": "string", "format": "uuid" }, "typeId": { "type": "string", "format": "uuid" }, "type": { "type": "string", "description": "Type of note (configured in settings)" }, "title": { "type": "string", "description": "Note title" }, "domain": { "type": "string", "description": "Domain associated with this note" }, "content": { "type": "string", "description": "Content of the note" }, "popUpOnCheckOut": { "type": "boolean", "description": "Flag that specify need of pop-up on check-out app" }, "popUpOnUser": { "type": "boolean", "description": "Flag that specify need of pop-up on users app" }, "links": { "type": "array", "description": "Collection of links to associated objects", "items": { "type": "object", "title": "Note link", "description": "Link to object associated with a note", "properties": { "id": { "type": "string", "description": "Id of object linked to note" }, "type": { "type": "string", "description": "Type of object linked to note" } }, "required": [ "id", "type" ], "example": { "id": "1234-5678", "type": "package" } } }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "typeId", "domain", "title" ] } }, "totalRecords": { "type": "integer", "readOnly": true, "description": "Total amount of notes" } }, "required": [ "notes" ] }
- getnotecollectionbylink(domain, objectType, objectId, **kwargs)
Return a list of notes by status. A maximum of 1000 notes can be returned per request.
GET /note-links/domain/{domain}/type/{objectType}/id/{objectId}- Keyword Arguments
search (str) – Partial match case-insensitive search term for note title and note content
noteType (list) – Search string for note type. Note(s) is returned only if it equals to specified word or sequence of words in the titleseparated by com type name. Multiple types should be declared with query parameter sequentially as follows “noteType=a¬eType=b”. (items: (type: string))
status (str) –
orderBy (str) –
order (str) –
offset (int) – Skip over a number of elements by specifying an offset value for the query (default: 0, minimum: 0, maximum: 2147483647)
limit (int) – Limit the number of elements returned in the response (default: 1000, minimum: 1, maximum: 2147483647)
- Returns
See Schema below.
- Return type
dict
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestUnprocessableEntity – Validation errors
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "title": "Collection of notes", "description": "Collection of notes", "properties": { "notes": { "type": "array", "items": { "type": "object", "description": "Notes about all kind of objects", "properties": { "id": { "type": "string", "format": "uuid" }, "typeId": { "type": "string", "format": "uuid" }, "type": { "type": "string", "description": "Type of note (configured in settings)" }, "title": { "type": "string", "description": "Note title" }, "domain": { "type": "string", "description": "Domain associated with this note" }, "content": { "type": "string", "description": "Content of the note" }, "popUpOnCheckOut": { "type": "boolean", "description": "Flag that specify need of pop-up on check-out app" }, "popUpOnUser": { "type": "boolean", "description": "Flag that specify need of pop-up on users app" }, "links": { "type": "array", "description": "Collection of links to associated objects", "items": { "type": "object", "title": "Note link", "description": "Link to object associated with a note", "properties": { "id": { "type": "string", "description": "Id of object linked to note" }, "type": { "type": "string", "description": "Type of object linked to note" } }, "required": [ "id", "type" ], "example": { "id": "1234-5678", "type": "package" } } }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "typeId", "domain", "title" ] } }, "totalRecords": { "type": "integer", "readOnly": true, "description": "Total amount of notes" } }, "required": [ "notes" ] }
- getnotetype(id_)
Retrieve note type with given ID
GET /note-types/{id}- Returns
See Schema below.
- Return type
dict
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestNotFound – Resource with a given ID not found
OkapiRequestUnprocessableEntity – Validation errors
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "title": "Note Type", "description": "Defines type of note", "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string", "description": "The unique name of this type", "maxLength": 255 }, "usage": { "type": "object", "readOnly": true, "description": "Type usage statistics", "properties": { "isAssigned": { "type": "boolean", "readOnly": true, "description": "Is this note type assigned to any note" } }, "required": [ "noteTotal" ] }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "name" ], "example": { "id": "118dbd8c-5ba0-47a9-a850-34bbb1dbf3b7", "name": "Important Note" } }
- getnotetypecollection(**kwargs)
Return a list of note types
GET /note-types- Keyword Arguments
query (str) – A query expressed as a CQL string, for details see [Note Types API](https://github.com/folio-org/mod-notes/blob/master/docs/api-guide.md#note-types-api) (default: cql.allRecords=1)
offset (int) – Skip over a number of elements by specifying an offset value for the query (default: 0, minimum: 0, maximum: 2147483647)
limit (int) – Limit the number of elements returned in the response (default: 1000, minimum: 1, maximum: 2147483647)
- Returns
See Schema below.
- Return type
dict
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestUnprocessableEntity – Validation errors
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "title": "Collection of note types", "description": "Collection of note types", "properties": { "noteTypes": { "type": "array", "items": { "type": "object", "title": "Note Type", "description": "Defines type of note", "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string", "description": "The unique name of this type", "maxLength": 255 }, "usage": { "type": "object", "readOnly": true, "description": "Type usage statistics", "properties": { "isAssigned": { "type": "boolean", "readOnly": true, "description": "Is this note type assigned to any note" } }, "required": [ "noteTotal" ] }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "name" ], "example": { "id": "118dbd8c-5ba0-47a9-a850-34bbb1dbf3b7", "name": "Important Note" } } }, "totalRecords": { "type": "integer", "readOnly": true, "description": "Total amount of note types" } }, "required": [ "noteTypes" ], "example": { "noteTypes": [ { "id": "118dbd8c-5ba0-47a9-a850-34bbb1dbf3b7", "name": "Important Note" }, { "id": "46669e09-8b45-4ede-afbd-ca73bb89cdb3", "label": "Urgent Note" } ], "totalRecords": 2 } }
- updatelinks(noteLinkUpdateCollection, objectType, objectId)
Add or delete links to specified list of notes
PUT /note-links/type/{objectType}/id/{objectId}- Parameters
noteLinkUpdateCollection (dict) – See Schema below.
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestNotFound – Resource with a given ID not found
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "description": "Collection of note links", "properties": { "notes": { "type": "array", "items": { "type": "object", "description": "A note link", "properties": { "id": { "type": "string", "format": "uuid" }, "status": { "type": "string", "enum": [ "ASSIGNED", "UNASSIGNED" ] } }, "required": [ "id", "status" ] } } }, "required": [ "notes" ] }
- updatenote(note, id_)
Update note with given ID
PUT /notes/{id}- Parameters
note (dict) – See Schema below.
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestNotFound – Resource with a given ID not found
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "description": "Notes about all kind of objects", "properties": { "id": { "type": "string", "format": "uuid" }, "typeId": { "type": "string", "format": "uuid" }, "type": { "type": "string", "description": "Type of note (configured in settings)" }, "title": { "type": "string", "description": "Note title" }, "domain": { "type": "string", "description": "Domain associated with this note" }, "content": { "type": "string", "description": "Content of the note" }, "popUpOnCheckOut": { "type": "boolean", "description": "Flag that specify need of pop-up on check-out app" }, "popUpOnUser": { "type": "boolean", "description": "Flag that specify need of pop-up on users app" }, "links": { "type": "array", "description": "Collection of links to associated objects", "items": { "type": "object", "title": "Note link", "description": "Link to object associated with a note", "properties": { "id": { "type": "string", "description": "Id of object linked to note" }, "type": { "type": "string", "description": "Type of object linked to note" } }, "required": [ "id", "type" ], "example": { "id": "1234-5678", "type": "package" } } }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "typeId", "domain", "title" ] }
- updatenotetype(noteType, id_)
Update note type with given ID
PUT /note-types/{id}- Parameters
noteType (dict) – See Schema below.
- Raises
OkapiRequestUnauthorized – Not authorized to perform requested action
OkapiRequestNotFound – Resource with a given ID not found
OkapiRequestFatalError – Unexpected error
Schema
{ "type": "object", "title": "Note Type", "description": "Defines type of note", "properties": { "id": { "type": "string", "format": "uuid" }, "name": { "type": "string", "description": "The unique name of this type", "maxLength": 255 }, "usage": { "type": "object", "readOnly": true, "description": "Type usage statistics", "properties": { "isAssigned": { "type": "boolean", "readOnly": true, "description": "Is this note type assigned to any note" } }, "required": [ "noteTotal" ] }, "metadata": { "type": "object", "title": "Metadata", "description": "Metadata about creation and changes to records", "properties": { "createdDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was created" }, "createdByUserId": { "type": "string", "format": "uuid" }, "createdByUsername": { "type": "string", "description": "Username of the user who created the record (when available)" }, "createdBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } }, "updatedDate": { "type": "string", "format": "date-time", "description": "Date and time when the record was last updated" }, "updatedByUserId": { "type": "string", "format": "uuid" }, "updatedByUsername": { "type": "string", "description": "Username of the user who updated the record (when available)" }, "updatedBy": { "type": "object", "description": "User Display Information", "properties": { "lastName": { "type": "string", "readOnly": true, "description": "Last name of the user" }, "firstName": { "type": "string", "readOnly": true, "description": "First name of the user" }, "middleName": { "type": "string", "readOnly": true, "description": "Middle name or initial of the user" } }, "example": { "lastName": "Doe", "firstName": "John", "middleName": "X." } } }, "required": [ "createdDate" ] } }, "required": [ "name" ], "example": { "id": "118dbd8c-5ba0-47a9-a850-34bbb1dbf3b7", "name": "Important Note" } }