@simplyhomes/sos-sdk
Version:
TypeScript SDK for Simply Homes SoS API v4
234 lines • 23.4 kB
TypeScript
/**
* API v4
* Swagger documentation for API v4
*
* The version of the OpenAPI document: 4.0
*
*
* NOTE: This class is auto generated by OpenAPI Generator (https://openapi-generator.tech).
* https://openapi-generator.tech
* Do not edit the class manually.
*/
import * as runtime from '../runtime';
import type { V4LeasingsCreateLeasingBodyDto, V4LeasingsCreateLeasingResponseDto, V4LeasingsDeleteLeasingResponseDto, V4LeasingsGetLeasingColumnsResponseDto, V4LeasingsGetLeasingResponseDto, V4LeasingsGetLeasingsInViewResponseDto, V4LeasingsGetLeasingsResponseDto, V4LeasingsUpdateLeasingBodyDto, V4LeasingsUpdateLeasingResponseDto } from '../models/index';
export interface V4LeasingsControllerCreateLeasingV4Request {
v4LeasingsCreateLeasingBodyDto: V4LeasingsCreateLeasingBodyDto;
}
export interface V4LeasingsControllerDeleteLeasingV4Request {
leasingId: number;
}
export interface V4LeasingsControllerGetLeasingColumnsV4Request {
leasingId: string;
columns: string;
}
export interface V4LeasingsControllerGetLeasingV4Request {
leasingId: number;
viewId?: number;
}
export interface V4LeasingsControllerGetLeasingsInViewV4Request {
viewId: number;
limit?: number;
offset?: number;
countOnly?: boolean;
}
export interface V4LeasingsControllerGetLeasingsV4Request {
viewId?: number;
limit?: number;
offset?: number;
countOnly?: boolean;
}
export interface V4LeasingsControllerUpdateLeasingV4Request {
leasingId: number;
v4LeasingsUpdateLeasingBodyDto: V4LeasingsUpdateLeasingBodyDto;
}
/**
* LeasingsAPIV4Api - interface
*
* @export
* @interface LeasingsAPIV4ApiInterface
*/
export interface LeasingsAPIV4ApiInterface {
/**
* Create a new leasing record in the system
* @summary Create a new leasing
* @param {V4LeasingsCreateLeasingBodyDto} v4LeasingsCreateLeasingBodyDto
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LeasingsAPIV4ApiInterface
*/
v4LeasingsControllerCreateLeasingV4Raw(requestParameters: V4LeasingsControllerCreateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsCreateLeasingResponseDto>>;
/**
* Create a new leasing record in the system
* Create a new leasing
*/
v4LeasingsControllerCreateLeasingV4(requestParameters: V4LeasingsControllerCreateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsCreateLeasingResponseDto>;
/**
* Remove a leasing record from the system
* @summary Delete a specific leasing by leasingId
* @param {number} leasingId The unique identifier of the leasing
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LeasingsAPIV4ApiInterface
*/
v4LeasingsControllerDeleteLeasingV4Raw(requestParameters: V4LeasingsControllerDeleteLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsDeleteLeasingResponseDto>>;
/**
* Remove a leasing record from the system
* Delete a specific leasing by leasingId
*/
v4LeasingsControllerDeleteLeasingV4(requestParameters: V4LeasingsControllerDeleteLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsDeleteLeasingResponseDto>;
/**
* Retrieve only specified columns of a leasing for optimized data transfer
* @summary Get specific columns of a leasing by leasingId
* @param {string} leasingId The unique identifier of the leasing
* @param {string} columns Comma-separated list of column names
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LeasingsAPIV4ApiInterface
*/
v4LeasingsControllerGetLeasingColumnsV4Raw(requestParameters: V4LeasingsControllerGetLeasingColumnsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingColumnsResponseDto>>;
/**
* Retrieve only specified columns of a leasing for optimized data transfer
* Get specific columns of a leasing by leasingId
*/
v4LeasingsControllerGetLeasingColumnsV4(requestParameters: V4LeasingsControllerGetLeasingColumnsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingColumnsResponseDto>;
/**
* Retrieve detailed information about a specific leasing
* @summary Get a specific leasing by leasingId
* @param {number} leasingId The unique identifier of the leasing
* @param {number} [viewId] The ID of the view to apply when retrieving the leasing
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LeasingsAPIV4ApiInterface
*/
v4LeasingsControllerGetLeasingV4Raw(requestParameters: V4LeasingsControllerGetLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingResponseDto>>;
/**
* Retrieve detailed information about a specific leasing
* Get a specific leasing by leasingId
*/
v4LeasingsControllerGetLeasingV4(requestParameters: V4LeasingsControllerGetLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingResponseDto>;
/**
* Retrieve leasings filtered by a specific view configuration
* @summary Get leasings with a specific viewId
* @param {number} viewId The unique identifier of the view
* @param {number} [limit] Limit the number of leasings returned
* @param {number} [offset] Number of leasings to skip
* @param {boolean} [countOnly] If true, only return the count without the actual objects
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LeasingsAPIV4ApiInterface
*/
v4LeasingsControllerGetLeasingsInViewV4Raw(requestParameters: V4LeasingsControllerGetLeasingsInViewV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingsInViewResponseDto>>;
/**
* Retrieve leasings filtered by a specific view configuration
* Get leasings with a specific viewId
*/
v4LeasingsControllerGetLeasingsInViewV4(requestParameters: V4LeasingsControllerGetLeasingsInViewV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingsInViewResponseDto>;
/**
* # GET /v4/leasings ## Overview Retrieves a list of leasings with optional filtering, sorting, and pagination capabilities. This endpoint allows you to query leasings using view configurations or direct parameters to get customized leasing datasets. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | No | Optional view ID to apply filters, sorts, and column selections | | `limit` | number | No | Maximum number of leasings to return (default: 10, max: 100) | | `offset` | number | No | Number of leasings to skip for pagination (default: 0) | ### View Integration When a `viewId` is provided: - **Filters**: View filters are automatically applied to the query - **Sorts**: View sort configurations determine result ordering - **Columns**: View column selections determine returned fields - **Validation**: View must exist and belong to the authenticated user ### Pagination The endpoint supports offset-based pagination: - **Default Limit**: 10 leasings per request - **Maximum Limit**: 100 leasings per request - **Offset Calculation**: Use `offset = page * limit` for page-based pagination ## Response Structure The response contains an array of leasing objects with pagination metadata. ## Use Cases This endpoint is ideal for: - Building leasing listing interfaces - Implementing leasing search and filtering - Creating leasing dashboards and analytics - Generating leasing reports and exports - Managing rental agreements and tenant relationships - Tracking lease terms and rental income ## Performance Considerations - **Pagination**: Use appropriate limit values to balance performance and data needs - **View Optimization**: Well-designed views with targeted filters improve response times - **Column Selection**: Limit returned columns through views for better performance - **Caching**: Consider implementing client-side caching for frequently accessed data ## Integration Patterns **Standard Listing:** - No viewId: Returns all organization leasings with default columns - Basic pagination: Use limit/offset for page navigation **Filtered Views:** - With viewId: Returns leasings matching view criteria - Consistent Results: Same view always returns same filtered dataset - User Personalization: Each user can have custom views for different purposes
* @summary Get leasings with optional viewId
* @param {number} [viewId] The ID of the view to filter the leasings
* @param {number} [limit] The maximum number of objects to return
* @param {number} [offset] The offset for pagination, used to skip a number of objects
* @param {boolean} [countOnly] Whether to return only the count of objects instead of the objects themselves
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LeasingsAPIV4ApiInterface
*/
v4LeasingsControllerGetLeasingsV4Raw(requestParameters: V4LeasingsControllerGetLeasingsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingsResponseDto>>;
/**
* # GET /v4/leasings ## Overview Retrieves a list of leasings with optional filtering, sorting, and pagination capabilities. This endpoint allows you to query leasings using view configurations or direct parameters to get customized leasing datasets. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | No | Optional view ID to apply filters, sorts, and column selections | | `limit` | number | No | Maximum number of leasings to return (default: 10, max: 100) | | `offset` | number | No | Number of leasings to skip for pagination (default: 0) | ### View Integration When a `viewId` is provided: - **Filters**: View filters are automatically applied to the query - **Sorts**: View sort configurations determine result ordering - **Columns**: View column selections determine returned fields - **Validation**: View must exist and belong to the authenticated user ### Pagination The endpoint supports offset-based pagination: - **Default Limit**: 10 leasings per request - **Maximum Limit**: 100 leasings per request - **Offset Calculation**: Use `offset = page * limit` for page-based pagination ## Response Structure The response contains an array of leasing objects with pagination metadata. ## Use Cases This endpoint is ideal for: - Building leasing listing interfaces - Implementing leasing search and filtering - Creating leasing dashboards and analytics - Generating leasing reports and exports - Managing rental agreements and tenant relationships - Tracking lease terms and rental income ## Performance Considerations - **Pagination**: Use appropriate limit values to balance performance and data needs - **View Optimization**: Well-designed views with targeted filters improve response times - **Column Selection**: Limit returned columns through views for better performance - **Caching**: Consider implementing client-side caching for frequently accessed data ## Integration Patterns **Standard Listing:** - No viewId: Returns all organization leasings with default columns - Basic pagination: Use limit/offset for page navigation **Filtered Views:** - With viewId: Returns leasings matching view criteria - Consistent Results: Same view always returns same filtered dataset - User Personalization: Each user can have custom views for different purposes
* Get leasings with optional viewId
*/
v4LeasingsControllerGetLeasingsV4(requestParameters: V4LeasingsControllerGetLeasingsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingsResponseDto>;
/**
* Update an existing leasing record with new data
* @summary Update a specific leasing by leasingId
* @param {number} leasingId The unique identifier of the leasing
* @param {V4LeasingsUpdateLeasingBodyDto} v4LeasingsUpdateLeasingBodyDto
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof LeasingsAPIV4ApiInterface
*/
v4LeasingsControllerUpdateLeasingV4Raw(requestParameters: V4LeasingsControllerUpdateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsUpdateLeasingResponseDto>>;
/**
* Update an existing leasing record with new data
* Update a specific leasing by leasingId
*/
v4LeasingsControllerUpdateLeasingV4(requestParameters: V4LeasingsControllerUpdateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsUpdateLeasingResponseDto>;
}
/**
*
*/
export declare class LeasingsAPIV4Api extends runtime.BaseAPI implements LeasingsAPIV4ApiInterface {
/**
* Create a new leasing record in the system
* Create a new leasing
*/
v4LeasingsControllerCreateLeasingV4Raw(requestParameters: V4LeasingsControllerCreateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsCreateLeasingResponseDto>>;
/**
* Create a new leasing record in the system
* Create a new leasing
*/
v4LeasingsControllerCreateLeasingV4(requestParameters: V4LeasingsControllerCreateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsCreateLeasingResponseDto>;
/**
* Remove a leasing record from the system
* Delete a specific leasing by leasingId
*/
v4LeasingsControllerDeleteLeasingV4Raw(requestParameters: V4LeasingsControllerDeleteLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsDeleteLeasingResponseDto>>;
/**
* Remove a leasing record from the system
* Delete a specific leasing by leasingId
*/
v4LeasingsControllerDeleteLeasingV4(requestParameters: V4LeasingsControllerDeleteLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsDeleteLeasingResponseDto>;
/**
* Retrieve only specified columns of a leasing for optimized data transfer
* Get specific columns of a leasing by leasingId
*/
v4LeasingsControllerGetLeasingColumnsV4Raw(requestParameters: V4LeasingsControllerGetLeasingColumnsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingColumnsResponseDto>>;
/**
* Retrieve only specified columns of a leasing for optimized data transfer
* Get specific columns of a leasing by leasingId
*/
v4LeasingsControllerGetLeasingColumnsV4(requestParameters: V4LeasingsControllerGetLeasingColumnsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingColumnsResponseDto>;
/**
* Retrieve detailed information about a specific leasing
* Get a specific leasing by leasingId
*/
v4LeasingsControllerGetLeasingV4Raw(requestParameters: V4LeasingsControllerGetLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingResponseDto>>;
/**
* Retrieve detailed information about a specific leasing
* Get a specific leasing by leasingId
*/
v4LeasingsControllerGetLeasingV4(requestParameters: V4LeasingsControllerGetLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingResponseDto>;
/**
* Retrieve leasings filtered by a specific view configuration
* Get leasings with a specific viewId
*/
v4LeasingsControllerGetLeasingsInViewV4Raw(requestParameters: V4LeasingsControllerGetLeasingsInViewV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingsInViewResponseDto>>;
/**
* Retrieve leasings filtered by a specific view configuration
* Get leasings with a specific viewId
*/
v4LeasingsControllerGetLeasingsInViewV4(requestParameters: V4LeasingsControllerGetLeasingsInViewV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingsInViewResponseDto>;
/**
* # GET /v4/leasings ## Overview Retrieves a list of leasings with optional filtering, sorting, and pagination capabilities. This endpoint allows you to query leasings using view configurations or direct parameters to get customized leasing datasets. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | No | Optional view ID to apply filters, sorts, and column selections | | `limit` | number | No | Maximum number of leasings to return (default: 10, max: 100) | | `offset` | number | No | Number of leasings to skip for pagination (default: 0) | ### View Integration When a `viewId` is provided: - **Filters**: View filters are automatically applied to the query - **Sorts**: View sort configurations determine result ordering - **Columns**: View column selections determine returned fields - **Validation**: View must exist and belong to the authenticated user ### Pagination The endpoint supports offset-based pagination: - **Default Limit**: 10 leasings per request - **Maximum Limit**: 100 leasings per request - **Offset Calculation**: Use `offset = page * limit` for page-based pagination ## Response Structure The response contains an array of leasing objects with pagination metadata. ## Use Cases This endpoint is ideal for: - Building leasing listing interfaces - Implementing leasing search and filtering - Creating leasing dashboards and analytics - Generating leasing reports and exports - Managing rental agreements and tenant relationships - Tracking lease terms and rental income ## Performance Considerations - **Pagination**: Use appropriate limit values to balance performance and data needs - **View Optimization**: Well-designed views with targeted filters improve response times - **Column Selection**: Limit returned columns through views for better performance - **Caching**: Consider implementing client-side caching for frequently accessed data ## Integration Patterns **Standard Listing:** - No viewId: Returns all organization leasings with default columns - Basic pagination: Use limit/offset for page navigation **Filtered Views:** - With viewId: Returns leasings matching view criteria - Consistent Results: Same view always returns same filtered dataset - User Personalization: Each user can have custom views for different purposes
* Get leasings with optional viewId
*/
v4LeasingsControllerGetLeasingsV4Raw(requestParameters: V4LeasingsControllerGetLeasingsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsGetLeasingsResponseDto>>;
/**
* # GET /v4/leasings ## Overview Retrieves a list of leasings with optional filtering, sorting, and pagination capabilities. This endpoint allows you to query leasings using view configurations or direct parameters to get customized leasing datasets. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | No | Optional view ID to apply filters, sorts, and column selections | | `limit` | number | No | Maximum number of leasings to return (default: 10, max: 100) | | `offset` | number | No | Number of leasings to skip for pagination (default: 0) | ### View Integration When a `viewId` is provided: - **Filters**: View filters are automatically applied to the query - **Sorts**: View sort configurations determine result ordering - **Columns**: View column selections determine returned fields - **Validation**: View must exist and belong to the authenticated user ### Pagination The endpoint supports offset-based pagination: - **Default Limit**: 10 leasings per request - **Maximum Limit**: 100 leasings per request - **Offset Calculation**: Use `offset = page * limit` for page-based pagination ## Response Structure The response contains an array of leasing objects with pagination metadata. ## Use Cases This endpoint is ideal for: - Building leasing listing interfaces - Implementing leasing search and filtering - Creating leasing dashboards and analytics - Generating leasing reports and exports - Managing rental agreements and tenant relationships - Tracking lease terms and rental income ## Performance Considerations - **Pagination**: Use appropriate limit values to balance performance and data needs - **View Optimization**: Well-designed views with targeted filters improve response times - **Column Selection**: Limit returned columns through views for better performance - **Caching**: Consider implementing client-side caching for frequently accessed data ## Integration Patterns **Standard Listing:** - No viewId: Returns all organization leasings with default columns - Basic pagination: Use limit/offset for page navigation **Filtered Views:** - With viewId: Returns leasings matching view criteria - Consistent Results: Same view always returns same filtered dataset - User Personalization: Each user can have custom views for different purposes
* Get leasings with optional viewId
*/
v4LeasingsControllerGetLeasingsV4(requestParameters?: V4LeasingsControllerGetLeasingsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsGetLeasingsResponseDto>;
/**
* Update an existing leasing record with new data
* Update a specific leasing by leasingId
*/
v4LeasingsControllerUpdateLeasingV4Raw(requestParameters: V4LeasingsControllerUpdateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4LeasingsUpdateLeasingResponseDto>>;
/**
* Update an existing leasing record with new data
* Update a specific leasing by leasingId
*/
v4LeasingsControllerUpdateLeasingV4(requestParameters: V4LeasingsControllerUpdateLeasingV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4LeasingsUpdateLeasingResponseDto>;
}
//# sourceMappingURL=LeasingsAPIV4Api.d.ts.map