Skip to content

oldas.folders

Provides a class for loading up the folders.

Folder

Bases: NamedTuple

Folder information class.

id instance-attribute

id

The ID of the folder.

name property

name

The name of the folder.

raw class-attribute instance-attribute

raw = None

The raw data from the API.

sort_id instance-attribute

sort_id

The sort ID of the folder.

from_json classmethod

from_json(data)

Load the folder from JSON data.

Parameters:

Name Type Description Default

data

RawData

The data to load the folder from.

required

Returns:

Type Description
Folder

The folder information.

Folders

Folders(data=None)

Bases: OldList[Folder]

Load the folder list from TheOldReader.

load async classmethod

load(session)

Load the folders.

Parameters:

Name Type Description Default

session

Session

The API session object.

required

Returns:

Type Description
Folders

A list of folders.