US-EPA-CAMD / easey-ui

Project Management repo for EPA Clean Air Markets Division (CAMD) Business Suite of applications
MIT License
0 stars 0 forks source link

Interface with RGGI #3921

Open MaeganWood64 opened 1 year ago

MaeganWood64 commented 1 year ago

Original Description

Link to Draft RGGI Requirements: https://usepa.sharepoint.com/:w:/r/sites/CAMDCVPTeam/Shared%20Documents/Integration%20Coordination/RGGI/RGGI%20ECMPS%202.0/Draft%20RGGI%20Requirements.docx?d=wdc7a1b1f4a924fbeb76dc0a6e330438e&csf=1&web=1&e=Mc7gCF

Overview

  1. Develop the JSON schema for the Facility Data Summary Data Endpoint endpoint payloads.
  2. Develop the JSON schema for the Facility Data Specific Data Endpoint endpoint payloads.
  3. Develop the JSON schema for the Quarterly Apportioned Emissions Data Specific Data Endpoint endpoint payloads.
  4. Develop the JSON schema for the Quarterly Apportioned Emissions Data Last Updated Endpoint endpoint payloads.
  5. Develop a CAMDBS API based on the CAMDBSP Facility Data Summary Data Endpoint endpoint described below.
  6. Develop an EASEY API that uses the CAMDBS API for the CAMDBSP Facility Data Summary Data Endpoint endpoint described below.
  7. Develop a CAMDBS API based on the CAMDBSP Facility Data Specific Data Endpoint endpoint described below.
  8. Develop an EASEY API that uses the CAMDBS API for the CAMDBSP Facility Data Specific Data Endpoint endpoint described below.
  9. Develop a EASEY API based on the Quarterly Apportioned Emissions Data Specific Data Endpoint endpoint described below.
  10. Develop a EASEY API based on the Quarterly Apportioned Emissions Data Last Updated Endpoint endpoint described below.

Notes

  1. Move NAICS codes from facility level to unit level.

CAMDBSP Facility Data

Summary Data Endpoint:

Specific Data Endpoint:

General Information

Use CAMDECMPSMD.RGGI_XML_QRY data to determine returned data.

_CDXUSER

COMPANY

PLANT

_PLANTPERSON (VW_RGGI_PLANT_PERSON)

PERSON

UNIT

_UNIT_BOILERTYPE

_UNIT_OPSTATUS

_UNITOWNER

_UNITPROGRAM

_PROGRAMPARAMETER

Tables that trigger last updated pull on ADD_DATE/UPDATE_DATE:

Quarterly Apportioned Emissions Data

Specific Data Endpoint:

Last Updated Endpoint:

General Information:

Answered Questions

Requirements Outstanding Issues and Questions

  1. The existing RGGI API provides the contact information for the DR/ADRs associated with the facility. The current plan for ECMPS 2.0 is to provide the CDX user ID in the API call and have RGGI query CDX for the contact information for the DR/ADR. This needs to be validated with the CDX folks. Note: we may need to move from CDX user ID to email address. Only include CDX User ID for authenticated calls and continue to provide the Person ID (Rep ID) to unauthenticated users.
  2. How much additional information should we add to the units described in facilities call? The approach we are taking here mimics what is supplied on the Certificate of Representation form. For now, do not add information beyond what RGGI needs.
  3. RGGI will require the concept of a lastUpdatedDateTime parameter on the both the facilities endpoint and the apportioned quarterly emissions endpoint. Explore feasibility of adding this parameter to the other emissions endpoints. Implement as specified in the requirements document except return the next last updated timestamp in the response header.

CAMD Questions

  1. The programCodeInfo input parameter, when selected, currently requires an exact match with the programCodeInfo in each data object instead of matching a program code in the data object. So does not filter to RGGI easily. Should we change this, create a new program selection, or let RGGI filter the data? This appears to work correctly. Check again.
  2. The Draft RGGI Requirements document proposes adding a lastUpdatedDateTime parameter to the "/facilities-mgmt/facilities" endpoint. ERG would typically implement a last-updated endpoint by returning the timestamp to use during the next call to the endpoint. Does CAMD have an issue with implementing a separate last-updated endpoint. If implemented as a separate endpoint, should the endpoint return full facility data or just facility summary information? Should the endpoint accept a Program Code parameter? Based on Dwayne's memory (not notes) CAMD preferred using a combined endpoint to return facility summary data, and another endpoint to return complete facility data.
  3. Does CAMD have any issues with having the Facility Details API call a CBS API to get CAMDBSP detailed facility data instead of pulling the tables into the Cloud DB? CAMD (Mike) is okay with the API called by RGGI will call a CBS API.

RGGI Questions from ERG

  1. The CAMD Business System currently stores NAICS codes at the unit level not the facility level. The RGGI facility web services return the max NAICS code from the RGGI units at the facility. Should the new facility API continue to return max value, or should it return all NAICS codes at the unit level? CAMD indicate to return NAICS at the unit level and inform RGGI about the change.
MaeganWood64 commented 1 year ago