Endpoints are the main building blocks of TypedRest. An endpoint represents an URI that provides methods for interacting with a specific resource. The type of the endpoint determines the available methods.
TypedRest provides a number of endpoint types modelling common REST patterns. Most APIs can be consumed by either directly using these types or by deriving from them and adding a few additional methods for special use cases.
Entry endpoints represent the top-level URI of APIs.
Generic endpoints allow you to model collections and elements:
- Element - individual resource (read, write, delete)
- Collection - collection of entities addressable as elements (read all, create, get child by ID)
- Indexer - address child endpoints by ID
Raw endpoints allow you to transmit binary data rather than serialized objects:
Reactive endpoints allow you to receive data as push streams rather than explicitly pulling:
- Polling - poll resource for state changes
- Streaming - stream of entities via persistent connection
- Streaming Collection - collection of entities observable as append-only stream
RPC endpoints allow you to interact with non-RESTful resources that act like callable functions: