bcgov / entity

ServiceBC Registry Team working on Legal Entities
Apache License 2.0
23 stars 58 forks source link

Platform API Validation - Real Time #23672

Open fionazhou-jsb opened 4 days ago

fionazhou-jsb commented 4 days ago

As a STR Platform I want to pass host registration details (registration number, unit number if applicable, street number, and postal code) via API to the STR registry,
so that I can confirm the validity of the registration and ensure compliance with regulations.

Context / Background

Platform must validate their registration details against the Short Term Rental registry. The validation includes checking the registration status and confirming that the address information (unit number, street number, and postal code) entered by the host on the platform site matches what is on file with the registry.

We need to return a message that indicate whether the validation passes or fails.

Presentation

Teams Channel

Document given to Housing regarding API

Business Rules

Real Time API Call:

For Valid Registration

- registration: abcd123, code: 404,  status: ACTIVE (suspended, cancelled, expired)  

 - code: 404 means there is an error ( 

Address mismatch

Story Scenarios

Scenario 1: Registration number is invalid

Scenario 2: Registration number and address details are valid

Scenario 3: Registration number does not match the address details

Scenario 4: API call fails or external registry is unavailable

fionazhou-jsb commented 2 days ago

@stcepeda for you to review

mbertucci commented 1 day ago

@thorwolpert

Good morning Thor.

We had a brief chat via teams about codes. Can you provide us with recommendations for the codes for this ticket and #23671?

I'm ok with you editing the ticket and adding those numbers or correcting any misunderstandings that we have for the error messages.

Thank you,

M

stcepeda commented 1 day ago

@fionazhou-jsb Registration statuses each need to be separate codes. Active passes validation. Suspended passes validation and requires 1 action from platforms (don't publish but don't cancel bookings), while other statuses require diffrent actions : cancelled (don't publish, cancel bookings), expired (don't publish and I don't remember if they need to cancel bookings). Anyway, each of these need to return a separate code as platform action will vary. Otherwise, looks good.