arxiv.submission.domain.agent module

Data structures for agents.

class arxiv.submission.domain.agent.Agent(native_id)[source]

Bases: object

Base class for agents in the submission system.

An agent is an actor/system that generates/is responsible for events.

get_agent_identifier()[source]

Get the unique identifier for this agent instance.

Based on both the agent type and native ID.

Return type

str

classmethod get_agent_type()[source]

Get the name of the instance’s class.

Return type

str

native_id = None

Type-specific identifier for the agent. This might be an URI.

class arxiv.submission.domain.agent.User(native_id, email=<factory>, username=<factory>, forename=<factory>, surname=<factory>, suffix=<factory>, name=<factory>, identifier=None, affiliation=<factory>, hostname=None, endorsements=<factory>, agent_type=<factory>, agent_identifier=<factory>)[source]

Bases: arxiv.submission.domain.agent.Agent

An (human) end user.

get_name()[source]

Full name of the user.

hostname = None

Hostname or IP address from which user requests are originating.

identifier = None
class arxiv.submission.domain.agent.System(native_id, agent_type=<factory>, agent_identifier=<factory>, username=<factory>, hostname=<factory>)[source]

Bases: arxiv.submission.domain.agent.Agent

The submission application (this application).

class arxiv.submission.domain.agent.Client(native_id, hostname=None, agent_type=<factory>, agent_identifier=<factory>)[source]

Bases: arxiv.submission.domain.agent.Agent

A non-human third party, usually an API client.

hostname = None

Hostname or IP address from which client requests are originating.

arxiv.submission.domain.agent.agent_factory(**data)[source]

Instantiate a subclass of Agent.

Return type

Agent