@simplyhomes/sos-sdk
Version:
TypeScript SDK for Simply Homes SoS API v4
182 lines • 79 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 { V4MarketOwnerRelationsCreateRelationMarketOwnerBodyDto, V4MarketOwnerRelationsCreateRelationMarketOwnerResponseDto, V4MarketOwnerRelationsDeleteRelationMarketOwnerResponseDto, V4MarketOwnerRelationsGetRelationMarketOwnerColumnsResponseDto, V4MarketOwnerRelationsGetRelationMarketOwnerResponseDto, V4MarketOwnerRelationsGetRelationMarketOwnersInViewResponseDto, V4MarketOwnerRelationsGetRelationMarketOwnersResponseDto, V4MarketOwnerRelationsUpdateRelationMarketOwnerBodyDto, V4MarketOwnerRelationsUpdateRelationMarketOwnerResponseDto } from '../models/index';
export interface V4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4Request {
v4MarketOwnerRelationsCreateRelationMarketOwnerBodyDto: V4MarketOwnerRelationsCreateRelationMarketOwnerBodyDto;
}
export interface V4MarketOwnerRelationsControllerDeleteRelationMarketOwnerV4Request {
marketId: number;
ownerId: number;
}
export interface V4MarketOwnerRelationsControllerGetRelationMarketOwnerColumnsV4Request {
columns: string;
marketId: number;
ownerId: number;
}
export interface V4MarketOwnerRelationsControllerGetRelationMarketOwnerV4Request {
marketId: number;
ownerId: number;
viewId?: number;
}
export interface V4MarketOwnerRelationsControllerGetRelationMarketOwnersInViewV4Request {
viewId: number;
limit?: number;
offset?: number;
countOnly?: boolean;
}
export interface V4MarketOwnerRelationsControllerGetRelationMarketOwnersV4Request {
viewId?: number;
limit?: number;
offset?: number;
countOnly?: boolean;
}
export interface V4MarketOwnerRelationsControllerUpdateRelationMarketOwnerV4Request {
marketId: number;
ownerId: number;
v4MarketOwnerRelationsUpdateRelationMarketOwnerBodyDto: V4MarketOwnerRelationsUpdateRelationMarketOwnerBodyDto;
}
/**
* RelationMarketOwnersAPIV4Api - interface
*
* @export
* @interface RelationMarketOwnersAPIV4ApiInterface
*/
export interface RelationMarketOwnersAPIV4ApiInterface {
/**
* # POST /v4/relation-market-owners ## Overview Creates a new three-way relationship between a market, property owner, and property manager. This endpoint establishes the association between markets, property owners, and property managers for comprehensive territory management and service area tracking. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Body The request body should contain the relationship information to create the new market-owner-property manager association. ### Required Fields | Field | Type | Description | |-------|------|-------------| | `marketId` | number | ID of the market to associate | | `ownerId` | number | ID of the property owner to associate | | `propertyManagerId` | number | ID of the property manager to associate | ### Validation Rules - **Market ID**: Must be a valid, existing market ID within the organization - **Owner ID**: Must be a valid, existing property owner ID within the organization - **Property Manager ID**: Must be a valid, existing property manager ID within the organization - **Unique Combination**: The combination of market, owner, and property manager must be unique ## Use Cases This endpoint is ideal for: - **Territory Management**: Establish comprehensive territory assignments with both owners and property managers - **Service Area Setup**: Define service areas where property managers work with specific owners in specific markets - **Partnership Establishment**: Create formal partnerships between owners and property managers in specific markets - **Business Expansion**: Establish new three-way relationships when expanding into new markets - **Portfolio Management**: Link owners with their preferred property managers in specific markets - **Market Coverage**: Ensure comprehensive market coverage with proper owner-property manager partnerships - **Relationship Tracking**: Track complex three-way business relationships for reporting and analysis
* @summary Create a new relation-market-owner
* @param {V4MarketOwnerRelationsCreateRelationMarketOwnerBodyDto} v4MarketOwnerRelationsCreateRelationMarketOwnerBodyDto
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof RelationMarketOwnersAPIV4ApiInterface
*/
v4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4Raw(requestParameters: V4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsCreateRelationMarketOwnerResponseDto>>;
/**
* # POST /v4/relation-market-owners ## Overview Creates a new three-way relationship between a market, property owner, and property manager. This endpoint establishes the association between markets, property owners, and property managers for comprehensive territory management and service area tracking. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Body The request body should contain the relationship information to create the new market-owner-property manager association. ### Required Fields | Field | Type | Description | |-------|------|-------------| | `marketId` | number | ID of the market to associate | | `ownerId` | number | ID of the property owner to associate | | `propertyManagerId` | number | ID of the property manager to associate | ### Validation Rules - **Market ID**: Must be a valid, existing market ID within the organization - **Owner ID**: Must be a valid, existing property owner ID within the organization - **Property Manager ID**: Must be a valid, existing property manager ID within the organization - **Unique Combination**: The combination of market, owner, and property manager must be unique ## Use Cases This endpoint is ideal for: - **Territory Management**: Establish comprehensive territory assignments with both owners and property managers - **Service Area Setup**: Define service areas where property managers work with specific owners in specific markets - **Partnership Establishment**: Create formal partnerships between owners and property managers in specific markets - **Business Expansion**: Establish new three-way relationships when expanding into new markets - **Portfolio Management**: Link owners with their preferred property managers in specific markets - **Market Coverage**: Ensure comprehensive market coverage with proper owner-property manager partnerships - **Relationship Tracking**: Track complex three-way business relationships for reporting and analysis
* Create a new relation-market-owner
*/
v4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4(requestParameters: V4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsCreateRelationMarketOwnerResponseDto>;
/**
* # DELETE /v4/market-owner-relations/markets/{marketId}/owners/{ownerId} ## Overview Deletes an existing market-owner relationship from the system. This is a permanent operation that removes the association between a market and property owner, including any optionally associated property manager. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | ## Access Control - **Organization Scope**: Relationship must belong to the authenticated user\'s organization - **Relationship Validation**: Invalid or non-existent relationship combinations will return a 404 error - **Data Privacy**: Only relationships within the user\'s organization can be deleted ## Deletion Behavior The deletion operation: - **Permanent Removal**: Relationship record is permanently deleted from the system - **No Cascade**: Does not affect the associated market, owner, or property manager records - **Territory Impact**: May affect territory coverage and service area assignments - **Partnership Impact**: Removes the business relationship between market and owner, and any associated property manager - **Immediate Effect**: Deletion is applied immediately - **Audit Trail**: Deletion is logged for audit and compliance purposes ## Response Structure Returns confirmation that the relationship was successfully deleted. ## Use Cases This endpoint is ideal for: - **Partnership Dissolution**: Remove market-owner relationships and any associated property manager assignments - **Territory Changes**: Remove market-owner assignments during territory restructuring - **Business Restructuring**: Remove relationships during organizational changes - **Service Area Changes**: Remove property manager assignments from specific market-owner combinations - **Relationship Cleanup**: Clean up obsolete or incorrect market-owner relationships - **Market Exit**: Remove relationships when parties exit specific markets - **Data Management**: Maintain clean relationship databases - **System Maintenance**: Clean up test or duplicate relationship data ## Important Considerations Before deleting a relationship, consider: - **Territory Coverage**: Ensure proper market coverage after removal - **Service Continuity**: Verify property management service continuity - **Business Impact**: Consider impact on ongoing business operations - **Alternative Arrangements**: Ensure alternative service arrangements are in place - **Historical Data**: Consider preserving historical relationship data - **Stakeholder Notification**: Notify affected parties of the relationship termination - **Alternative Actions**: Consider deactivating instead of permanent deletion ## Error Handling Common errors include: - **Relationship Not Found**: Relationship combination does not exist or belongs to different organization - **Permission Denied**: User lacks permission to delete relationships - **Business Rules**: Relationship deletion violates business rules or constraints - **Active Dependencies**: Relationship cannot be deleted due to active business dependencies - **System Errors**: Database or system issues preventing deletion ## Recovery - **No Recovery**: Deleted relationship records cannot be restored through the API - **Backup Systems**: Recovery may be possible through system backups - **Audit Logs**: Deletion events are recorded for audit purposes - **Business Impact**: Consider business continuity and data recovery policies - **Relationship Recreation**: New relationships can be created if needed
* @summary Delete a specific relation-market-owner by marketId and ownerId
* @param {number} marketId The unique identifier of the market
* @param {number} ownerId The unique identifier of the owner
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof RelationMarketOwnersAPIV4ApiInterface
*/
v4MarketOwnerRelationsControllerDeleteRelationMarketOwnerV4Raw(requestParameters: V4MarketOwnerRelationsControllerDeleteRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsDeleteRelationMarketOwnerResponseDto>>;
/**
* # DELETE /v4/market-owner-relations/markets/{marketId}/owners/{ownerId} ## Overview Deletes an existing market-owner relationship from the system. This is a permanent operation that removes the association between a market and property owner, including any optionally associated property manager. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | ## Access Control - **Organization Scope**: Relationship must belong to the authenticated user\'s organization - **Relationship Validation**: Invalid or non-existent relationship combinations will return a 404 error - **Data Privacy**: Only relationships within the user\'s organization can be deleted ## Deletion Behavior The deletion operation: - **Permanent Removal**: Relationship record is permanently deleted from the system - **No Cascade**: Does not affect the associated market, owner, or property manager records - **Territory Impact**: May affect territory coverage and service area assignments - **Partnership Impact**: Removes the business relationship between market and owner, and any associated property manager - **Immediate Effect**: Deletion is applied immediately - **Audit Trail**: Deletion is logged for audit and compliance purposes ## Response Structure Returns confirmation that the relationship was successfully deleted. ## Use Cases This endpoint is ideal for: - **Partnership Dissolution**: Remove market-owner relationships and any associated property manager assignments - **Territory Changes**: Remove market-owner assignments during territory restructuring - **Business Restructuring**: Remove relationships during organizational changes - **Service Area Changes**: Remove property manager assignments from specific market-owner combinations - **Relationship Cleanup**: Clean up obsolete or incorrect market-owner relationships - **Market Exit**: Remove relationships when parties exit specific markets - **Data Management**: Maintain clean relationship databases - **System Maintenance**: Clean up test or duplicate relationship data ## Important Considerations Before deleting a relationship, consider: - **Territory Coverage**: Ensure proper market coverage after removal - **Service Continuity**: Verify property management service continuity - **Business Impact**: Consider impact on ongoing business operations - **Alternative Arrangements**: Ensure alternative service arrangements are in place - **Historical Data**: Consider preserving historical relationship data - **Stakeholder Notification**: Notify affected parties of the relationship termination - **Alternative Actions**: Consider deactivating instead of permanent deletion ## Error Handling Common errors include: - **Relationship Not Found**: Relationship combination does not exist or belongs to different organization - **Permission Denied**: User lacks permission to delete relationships - **Business Rules**: Relationship deletion violates business rules or constraints - **Active Dependencies**: Relationship cannot be deleted due to active business dependencies - **System Errors**: Database or system issues preventing deletion ## Recovery - **No Recovery**: Deleted relationship records cannot be restored through the API - **Backup Systems**: Recovery may be possible through system backups - **Audit Logs**: Deletion events are recorded for audit purposes - **Business Impact**: Consider business continuity and data recovery policies - **Relationship Recreation**: New relationships can be created if needed
* Delete a specific relation-market-owner by marketId and ownerId
*/
v4MarketOwnerRelationsControllerDeleteRelationMarketOwnerV4(requestParameters: V4MarketOwnerRelationsControllerDeleteRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsDeleteRelationMarketOwnerResponseDto>;
/**
* # GET /v4/market-owner-relations/markets/{marketId}/owners/{ownerId}/{columns} ## Overview Retrieves specific columns of a market-owner relationship by its composite key identifiers. This endpoint allows you to fetch only the data you need, improving performance and reducing bandwidth usage. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | | `columns` | string | Yes | Comma-separated list of column names to retrieve | ## Column Selection Available columns include: - **mid**: Market identifier - **oid**: Owner identifier - **pmid**: Property Manager identifier - **market**: Market object (if joined) - **owner**: Owner object (if joined) - **propertyManager**: Property Manager object (if joined) - **createdAt**: Creation timestamp - **updatedAt**: Last update timestamp ### Examples - Single column: `mid` - Multiple columns: `mid,oid,pmid` - With relationships: `mid,oid,pmid,market,owner,propertyManager` - Timestamps only: `createdAt,updatedAt` ## Use Cases This endpoint is ideal for: - **Performance Optimization**: Fetch only required data to reduce response size - **Bandwidth Conservation**: Minimize data transfer for mobile or limited connections - **Specific Data Needs**: Get only the columns needed for specific use cases - **List Views**: Fetch minimal data for displaying relationship lists - **Data Integration**: Get specific relationship data for integration with other systems - **Reporting**: Extract specific columns for reporting purposes - **Territory Analysis**: Get specific relationship data for territory management
* @summary Get specific columns of a relation-market-owner by marketId and ownerId
* @param {string} columns Comma-separated list of column names
* @param {number} marketId The unique identifier of the market
* @param {number} ownerId The unique identifier of the owner
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof RelationMarketOwnersAPIV4ApiInterface
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnerColumnsV4Raw(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnerColumnsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsGetRelationMarketOwnerColumnsResponseDto>>;
/**
* # GET /v4/market-owner-relations/markets/{marketId}/owners/{ownerId}/{columns} ## Overview Retrieves specific columns of a market-owner relationship by its composite key identifiers. This endpoint allows you to fetch only the data you need, improving performance and reducing bandwidth usage. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | | `columns` | string | Yes | Comma-separated list of column names to retrieve | ## Column Selection Available columns include: - **mid**: Market identifier - **oid**: Owner identifier - **pmid**: Property Manager identifier - **market**: Market object (if joined) - **owner**: Owner object (if joined) - **propertyManager**: Property Manager object (if joined) - **createdAt**: Creation timestamp - **updatedAt**: Last update timestamp ### Examples - Single column: `mid` - Multiple columns: `mid,oid,pmid` - With relationships: `mid,oid,pmid,market,owner,propertyManager` - Timestamps only: `createdAt,updatedAt` ## Use Cases This endpoint is ideal for: - **Performance Optimization**: Fetch only required data to reduce response size - **Bandwidth Conservation**: Minimize data transfer for mobile or limited connections - **Specific Data Needs**: Get only the columns needed for specific use cases - **List Views**: Fetch minimal data for displaying relationship lists - **Data Integration**: Get specific relationship data for integration with other systems - **Reporting**: Extract specific columns for reporting purposes - **Territory Analysis**: Get specific relationship data for territory management
* Get specific columns of a relation-market-owner by marketId and ownerId
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnerColumnsV4(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnerColumnsV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsGetRelationMarketOwnerColumnsResponseDto>;
/**
* # GET /v4/market-owner-relations/markets/{marketId}/owners/{ownerId} ## Overview Retrieves a specific market-owner relationship by its composite key identifiers. This endpoint provides detailed information about a single relationship between a market and property owner, with optional property manager association. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | No | Optional view ID to apply specific column selection and formatting | ## Access Control - **Organization Scope**: Only relationships within the authenticated user\'s organization are accessible - **Relationship Validation**: Invalid or non-existent relationship combinations will return a 404 error - **Data Privacy**: Sensitive relationship data is protected by organization boundaries ## Response Structure Returns detailed information about the specified market-owner-property manager relationship. ## Use Cases This endpoint is ideal for: - **Relationship Details**: Get complete information about a specific market-owner relationship - **Territory Analysis**: Analyze specific territory assignments and coverage - **Partnership Verification**: Verify owner assignments to specific markets and any associated property managers - **Relationship Management**: Access detailed relationship information for management purposes - **Business Intelligence**: Get detailed data for relationship analysis - **Service Area Verification**: Verify property management service areas when property managers are assigned - **Audit Trail**: Access specific relationship records for audit purposes
* @summary Get a specific relation-market-owner by marketId and ownerId
* @param {number} marketId The unique identifier of the market
* @param {number} ownerId The unique identifier of the owner
* @param {number} [viewId] The ID of the view to use for retrieving the repository
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof RelationMarketOwnersAPIV4ApiInterface
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnerV4Raw(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsGetRelationMarketOwnerResponseDto>>;
/**
* # GET /v4/market-owner-relations/markets/{marketId}/owners/{ownerId} ## Overview Retrieves a specific market-owner relationship by its composite key identifiers. This endpoint provides detailed information about a single relationship between a market and property owner, with optional property manager association. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | No | Optional view ID to apply specific column selection and formatting | ## Access Control - **Organization Scope**: Only relationships within the authenticated user\'s organization are accessible - **Relationship Validation**: Invalid or non-existent relationship combinations will return a 404 error - **Data Privacy**: Sensitive relationship data is protected by organization boundaries ## Response Structure Returns detailed information about the specified market-owner-property manager relationship. ## Use Cases This endpoint is ideal for: - **Relationship Details**: Get complete information about a specific market-owner relationship - **Territory Analysis**: Analyze specific territory assignments and coverage - **Partnership Verification**: Verify owner assignments to specific markets and any associated property managers - **Relationship Management**: Access detailed relationship information for management purposes - **Business Intelligence**: Get detailed data for relationship analysis - **Service Area Verification**: Verify property management service areas when property managers are assigned - **Audit Trail**: Access specific relationship records for audit purposes
* Get a specific relation-market-owner by marketId and ownerId
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnerV4(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsGetRelationMarketOwnerResponseDto>;
/**
* # GET /v4/relation-market-owners/viewId/{viewId} ## Overview Retrieves market-owner relationships using a specific view configuration. Views define custom filtering, sorting, and column selection for relationships, allowing for organized and consistent data presentation based on business needs. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | Yes | The unique identifier of the view to apply | ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `limit` | number | No | Maximum number of relationships to return (default: 20, max: 100) | | `offset` | number | No | Number of relationships to skip for pagination (default: 0) | | `countOnly` | boolean | No | Return only the count without the actual data | ## View Configuration Views can define: - **Column Selection**: Specific columns to include in the response - **Filtering Rules**: Criteria for which relationships to include - **Sorting Options**: Default sorting for the results - **Access Controls**: Additional permission checks ## Use Cases This endpoint is ideal for: - **Territory Views**: Display relationships according to territory configurations - **Owner Analysis**: Use views to analyze owner-market distributions - **Market Coverage**: Apply views that show market coverage by owners - **Business Intelligence**: Create specialized views for relationship analysis - **Custom Dashboards**: Build custom dashboard views for relationship data - **Filtered Reports**: Generate filtered reports on market-owner relationships
* @summary Get relation-market-owners with a specific viewId
* @param {number} viewId The unique identifier of the view
* @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 RelationMarketOwnersAPIV4ApiInterface
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnersInViewV4Raw(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnersInViewV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsGetRelationMarketOwnersInViewResponseDto>>;
/**
* # GET /v4/relation-market-owners/viewId/{viewId} ## Overview Retrieves market-owner relationships using a specific view configuration. Views define custom filtering, sorting, and column selection for relationships, allowing for organized and consistent data presentation based on business needs. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `viewId` | number | Yes | The unique identifier of the view to apply | ### Query Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `limit` | number | No | Maximum number of relationships to return (default: 20, max: 100) | | `offset` | number | No | Number of relationships to skip for pagination (default: 0) | | `countOnly` | boolean | No | Return only the count without the actual data | ## View Configuration Views can define: - **Column Selection**: Specific columns to include in the response - **Filtering Rules**: Criteria for which relationships to include - **Sorting Options**: Default sorting for the results - **Access Controls**: Additional permission checks ## Use Cases This endpoint is ideal for: - **Territory Views**: Display relationships according to territory configurations - **Owner Analysis**: Use views to analyze owner-market distributions - **Market Coverage**: Apply views that show market coverage by owners - **Business Intelligence**: Create specialized views for relationship analysis - **Custom Dashboards**: Build custom dashboard views for relationship data - **Filtered Reports**: Generate filtered reports on market-owner relationships
* Get relation-market-owners with a specific viewId
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnersInViewV4(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnersInViewV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsGetRelationMarketOwnersInViewResponseDto>;
/**
* # GET /v4/relation-market-owners ## Overview Retrieves market-owner relationships with optional filtering, sorting, and pagination capabilities. This endpoint provides access to the associations between markets, property owners, and property managers, essential for territory management and ownership tracking in real estate operations. ## 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 and column selection | | `limit` | number | No | Maximum number of relationships to return (default: 20, max: 100) | | `offset` | number | No | Number of relationships to skip for pagination (default: 0) | | `countOnly` | boolean | No | Return only the count of relationships without the actual data | ## Relationship Structure This endpoint manages three-way relationships between: - **Markets**: Geographic territories or business regions - **Owners**: Property owners operating in markets - **Property Managers**: Property management companies serving markets ## Use Cases This endpoint is ideal for: - **Territory Management**: Track which owners and property managers operate in which markets - **Ownership Analysis**: Analyze owner and property manager distribution across different markets - **Market Coverage**: Understand owner and property manager presence and coverage in markets - **Relationship Mapping**: Map the three-way connections between markets, owners, and property managers - **Business Intelligence**: Generate insights on market-owner-property manager relationships - **Portfolio Analysis**: Analyze owner portfolios and property manager coverage across multiple markets - **Service Area Management**: Track property management service areas by market - **Partnership Analysis**: Analyze partnerships between owners and property managers in specific markets
* @summary Get relation-market-owners with optional viewId
* @param {number} [viewId] The ID of the view to use for retrieving the repository
* @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 RelationMarketOwnersAPIV4ApiInterface
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnersV4Raw(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnersV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsGetRelationMarketOwnersResponseDto>>;
/**
* # GET /v4/relation-market-owners ## Overview Retrieves market-owner relationships with optional filtering, sorting, and pagination capabilities. This endpoint provides access to the associations between markets, property owners, and property managers, essential for territory management and ownership tracking in real estate operations. ## 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 and column selection | | `limit` | number | No | Maximum number of relationships to return (default: 20, max: 100) | | `offset` | number | No | Number of relationships to skip for pagination (default: 0) | | `countOnly` | boolean | No | Return only the count of relationships without the actual data | ## Relationship Structure This endpoint manages three-way relationships between: - **Markets**: Geographic territories or business regions - **Owners**: Property owners operating in markets - **Property Managers**: Property management companies serving markets ## Use Cases This endpoint is ideal for: - **Territory Management**: Track which owners and property managers operate in which markets - **Ownership Analysis**: Analyze owner and property manager distribution across different markets - **Market Coverage**: Understand owner and property manager presence and coverage in markets - **Relationship Mapping**: Map the three-way connections between markets, owners, and property managers - **Business Intelligence**: Generate insights on market-owner-property manager relationships - **Portfolio Analysis**: Analyze owner portfolios and property manager coverage across multiple markets - **Service Area Management**: Track property management service areas by market - **Partnership Analysis**: Analyze partnerships between owners and property managers in specific markets
* Get relation-market-owners with optional viewId
*/
v4MarketOwnerRelationsControllerGetRelationMarketOwnersV4(requestParameters: V4MarketOwnerRelationsControllerGetRelationMarketOwnersV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsGetRelationMarketOwnersResponseDto>;
/**
* # PATCH /v4/market-owner-relations/markets/{marketId}/owners/{ownerId} ## Overview Updates information of an existing market-owner relationship. This endpoint allows you to modify relationship properties, including adding, updating, or removing the associated property manager. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | ## Request Body The request body should contain the fields to update. Since this is a relationship entity with composite keys, updates are typically limited to metadata fields. ### Note on Updates For market-owner relationship entities: - The primary identifiers (marketId, ownerId) form the composite key - The property manager can be added, updated, or removed (set to null) as it\'s optional - Updates can include property manager assignments, removals, and other relationship metadata ## Use Cases This endpoint is ideal for: - **Metadata Updates**: Update any metadata associated with the relationship - **Status Changes**: Update relationship status or flags - **Audit Updates**: Update audit fields or tracking information - **Relationship Refinement**: Fine-tune relationship properties without changing core associations - **Data Correction**: Fix any incorrect metadata in the relationship - **Business Rule Updates**: Update business rules or constraints associated with the relationship ## Access Control - **Organization Scope**: Relationship must belong to the authenticated user\'s organization - **Update Validation**: Only valid relationship combinations can be updated - **Data Privacy**: Updates are isolated to the user\'s organization - **Composite Key Integrity**: Core relationship identifiers cannot be modified ## Important Note To change the core relationship (market, owner, or property manager), you would typically: 1. Delete the existing relationship 2. Create a new relationship with the updated identifiers
* @summary Update a specific relation-market-owner by marketId and ownerId
* @param {number} marketId The unique identifier of the market
* @param {number} ownerId The unique identifier of the owner
* @param {V4MarketOwnerRelationsUpdateRelationMarketOwnerBodyDto} v4MarketOwnerRelationsUpdateRelationMarketOwnerBodyDto
* @param {*} [options] Override http request option.
* @throws {RequiredError}
* @memberof RelationMarketOwnersAPIV4ApiInterface
*/
v4MarketOwnerRelationsControllerUpdateRelationMarketOwnerV4Raw(requestParameters: V4MarketOwnerRelationsControllerUpdateRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsUpdateRelationMarketOwnerResponseDto>>;
/**
* # PATCH /v4/market-owner-relations/markets/{marketId}/owners/{ownerId} ## Overview Updates information of an existing market-owner relationship. This endpoint allows you to modify relationship properties, including adding, updating, or removing the associated property manager. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | ## Request Body The request body should contain the fields to update. Since this is a relationship entity with composite keys, updates are typically limited to metadata fields. ### Note on Updates For market-owner relationship entities: - The primary identifiers (marketId, ownerId) form the composite key - The property manager can be added, updated, or removed (set to null) as it\'s optional - Updates can include property manager assignments, removals, and other relationship metadata ## Use Cases This endpoint is ideal for: - **Metadata Updates**: Update any metadata associated with the relationship - **Status Changes**: Update relationship status or flags - **Audit Updates**: Update audit fields or tracking information - **Relationship Refinement**: Fine-tune relationship properties without changing core associations - **Data Correction**: Fix any incorrect metadata in the relationship - **Business Rule Updates**: Update business rules or constraints associated with the relationship ## Access Control - **Organization Scope**: Relationship must belong to the authenticated user\'s organization - **Update Validation**: Only valid relationship combinations can be updated - **Data Privacy**: Updates are isolated to the user\'s organization - **Composite Key Integrity**: Core relationship identifiers cannot be modified ## Important Note To change the core relationship (market, owner, or property manager), you would typically: 1. Delete the existing relationship 2. Create a new relationship with the updated identifiers
* Update a specific relation-market-owner by marketId and ownerId
*/
v4MarketOwnerRelationsControllerUpdateRelationMarketOwnerV4(requestParameters: V4MarketOwnerRelationsControllerUpdateRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsUpdateRelationMarketOwnerResponseDto>;
}
/**
*
*/
export declare class RelationMarketOwnersAPIV4Api extends runtime.BaseAPI implements RelationMarketOwnersAPIV4ApiInterface {
/**
* # POST /v4/relation-market-owners ## Overview Creates a new three-way relationship between a market, property owner, and property manager. This endpoint establishes the association between markets, property owners, and property managers for comprehensive territory management and service area tracking. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Body The request body should contain the relationship information to create the new market-owner-property manager association. ### Required Fields | Field | Type | Description | |-------|------|-------------| | `marketId` | number | ID of the market to associate | | `ownerId` | number | ID of the property owner to associate | | `propertyManagerId` | number | ID of the property manager to associate | ### Validation Rules - **Market ID**: Must be a valid, existing market ID within the organization - **Owner ID**: Must be a valid, existing property owner ID within the organization - **Property Manager ID**: Must be a valid, existing property manager ID within the organization - **Unique Combination**: The combination of market, owner, and property manager must be unique ## Use Cases This endpoint is ideal for: - **Territory Management**: Establish comprehensive territory assignments with both owners and property managers - **Service Area Setup**: Define service areas where property managers work with specific owners in specific markets - **Partnership Establishment**: Create formal partnerships between owners and property managers in specific markets - **Business Expansion**: Establish new three-way relationships when expanding into new markets - **Portfolio Management**: Link owners with their preferred property managers in specific markets - **Market Coverage**: Ensure comprehensive market coverage with proper owner-property manager partnerships - **Relationship Tracking**: Track complex three-way business relationships for reporting and analysis
* Create a new relation-market-owner
*/
v4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4Raw(requestParameters: V4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<runtime.ApiResponse<V4MarketOwnerRelationsCreateRelationMarketOwnerResponseDto>>;
/**
* # POST /v4/relation-market-owners ## Overview Creates a new three-way relationship between a market, property owner, and property manager. This endpoint establishes the association between markets, property owners, and property managers for comprehensive territory management and service area tracking. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Body The request body should contain the relationship information to create the new market-owner-property manager association. ### Required Fields | Field | Type | Description | |-------|------|-------------| | `marketId` | number | ID of the market to associate | | `ownerId` | number | ID of the property owner to associate | | `propertyManagerId` | number | ID of the property manager to associate | ### Validation Rules - **Market ID**: Must be a valid, existing market ID within the organization - **Owner ID**: Must be a valid, existing property owner ID within the organization - **Property Manager ID**: Must be a valid, existing property manager ID within the organization - **Unique Combination**: The combination of market, owner, and property manager must be unique ## Use Cases This endpoint is ideal for: - **Territory Management**: Establish comprehensive territory assignments with both owners and property managers - **Service Area Setup**: Define service areas where property managers work with specific owners in specific markets - **Partnership Establishment**: Create formal partnerships between owners and property managers in specific markets - **Business Expansion**: Establish new three-way relationships when expanding into new markets - **Portfolio Management**: Link owners with their preferred property managers in specific markets - **Market Coverage**: Ensure comprehensive market coverage with proper owner-property manager partnerships - **Relationship Tracking**: Track complex three-way business relationships for reporting and analysis
* Create a new relation-market-owner
*/
v4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4(requestParameters: V4MarketOwnerRelationsControllerCreateRelationMarketOwnerV4Request, initOverrides?: RequestInit | runtime.InitOverrideFunction): Promise<V4MarketOwnerRelationsCreateRelationMarketOwnerResponseDto>;
/**
* # DELETE /v4/market-owner-relations/markets/{marketId}/owners/{ownerId} ## Overview Deletes an existing market-owner relationship from the system. This is a permanent operation that removes the association between a market and property owner, including any optionally associated property manager. ## Authentication - **Required**: Yes - **Security**: - `x-api-key` header - `organization-id` header ## Request Parameters ### Path Parameters | Parameter | Type | Required | Description | |-----------|------|----------|-------------| | `marketId` | number | Yes | The unique identifier of the market | | `ownerId` | number | Yes | The unique identifier of the property owner | ## Access Control - **Organization Scope**: Relationship must belong to the authenticated user\'s organization - **Relationship Validation**: Invalid or non-existent relationship combinations will return a 404 error - **Data Privacy**: Only relationships within the user\'s organization can be deleted ## Deletion Behavior The deletion operation: - **Permanent Removal**: Relationship record is permanently deleted from the system - **No Cascade**: Does not affect the associated market, owner, or property manager records - **Territory Impact**: May affect territory coverage and service area assignments - **Partnership Impact**: Removes the business relationship between market and owner, and any associated property manager - **Immediate Effect**: Deletion is applied immediately - **Audit Trail**: Deletion is logged for audit and compliance purposes ## Response Structure Returns confirmation that the relationship was successfully deleted. ## Use Cases This endpoint is ideal for: - **Partnership Dissolution**: Remove market-owner relationships and any associated property manager assignments - **Territory Changes**: Remove market-owner assignments during territory restructuring - **Business Restructuring**: Remove relationships during organizational changes - **Service Area Changes**: Remove property manager assignments from specific market-owner combinations - **Relationship Cleanup**: Clean up obsolete or incorrect market-owner relationships - **Market Exit**: Remove relationships when parties exit specific markets - **Data Management**: Maintain clean relationship databases - **System Maintenance**: Clean up test or duplicate relationship data ## Important Considerations Before deleting a relationship, consider: - **Territory Coverage**: Ensure proper market coverage after removal - **Service Continuity**: Verify property management service continuity - **Business Impact**: Consider impact on ongoing business operations - **Alternative Arrangements**: Ensure alternative service arrangements are in place - **Historical Data**: Consider preserving historical relationship data - **Stakeholder Notification**: Notify affected parties of the relationship termination - **Alternative Actions**: Consider deactivating instead of permanent deletion ## Error Handling Common errors include: - **Relationship Not Found**: Relationship combination does not exist or belongs to different organization - **Permission Denied**: User lacks permission to delete relationships - **Business