11/* Add application_information */
2- INSERT INTO `application_information` (`id`, `kind`, `description`, `published`, `self_link_href`, `self_link_rel`, `up_link_href`, `up_link_rel`, `updated`, `uuid`, `authorizationServerAuthorizationEndpoint`, `authorizationServerRegistrationEndpoint`, `authorizationServerTokenEndpoint`, `authorizationServerUri`, `clientId`, `clientIdIssuedAt`, `clientName`, `clientSecret`, `clientSecretExpiresAt`, `clientUri`, `contacts`, `dataCustodianApplicationStatus`, `dataCustodianBulkRequestURI`, `dataCustodianDefaultBatchResource`, `dataCustodianDefaultSubscriptionResource`, `dataCustodianId`, `dataCustodianResourceEndpoint`, `dataCustodianThirdPartySelectionScreenURI`, `grantTypes`, `logoUri`, `policyUri`, `redirectUri`, `registrationAccessToken`, `registrationClientUri`, `responseTypes`, `softwareId`, `softwareVersion`, `thirdPartyApplicationDescription`, `thirdPartyApplicationName`, `thirdPartyApplicationStatus`, `thirdPartyApplicationType`, `thirdPartyApplicationUse`, `thirdPartyDataCustodianSelectionScreenURI`, `thirdPartyLoginScreenURI`, `thirdPartyNotifyUri`, `thirdPartyPhone`, `thirdPartyScopeSelectionScreenURI`, `thirdPartyUserPortalScreenURI`, `tokenEndpointAuthMethod`, `tosUri`, `dataCustodianScopeSelectionScreenURI`) VALUES
3- (1, 'DATA_CUSTODIAN_ADMIN', 'GreenButtonData.org Data Custodian Admin Application', '2014-01-02 05:00:00', '/espi/1_1/resource/DataCustodian/ApplicationInformation/1', 'self', '/espi/1_1/resource/DataCustodian/ApplicationInformation', 'up', '2014-01-02 05:00:00', '185C9C3F-5B4A-44A9-8959-3AE79E60A9F5', 'http://localhost:8080/DataCustodian/oauth/authorize', 'http://localhost:8080/DataCustodian/espi/1_1/register', 'http://localhost:8080/DataCustodian/oauth/token', 'http://localhost:8080/DataCustodian/', 'data_custodian_admin', 1403190000, 'Green Button DataCustodian Admin', 'secret', 0, 'http://localhost:8080/DataCustodian','
[email protected] ,
[email protected] ,
[email protected] ', '1', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Bulk', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Subscription', 'data_custodian', 'http://localhost:8080/DataCustodian/espi/1_1/resource', 'http://localhost:8080/DataCustodian/RetailCustomer/{retailCustomerId}/ThirdPartyList', 'client_credentials', NULL, NULL, NULL, NULL, NULL, 1, 'EnergyOS OpenESPI', '1.2', 'EnergyOS OpenESPI Example DataCustodian Admin', 'Data Custodian Admin (localhost)', '1', '1', '1', NULL, NULL, NULL, NULL, NULL, NULL, 'client_secret_basic', NULL, 'http://localhost:8080/DataCustodian/RetailCustomer/ScopeSelection'),
4- (2, 'THIRD_PARTY', 'GreenButtonData.org ThirdParty Application', '2014-01-02 05:00:00', '/espi/1_1/resource/DataCustodian/ApplicationInformation/2', 'self', '/espi/1_1/resource/DataCustodian/ApplicationInformation', 'up', '2014-01-02 05:00:00', 'AF6E8B03-0299-467E-972A-A883ECDCC575', 'http://localhost:8080/DataCustodian/oauth/authorize', 'http://localhost:8080/DataCustodian/espi/1_1/register', 'http://localhost:8080/DataCustodian/oauth/token', 'http://localhost:8080/DataCustodian/', 'third_party', 1403190000, 'Green Button Third Party', 'secret', 0, 'http://localhost:8081/ThirdParty', '
[email protected] ,
[email protected] ,
[email protected] ', '1', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Bulk', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Subscription', 'data_custodian', 'http://localhost:8080/DataCustodian/espi/1_1/resource', 'http://localhost:8080/DataCustodian/RetailCustomer/1/ThirdPartyList', 'client_credentials', 'http://localhost:8081/ThirdParty/resources/ico/favicon.png', NULL, 'http://localhost:8081/ThirdParty/espi/1_1/OAuthCallBack', 'd89bb056-0f02-4d47-9fd2-ec6a19ba8d0c', NULL, 1, 'EnergyOS OpenESPI Example Third Party', '1.2', 'EnergyOS OpenESPI Example Third Party', 'Third Party (localhost)', '1', '1', '1', 'http://localhost:8081/ThirdParty/RetailCustomer/{retailCustomerId}/DataCustodianList', 'http://localhost:8081/ThirdParty/login', 'http://localhost:8081/ThirdParty/espi/1_1/Notification', NULL, 'http://localhost:8081/ThirdParty/RetailCustomer/ScopeSelection', 'http://localhost:8081/ThirdParty', 'client_secret_basic', NULL, 'http://localhost:8080/DataCustodian/RetailCustomer/ScopeSelectionList'),
5- (3, 'UPLOAD_ADMIN', 'GreenButtonData.org MDM Upload Application', '2014-01-02 05:00:00', '/espi/1_1/resource/DataCustodian/ApplicationInformation/3', 'self', '/espi/1_1/resource/DataCustodian/ApplicationInformation', 'up', '2014-01-02 05:00:00', '185C9C3F-5B4A-44A9-8959-3AE79E60A9F7', 'http://localhost:8080/DataCustodian/oauth/authorize', 'http://localhost:8080/DataCustodian/espi/1_1/register', 'http://localhost:8080/DataCustodian/oauth/token', 'http://localhost:8080/DataCustodian/', 'upload_admin', 1403190000, 'Green Button DMD Upload Service', 'secret', 0, NULL, '
[email protected] ,
[email protected] ,
[email protected] ', '1', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Bulk', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Subscription', 'data_custodian', 'http://localhost:8080/DataCustodian/espi/1_1/resource', 'http://localhost:8080/DataCustodian/RetailCustomer/1/ThirdPartyList','client_credentials', NULL, NULL, NULL, NULL, NULL, 1, 'EnergyOS OpenESPI DMD Upload Service', '1.2', 'EnergyOS OpenESPI DMD Upload Service', 'MDM Upload (localhost)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'client_secret_basic', NULL, NULL);
2+ INSERT INTO `application_information` (`id`, `kind`, `description`, `published`, `self_link_href`, `self_link_rel`, `up_link_href`, `up_link_rel`, `updated`, `uuid`, `authorizationServerAuthorizationEndpoint`, `authorizationServerRegistrationEndpoint`, `authorizationServerTokenEndpoint`, `authorizationServerUri`, `clientId`, `clientIdIssuedAt`, `clientName`, `clientSecret`, `clientSecretExpiresAt`, `clientUri`, `contacts`, `dataCustodianApplicationStatus`, `dataCustodianBulkRequestURI`, `dataCustodianDefaultBatchResource`, `dataCustodianDefaultSubscriptionResource`, `dataCustodianId`, `dataCustodianResourceEndpoint`, `dataCustodianThirdPartySelectionScreenURI`, `logoUri`, `policyUri`, `redirectUri`, `registrationAccessToken`, `registrationClientUri`, `responseTypes`, `softwareId`, `softwareVersion`, `thirdPartyApplicationDescription`, `thirdPartyApplicationName`, `thirdPartyApplicationStatus`, `thirdPartyApplicationType`, `thirdPartyApplicationUse`, `thirdPartyDataCustodianSelectionScreenURI`, `thirdPartyLoginScreenURI`, `thirdPartyNotifyUri`, `thirdPartyPhone`, `thirdPartyScopeSelectionScreenURI`, `thirdPartyUserPortalScreenURI`, `tokenEndpointAuthMethod`, `tosUri`, `dataCustodianScopeSelectionScreenURI`) VALUES
3+ (1, 'DATA_CUSTODIAN_ADMIN', 'GreenButtonData.org Data Custodian Admin Application', '2014-01-02 05:00:00', '/espi/1_1/resource/DataCustodian/ApplicationInformation/1', 'self', '/espi/1_1/resource/DataCustodian/ApplicationInformation', 'up', '2014-01-02 05:00:00', '185C9C3F-5B4A-44A9-8959-3AE79E60A9F5', 'http://localhost:8080/DataCustodian/oauth/authorize', 'http://localhost:8080/DataCustodian/espi/1_1/register', 'http://localhost:8080/DataCustodian/oauth/token', 'http://localhost:8080/DataCustodian/', 'data_custodian_admin', 1403190000, 'Green Button DataCustodian Admin', 'secret', 0, 'http://localhost:8080/DataCustodian','
[email protected] ,
[email protected] ,
[email protected] ', '1', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Bulk', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Subscription', 'data_custodian', 'http://localhost:8080/DataCustodian/espi/1_1/resource', 'http://localhost:8080/DataCustodian/RetailCustomer/{retailCustomerId}/ThirdPartyList', NULL, NULL, NULL, NULL, NULL, 1, 'EnergyOS OpenESPI', '1.2', 'EnergyOS OpenESPI Example DataCustodian Admin', 'Data Custodian Admin (localhost)', '1', '1', '1', NULL, NULL, NULL, NULL, NULL, NULL, 'client_secret_basic', NULL, 'http://localhost:8080/DataCustodian/RetailCustomer/ScopeSelection'),
4+ (2, 'THIRD_PARTY', 'GreenButtonData.org ThirdParty Application', '2014-01-02 05:00:00', '/espi/1_1/resource/DataCustodian/ApplicationInformation/2', 'self', '/espi/1_1/resource/DataCustodian/ApplicationInformation', 'up', '2014-01-02 05:00:00', 'AF6E8B03-0299-467E-972A-A883ECDCC575', 'http://localhost:8080/DataCustodian/oauth/authorize', 'http://localhost:8080/DataCustodian/espi/1_1/register', 'http://localhost:8080/DataCustodian/oauth/token', 'http://localhost:8080/DataCustodian/', 'third_party', 1403190000, 'Green Button Third Party', 'secret', 0, 'http://localhost:8081/ThirdParty', '
[email protected] ,
[email protected] ,
[email protected] ', '1', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Bulk', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Subscription', 'data_custodian', 'http://localhost:8080/DataCustodian/espi/1_1/resource', 'http://localhost:8080/DataCustodian/RetailCustomer/1/ThirdPartyList', 'http://localhost:8081/ThirdParty/resources/ico/favicon.png', NULL, 'http://localhost:8081/ThirdParty/espi/1_1/OAuthCallBack', 'd89bb056-0f02-4d47-9fd2-ec6a19ba8d0c', NULL, 1, 'EnergyOS OpenESPI Example Third Party', '1.2', 'EnergyOS OpenESPI Example Third Party', 'Third Party (localhost)', '1', '1', '1', 'http://localhost:8081/ThirdParty/RetailCustomer/{retailCustomerId}/DataCustodianList', 'http://localhost:8081/ThirdParty/login', 'http://localhost:8081/ThirdParty/espi/1_1/Notification', NULL, 'http://localhost:8081/ThirdParty/RetailCustomer/ScopeSelection', 'http://localhost:8081/ThirdParty', 'client_secret_basic', NULL, 'http://localhost:8080/DataCustodian/RetailCustomer/ScopeSelectionList'),
5+ (3, 'UPLOAD_ADMIN', 'GreenButtonData.org MDM Upload Application', '2014-01-02 05:00:00', '/espi/1_1/resource/DataCustodian/ApplicationInformation/3', 'self', '/espi/1_1/resource/DataCustodian/ApplicationInformation', 'up', '2014-01-02 05:00:00', '185C9C3F-5B4A-44A9-8959-3AE79E60A9F7', 'http://localhost:8080/DataCustodian/oauth/authorize', 'http://localhost:8080/DataCustodian/espi/1_1/register', 'http://localhost:8080/DataCustodian/oauth/token', 'http://localhost:8080/DataCustodian/', 'upload_admin', 1403190000, 'Green Button DMD Upload Service', 'secret', 0, NULL, '
[email protected] ,
[email protected] ,
[email protected] ', '1', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Bulk', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch', 'http://localhost:8080/DataCustodian/espi/1_1/resource/Batch/Subscription', 'data_custodian', 'http://localhost:8080/DataCustodian/espi/1_1/resource', 'http://localhost:8080/DataCustodian/RetailCustomer/1/ThirdPartyList', NULL, NULL, NULL, NULL, NULL, 1, 'EnergyOS OpenESPI DMD Upload Service', '1.2', 'EnergyOS OpenESPI DMD Upload Service', 'MDM Upload (localhost)', NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, NULL, 'client_secret_basic', NULL, NULL);
66
77/* Add application_information_scopes */
88INSERT INTO application_information_scopes (application_information_id, scope) VALUES (1 , ' FB=1_3_4_5_13_14_19_32_33_34_35_36_37_38_41_44_45' );
@@ -12,6 +12,12 @@ INSERT INTO application_information_scopes (application_information_id, scope) V
1212INSERT INTO application_information_scopes (application_information_id, scope) VALUES (2 , ' FB=1_3_4_5_6_7_8_9_10_11_29_12_13_14_15_16_17_18_19_27_28_32_33_34_35_37_38_39_40_41_44;IntervalDuration=3600;BlockDuration=monthly;HistoryLength=13' );
1313INSERT INTO application_information_scopes (application_information_id, scope) VALUES (3 , ' FB=45' );
1414
15+ /* Add application_information_grant_types */
16+ INSERT INTO application_information_grant_types (application_information_id, grantTypes) VALUES (1 , ' CLIENT_CREDENTIALS' );
17+ INSERT INTO application_information_grant_types (application_information_id, grantTypes) VALUES (2 , ' AUTHORIZATION_CODE' );
18+ INSERT INTO application_information_grant_types (application_information_id, grantTypes) VALUES (2 , ' REFRESH_TOKEN' );
19+ INSERT INTO application_information_grant_types (application_information_id, grantTypes) VALUES (3 , ' CLIENT_CREDENTIALS' );
20+
1521/* Add predefined authorizations */
1622INSERT INTO authorizations (id, description, published, self_link_href, self_link_rel, up_link_href, up_link_rel, updated, uuid, access_token, authorization_uri, ap_duration, ap_start, code, error, errorDescription, errorUri, expiresIn, grantType, pp_duration, pp_start, refreshToken, resourceURI, responseType, scope, state, status, third_party, tokenType, application_information_id, retail_customer_id, subscription_id)
1723VALUES (1 ,NULL ,' 2014-05-12 09:02:03' ,NULL ,' self' ,NULL ,' up' ,' 2014-05-12 09:02:03' ,' 558EBD17-FD1D-435D-8F8D-1D9A129EE1A6' ,' 688b026c-665f-4994-9139-6b21b13fbeee' ,' http://localhost:8080/DataCustodian/espi/1_1/resource/Authorization/1' ,0 ,0 ,NULL ,NULL ,NULL ,NULL ,31536000 ,NULL ,0 ,0 ,NULL ,' http://localhost:8080/DataCustodian/espi/1_1/resource/' ,NULL ,' DataCustodian_Admin_Access' ,NULL ,' 1' ,' data_custodian_admin' ,0 ,1 ,0 ,1 );
0 commit comments