diff --git a/openapi/components/responses/AtomEntry_Customer.yaml b/openapi/components/responses/AtomEntry_Customer.yaml index 00164f5..c2287ad 100644 --- a/openapi/components/responses/AtomEntry_Customer.yaml +++ b/openapi/components/responses/AtomEntry_Customer.yaml @@ -9,18 +9,30 @@ content: summary: A single Customer entry value: | - urn:uuid:c8e5f2d9-3a7b-5e4c-9d1f-6b8a2c3e5d7f - - - + urn:uuid:6c6d986b-bae0-54c9-b20c-f63b5fa9de56 + + + + Customer - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:19.660350Z + 2023-10-20T17:57:21.627755Z - 0 - en_US - John Smith + + + + 200 SECOND AVE + + + OLDCASTLE + ON + + N9V 2T7 + + + other + JOHN DOE diff --git a/openapi/components/responses/AtomEntry_CustomerAccount.yaml b/openapi/components/responses/AtomEntry_CustomerAccount.yaml index 857421f..cb09ff0 100644 --- a/openapi/components/responses/AtomEntry_CustomerAccount.yaml +++ b/openapi/components/responses/AtomEntry_CustomerAccount.yaml @@ -9,17 +9,29 @@ content: summary: A single CustomerAccount entry value: | - urn:uuid:e3f7b9d1-5c8a-6e4d-9f2b-7a1c5e8d3f6b - - - + urn:uuid:118b34f4-64ab-5242-8ec9-bd2c6c2ae002 + + + + CustomerAccount - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:19.660350Z + 2023-10-20T17:57:21.627755Z - 15 - ACC-123456 + + + + 200 SECOND AVE + + + OLDCASTLE + ON + + N9V 2T7 + + + 30000000-00 diff --git a/openapi/components/responses/AtomEntry_CustomerAgreement.yaml b/openapi/components/responses/AtomEntry_CustomerAgreement.yaml index 1c3657c..e6498f2 100644 --- a/openapi/components/responses/AtomEntry_CustomerAgreement.yaml +++ b/openapi/components/responses/AtomEntry_CustomerAgreement.yaml @@ -9,17 +9,19 @@ content: summary: A single CustomerAgreement entry value: | - urn:uuid:a9f3c5e8-7b6d-5e4c-9f2a-8d1c6e5b3a7f - - - + urn:uuid:b4d2b756-7442-558e-bfb2-5c3288e92f04 + + + + + + CustomerAgreement - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - 840 - AGR-789012 + 30000000-00_004_electric diff --git a/openapi/components/responses/AtomEntry_EndDevice.yaml b/openapi/components/responses/AtomEntry_EndDevice.yaml index 0cc373a..054ada8 100644 --- a/openapi/components/responses/AtomEntry_EndDevice.yaml +++ b/openapi/components/responses/AtomEntry_EndDevice.yaml @@ -9,16 +9,16 @@ content: summary: A single EndDevice entry value: | - urn:uuid:e9f5d3c8-6b7a-5e4d-9f2c-7a1d6e5b8c3f - - + urn:uuid:73a40799-2c91-5a15-a561-25102c959fcd + + + EndDevice - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - false - false + inverter-01-51111111111 diff --git a/openapi/components/responses/AtomEntry_Meter.yaml b/openapi/components/responses/AtomEntry_Meter.yaml index 06e96fd..80bc2c6 100644 --- a/openapi/components/responses/AtomEntry_Meter.yaml +++ b/openapi/components/responses/AtomEntry_Meter.yaml @@ -9,16 +9,16 @@ content: summary: A single Meter entry value: | - urn:uuid:a8f7e6d5-9c8b-5e4d-9f2a-7d1c6e5b8a3f - - + urn:uuid:aba939ae-5ce7-5393-bcfe-cceaa298424b + + + Meter - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - 16S - 900 + EPP00004 diff --git a/openapi/components/responses/AtomEntry_ProgramDateIdMappings.yaml b/openapi/components/responses/AtomEntry_ProgramDateIdMappings.yaml index 3be466f..05b0041 100644 --- a/openapi/components/responses/AtomEntry_ProgramDateIdMappings.yaml +++ b/openapi/components/responses/AtomEntry_ProgramDateIdMappings.yaml @@ -9,14 +9,20 @@ content: summary: A single ProgramDateIdMappings entry value: | - urn:uuid:f8e9d6c7-5b4a-5e4d-9f2c-7a1d6e5b8c3f - - + urn:uuid:913830f7-e2e4-5dc2-8264-3dd7ab3cf316 + + + ProgramDateIdMappings - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z + + CUST_DR_PROGRAM_ENROLLMENT_DATE + DR-01 + DR Enrollment + diff --git a/openapi/components/responses/AtomEntry_ServiceLocation.yaml b/openapi/components/responses/AtomEntry_ServiceLocation.yaml index fbb5909..2037d6c 100644 --- a/openapi/components/responses/AtomEntry_ServiceLocation.yaml +++ b/openapi/components/responses/AtomEntry_ServiceLocation.yaml @@ -9,16 +9,31 @@ content: summary: A single ServiceLocation entry value: | - urn:uuid:c7f9e5d2-8a6b-5e4c-9f3a-7d1c6e5b8a2f - - - + urn:uuid:fce8847d-4dac-5019-9d72-a2b756ac55b6 + + + + + + ServiceLocation - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - false + + + 200 SECOND AVE + + + OLDCASTLE + ON + + N9V 2T7 + + + https://data.greenbuttonconnect.org/DataCustodian/espi/1_1/resource/Subscription/407607/UsagePoint/1455265 + diff --git a/openapi/components/responses/AtomEntry_ServiceSupplier.yaml b/openapi/components/responses/AtomEntry_ServiceSupplier.yaml index 3aae824..f787879 100644 --- a/openapi/components/responses/AtomEntry_ServiceSupplier.yaml +++ b/openapi/components/responses/AtomEntry_ServiceSupplier.yaml @@ -9,15 +9,19 @@ content: summary: A single ServiceSupplier entry value: | - urn:uuid:c8f9e6d5-7b6a-5e4c-9f2d-8a1c6e5b7a3f - - + urn:uuid:fe8d9d03-6c2e-5b6a-b6c2-4d19f11cc830 + + + ServiceSupplier - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - 0 + + Acme Energy Supplier + + retailer diff --git a/openapi/components/responses/AtomFeed_Customer.yaml b/openapi/components/responses/AtomFeed_Customer.yaml index 0a0a593..d328bc2 100644 --- a/openapi/components/responses/AtomFeed_Customer.yaml +++ b/openapi/components/responses/AtomFeed_Customer.yaml @@ -10,22 +10,34 @@ content: value: | urn:uuid:b47f3a45-8d21-5c19-a3d2-7f1e4b9c6a08 - + Customer - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:c8e5f2d9-3a7b-5e4c-9d1f-6b8a2c3e5d7f - - - + urn:uuid:6c6d986b-bae0-54c9-b20c-f63b5fa9de56 + + + + Customer - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:19.660350Z + 2023-10-20T17:57:21.627755Z - 0 - en_US - John Smith + + + + 200 SECOND AVE + + + OLDCASTLE + ON + + N9V 2T7 + + + other + JOHN DOE diff --git a/openapi/components/responses/AtomFeed_CustomerAccount.yaml b/openapi/components/responses/AtomFeed_CustomerAccount.yaml index 59839c9..cb1d94f 100644 --- a/openapi/components/responses/AtomFeed_CustomerAccount.yaml +++ b/openapi/components/responses/AtomFeed_CustomerAccount.yaml @@ -10,21 +10,33 @@ content: value: | urn:uuid:d5a9c8f2-4e6b-5d7a-8c3e-1f9b6a5d8c2e - + CustomerAccount - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:e3f7b9d1-5c8a-6e4d-9f2b-7a1c5e8d3f6b - - - + urn:uuid:118b34f4-64ab-5242-8ec9-bd2c6c2ae002 + + + + CustomerAccount - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:19.660350Z + 2023-10-20T17:57:21.627755Z - 15 - ACC-123456 + + + + 200 SECOND AVE + + + OLDCASTLE + ON + + N9V 2T7 + + + 30000000-00 diff --git a/openapi/components/responses/AtomFeed_CustomerAgreement.yaml b/openapi/components/responses/AtomFeed_CustomerAgreement.yaml index f84a938..882f380 100644 --- a/openapi/components/responses/AtomFeed_CustomerAgreement.yaml +++ b/openapi/components/responses/AtomFeed_CustomerAgreement.yaml @@ -10,21 +10,23 @@ content: value: | urn:uuid:f2d8c9e5-6a7b-5c4d-8e3f-9b1a6c5d8e2f - + CustomerAgreement - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:a9f3c5e8-7b6d-5e4c-9f2a-8d1c6e5b3a7f - - - + urn:uuid:b4d2b756-7442-558e-bfb2-5c3288e92f04 + + + + + + CustomerAgreement - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - 840 - AGR-789012 + 30000000-00_004_electric diff --git a/openapi/components/responses/AtomFeed_EndDevice.yaml b/openapi/components/responses/AtomFeed_EndDevice.yaml index b963eec..bf6d698 100644 --- a/openapi/components/responses/AtomFeed_EndDevice.yaml +++ b/openapi/components/responses/AtomFeed_EndDevice.yaml @@ -10,20 +10,20 @@ content: value: | urn:uuid:d8e9f5c3-7a6b-5e4d-9f2c-8a1d6e5c8b3f - + EndDevice - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:e9f5d3c8-6b7a-5e4d-9f2c-7a1d6e5b8c3f - - + urn:uuid:73a40799-2c91-5a15-a561-25102c959fcd + + + EndDevice - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - false - false + inverter-01-51111111111 diff --git a/openapi/components/responses/AtomFeed_Meter.yaml b/openapi/components/responses/AtomFeed_Meter.yaml index 0b038fa..621d426 100644 --- a/openapi/components/responses/AtomFeed_Meter.yaml +++ b/openapi/components/responses/AtomFeed_Meter.yaml @@ -10,20 +10,20 @@ content: value: | urn:uuid:f9e6d4c8-7b6a-5e4d-9f2c-8a1d6e5c7b3f - + Meter - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:a8f7e6d5-9c8b-5e4d-9f2a-7d1c6e5b8a3f - - + urn:uuid:aba939ae-5ce7-5393-bcfe-cceaa298424b + + + Meter - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - 16S - 900 + EPP00004 diff --git a/openapi/components/responses/AtomFeed_ProgramDateIdMappings.yaml b/openapi/components/responses/AtomFeed_ProgramDateIdMappings.yaml index eabeae7..3498882 100644 --- a/openapi/components/responses/AtomFeed_ProgramDateIdMappings.yaml +++ b/openapi/components/responses/AtomFeed_ProgramDateIdMappings.yaml @@ -10,18 +10,24 @@ content: value: | urn:uuid:e9f7d5c8-6b5a-5e4d-9f2c-8a1d6e5c7b3f - + ProgramDateIdMappings - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:f8e9d6c7-5b4a-5e4d-9f2c-7a1d6e5b8c3f - - + urn:uuid:913830f7-e2e4-5dc2-8264-3dd7ab3cf316 + + + ProgramDateIdMappings - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z + + CUST_DR_PROGRAM_ENROLLMENT_DATE + DR-01 + DR Enrollment + diff --git a/openapi/components/responses/AtomFeed_ServiceLocation.yaml b/openapi/components/responses/AtomFeed_ServiceLocation.yaml index c156d79..657bf7d 100644 --- a/openapi/components/responses/AtomFeed_ServiceLocation.yaml +++ b/openapi/components/responses/AtomFeed_ServiceLocation.yaml @@ -10,20 +10,35 @@ content: value: | urn:uuid:b5e8f3c9-6d7a-5c4e-8f2b-9a1c6d5e8b3f - + ServiceLocation - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:c7f9e5d2-8a6b-5e4c-9f3a-7d1c6e5b8a2f - - - + urn:uuid:fce8847d-4dac-5019-9d72-a2b756ac55b6 + + + + + + ServiceLocation - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - false + + + 200 SECOND AVE + + + OLDCASTLE + ON + + N9V 2T7 + + + https://data.greenbuttonconnect.org/DataCustodian/espi/1_1/resource/Subscription/407607/UsagePoint/1455265 + diff --git a/openapi/components/responses/AtomFeed_ServiceSupplier.yaml b/openapi/components/responses/AtomFeed_ServiceSupplier.yaml index dd24683..a75f0e3 100644 --- a/openapi/components/responses/AtomFeed_ServiceSupplier.yaml +++ b/openapi/components/responses/AtomFeed_ServiceSupplier.yaml @@ -10,19 +10,23 @@ content: value: | urn:uuid:b9e7f5d4-8c6a-5e4d-9f2b-7a1c6e5d8b3f - + ServiceSupplier - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:57:21.627755Z - urn:uuid:c8f9e6d5-7b6a-5e4c-9f2d-8a1c6e5b7a3f - - + urn:uuid:fe8d9d03-6c2e-5b6a-b6c2-4d19f11cc830 + + + ServiceSupplier - 2023-10-20T17:32:35.448812Z - 2023-10-20T17:33:23.054424Z + 2023-10-20T17:56:20.594174Z + 2023-10-20T17:57:21.627755Z - 0 + + Acme Energy Supplier + + retailer diff --git a/openapi/openapi.yaml b/openapi/openapi.yaml index 6e643f8..96dccdd 100644 --- a/openapi/openapi.yaml +++ b/openapi/openapi.yaml @@ -280,18 +280,74 @@ components: type: oauth2 description: >- OAuth 2.0 authorization for accessing Green Button ESPI resources. - Supports both Authorization Code flow (for customer-authorized access) - and Client Credentials flow (for Data Custodian administrative access). + + + **Supported Flows:** + + - **Authorization Code** - Used by Third Party Applications to access + customer-authorized resources + + - **Client Credentials** - Used by Data Custodians for administrative + access to all resources + + + **Function Blocks (Scopes):** + + The Green Button API uses ESPI Function Blocks to define access scopes. + Function blocks are specified in the format `FB=X_Y_Z` where each number + represents a specific capability: + + - FB_1: Provide Subscription + + - FB_3: Provide Usage Point List + + - FB_4: Provide Usage Point + + - FB_5: Provide Reading Type + + - FB_8: Provide Meter Reading + + - FB_13: Provide Interval Block + + - FB_14: Provide Electric Power Quality Summary + + - FB_15: Provide Electric Power Usage Summary + + - FB_18: Provide Local Time Parameters + + - FB_19: Provide Application Information + + - FB_31: Provide Authorization + + - FB_32: Provide Service Status + + - FB_33: Provide Usage Points (Data Custodian) + + - FB_34: Provide Batch Subscription + + - FB_35: Provide Batch Bulk + + - FB_37: Provide Batch RetailCustomer UsagePoint + + - FB_39: Provide Batch Subscription UsagePoint + + - FB_50-58: Provide Customer Resources flows: authorizationCode: authorizationUrl: https://sandbox.greenbuttonalliance.org:8443/DataCustodian/oauth/authorize tokenUrl: https://sandbox.greenbuttonalliance.org:8443/DataCustodian/oauth/token scopes: - 'FB=1_3_4_5_8_13_14_15_18_19_31_32_33_34_35_37_39': Full Green Button scope + 'FB=1_3_4_5_8_13_14_15_18_19_31_32_33_34_35_37_39_50_51_52_53_54_55_56_57_58': Full Green Button scope with customer resources + 'FB=1_3_4_5_8_13_14_15_18_19_31_32_33_34_35_37_39': Full Green Button scope (energy only) + 'FB=4_5_8_13_14_15': Usage data and summaries + 'FB=50_51_52_53_54_55_56_57_58': Customer and billing data clientCredentials: tokenUrl: https://sandbox.greenbuttonalliance.org:8443/DataCustodian/oauth/token scopes: - 'FB=1_3_4_5_8_13_14_15_18_19_31_32_33_34_35_37_39': Full Green Button scope + 'FB=1_3_4_5_8_13_14_15_18_19_31_32_33_34_35_37_39_50_51_52_53_54_55_56_57_58': Full Green Button scope with customer resources + 'FB=1_3_4_5_8_13_14_15_18_19_31_32_33_34_35_37_39': Full Green Button scope (energy only) + 'FB=4_5_8_13_14_15': Usage data and summaries + 'FB=50_51_52_53_54_55_56_57_58': Customer and billing data parameters: published-max: $ref: 'components/parameters/published-max.yaml' @@ -360,6 +416,52 @@ components: $ref: 'components/schemas/Statement.yaml' ProgramDateIdMappings: $ref: 'components/schemas/ProgramDateIdMappings.yaml' + Organisation: + $ref: 'components/schemas/Organisation.yaml' + StreetAddress: + $ref: 'components/schemas/StreetAddress.yaml' + StreetDetail: + $ref: 'components/schemas/StreetDetail.yaml' + TownDetail: + $ref: 'components/schemas/TownDetail.yaml' + TelephoneNumber: + $ref: 'components/schemas/TelephoneNumber.yaml' + ElectronicAddress: + $ref: 'components/schemas/ElectronicAddress.yaml' + Document: + $ref: 'components/schemas/Document.yaml' + Agreement: + $ref: 'components/schemas/Agreement.yaml' + Asset: + $ref: 'components/schemas/Asset.yaml' + Location: + $ref: 'components/schemas/Location.yaml' + PositionPoint: + $ref: 'components/schemas/PositionPoint.yaml' + Status: + $ref: 'components/schemas/Status.yaml' + Priority: + $ref: 'components/schemas/Priority.yaml' + LifecycleDate: + $ref: 'components/schemas/LifecycleDate.yaml' + AcceptanceTest: + $ref: 'components/schemas/AcceptanceTest.yaml' + MeterMultiplier: + $ref: 'components/schemas/MeterMultiplier.yaml' + AccountNotification: + $ref: 'components/schemas/AccountNotification.yaml' + DemandResponseProgram: + $ref: 'components/schemas/DemandResponseProgram.yaml' + ProgramDate: + $ref: 'components/schemas/ProgramDate.yaml' + ProgramDateIdMapping: + $ref: 'components/schemas/ProgramDateIdMapping.yaml' + StatementRef: + $ref: 'components/schemas/StatementRef.yaml' + PricingStructure: + $ref: 'components/schemas/PricingStructure.yaml' + BatchItemInfo: + $ref: 'components/schemas/BatchItemInfo.yaml' responses: AtomFeed: $ref: 'components/responses/AtomFeed.yaml'