@greensecurity/javascript-sdk 0.40.8-beta.3 → 0.40.8-beta.31
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/.devcontainer/README.md +35 -0
- package/README.md +14 -5
- package/dist/commonjs/__tests__/alerts.test.d.ts +2 -0
- package/dist/commonjs/__tests__/alerts.test.d.ts.map +1 -0
- package/dist/commonjs/__tests__/alerts.test.js +51 -0
- package/dist/commonjs/__tests__/alerts.test.js.map +1 -0
- package/dist/commonjs/__tests__/vendors.test.js +25 -0
- package/dist/commonjs/__tests__/vendors.test.js.map +1 -1
- package/dist/commonjs/__tests__/zones.test.js +3 -2
- package/dist/commonjs/__tests__/zones.test.js.map +1 -1
- package/dist/commonjs/admin-funcs/registerCompanies.d.ts +16 -0
- package/dist/commonjs/admin-funcs/registerCompanies.d.ts.map +1 -0
- package/dist/commonjs/admin-funcs/registerCompanies.js +9 -0
- package/dist/commonjs/admin-funcs/registerCompanies.js.map +1 -0
- package/dist/commonjs/admin-funcs/registerEmail.d.ts +9 -0
- package/dist/commonjs/admin-funcs/registerEmail.d.ts.map +1 -0
- package/dist/commonjs/admin-funcs/registerEmail.js +9 -0
- package/dist/commonjs/admin-funcs/registerEmail.js.map +1 -0
- package/dist/commonjs/admin-funcs/registerGeneralInfo.d.ts +23 -0
- package/dist/commonjs/admin-funcs/registerGeneralInfo.d.ts.map +1 -0
- package/dist/commonjs/admin-funcs/registerGeneralInfo.js +9 -0
- package/dist/commonjs/admin-funcs/registerGeneralInfo.js.map +1 -0
- package/dist/commonjs/admin-funcs/registerPassword.d.ts +7 -0
- package/dist/commonjs/admin-funcs/registerPassword.d.ts.map +1 -0
- package/dist/commonjs/admin-funcs/registerPassword.js +9 -0
- package/dist/commonjs/admin-funcs/registerPassword.js.map +1 -0
- package/dist/commonjs/funcs/alertsListAlerts.d.ts +21 -0
- package/dist/commonjs/funcs/alertsListAlerts.d.ts.map +1 -0
- package/dist/commonjs/funcs/alertsListAlerts.js +154 -0
- package/dist/commonjs/funcs/alertsListAlerts.js.map +1 -0
- package/dist/commonjs/funcs/alertsUpdateUserAlerts.d.ts +18 -0
- package/dist/commonjs/funcs/alertsUpdateUserAlerts.d.ts.map +1 -0
- package/dist/commonjs/funcs/alertsUpdateUserAlerts.js +117 -0
- package/dist/commonjs/funcs/alertsUpdateUserAlerts.js.map +1 -0
- package/dist/commonjs/funcs/vendorsGetNextUnansweredScreeningQuestion.d.ts +18 -0
- package/dist/commonjs/funcs/vendorsGetNextUnansweredScreeningQuestion.d.ts.map +1 -0
- package/dist/commonjs/funcs/vendorsGetNextUnansweredScreeningQuestion.js +126 -0
- package/dist/commonjs/funcs/vendorsGetNextUnansweredScreeningQuestion.js.map +1 -0
- package/dist/commonjs/funcs/vendorsGetVendorsDetails.d.ts +1 -0
- package/dist/commonjs/funcs/vendorsGetVendorsDetails.d.ts.map +1 -1
- package/dist/commonjs/funcs/vendorsGetVendorsDetails.js +1 -0
- package/dist/commonjs/funcs/vendorsGetVendorsDetails.js.map +1 -1
- package/dist/commonjs/index.extras.d.ts +10 -0
- package/dist/commonjs/index.extras.d.ts.map +1 -1
- package/dist/commonjs/index.extras.js +10 -0
- package/dist/commonjs/index.extras.js.map +1 -1
- package/dist/commonjs/lib/config.d.ts +4 -4
- package/dist/commonjs/lib/config.js +4 -4
- package/dist/commonjs/lib/config.js.map +1 -1
- package/dist/commonjs/lib/url.js +1 -1
- package/dist/commonjs/lib/url.js.map +1 -1
- package/dist/commonjs/models/components/alert.d.ts +79 -0
- package/dist/commonjs/models/components/alert.d.ts.map +1 -0
- package/dist/commonjs/models/components/alert.js +123 -0
- package/dist/commonjs/models/components/alert.js.map +1 -0
- package/dist/commonjs/models/components/credential.d.ts +6 -4
- package/dist/commonjs/models/components/credential.d.ts.map +1 -1
- package/dist/commonjs/models/components/credential.js +8 -4
- package/dist/commonjs/models/components/credential.js.map +1 -1
- package/dist/commonjs/models/components/credentialstatus.d.ts +3 -0
- package/dist/commonjs/models/components/credentialstatus.d.ts.map +1 -1
- package/dist/commonjs/models/components/credentialstatus.js +1 -0
- package/dist/commonjs/models/components/credentialstatus.js.map +1 -1
- package/dist/commonjs/models/components/expand.d.ts +6 -0
- package/dist/commonjs/models/components/expand.d.ts.map +1 -1
- package/dist/commonjs/models/components/expand.js +2 -0
- package/dist/commonjs/models/components/expand.js.map +1 -1
- package/dist/commonjs/models/components/facilitycalendarsummary.d.ts +68 -0
- package/dist/commonjs/models/components/facilitycalendarsummary.d.ts.map +1 -0
- package/dist/commonjs/models/components/facilitycalendarsummary.js +130 -0
- package/dist/commonjs/models/components/facilitycalendarsummary.js.map +1 -0
- package/dist/commonjs/models/components/facilitysummary.d.ts +2 -0
- package/dist/commonjs/models/components/facilitysummary.d.ts.map +1 -1
- package/dist/commonjs/models/components/facilitysummary.js +4 -0
- package/dist/commonjs/models/components/facilitysummary.js.map +1 -1
- package/dist/commonjs/models/components/index.d.ts +4 -0
- package/dist/commonjs/models/components/index.d.ts.map +1 -1
- package/dist/commonjs/models/components/index.js +4 -0
- package/dist/commonjs/models/components/index.js.map +1 -1
- package/dist/commonjs/models/components/screeninganswer.d.ts +112 -0
- package/dist/commonjs/models/components/screeninganswer.d.ts.map +1 -0
- package/dist/commonjs/models/components/screeninganswer.js +138 -0
- package/dist/commonjs/models/components/screeninganswer.js.map +1 -0
- package/dist/commonjs/models/components/screeningquestion.d.ts +98 -0
- package/dist/commonjs/models/components/screeningquestion.d.ts.map +1 -0
- package/dist/commonjs/models/components/screeningquestion.js +125 -0
- package/dist/commonjs/models/components/screeningquestion.js.map +1 -0
- package/dist/commonjs/models/components/userlocation.d.ts +1 -5
- package/dist/commonjs/models/components/userlocation.d.ts.map +1 -1
- package/dist/commonjs/models/components/userlocation.js +2 -3
- package/dist/commonjs/models/components/userlocation.js.map +1 -1
- package/dist/commonjs/models/components/vendor.d.ts +7 -2
- package/dist/commonjs/models/components/vendor.d.ts.map +1 -1
- package/dist/commonjs/models/components/vendor.js +11 -2
- package/dist/commonjs/models/components/vendor.js.map +1 -1
- package/dist/commonjs/models/errors/index.d.ts +1 -0
- package/dist/commonjs/models/errors/index.d.ts.map +1 -1
- package/dist/commonjs/models/errors/index.js +1 -0
- package/dist/commonjs/models/errors/index.js.map +1 -1
- package/dist/commonjs/models/operations/getnextunansweredscreeningquestion.d.ts +70 -0
- package/dist/commonjs/models/operations/getnextunansweredscreeningquestion.d.ts.map +1 -0
- package/dist/commonjs/models/operations/getnextunansweredscreeningquestion.js +122 -0
- package/dist/commonjs/models/operations/getnextunansweredscreeningquestion.js.map +1 -0
- package/dist/commonjs/models/operations/index.d.ts +3 -0
- package/dist/commonjs/models/operations/index.d.ts.map +1 -1
- package/dist/commonjs/models/operations/index.js +3 -0
- package/dist/commonjs/models/operations/index.js.map +1 -1
- package/dist/commonjs/models/operations/listalerts.d.ts +106 -0
- package/dist/commonjs/models/operations/listalerts.d.ts.map +1 -0
- package/dist/commonjs/models/operations/listalerts.js +149 -0
- package/dist/commonjs/models/operations/listalerts.js.map +1 -0
- package/dist/commonjs/models/operations/listvendorcredentials.d.ts +4 -4
- package/dist/commonjs/models/operations/listvendorcredentials.d.ts.map +1 -1
- package/dist/commonjs/models/operations/listvendorcredentials.js +4 -4
- package/dist/commonjs/models/operations/listvendorcredentials.js.map +1 -1
- package/dist/commonjs/models/operations/updateuseralerts.d.ts +57 -0
- package/dist/commonjs/models/operations/updateuseralerts.d.ts.map +1 -0
- package/dist/commonjs/models/operations/updateuseralerts.js +105 -0
- package/dist/commonjs/models/operations/updateuseralerts.js.map +1 -0
- package/dist/commonjs/react-query/alertsListAlerts.d.ts +75 -0
- package/dist/commonjs/react-query/alertsListAlerts.d.ts.map +1 -0
- package/dist/commonjs/react-query/alertsListAlerts.js +150 -0
- package/dist/commonjs/react-query/alertsListAlerts.js.map +1 -0
- package/dist/commonjs/react-query/alertsUpdateUserAlerts.d.ts +23 -0
- package/dist/commonjs/react-query/alertsUpdateUserAlerts.d.ts.map +1 -0
- package/dist/commonjs/react-query/alertsUpdateUserAlerts.js +47 -0
- package/dist/commonjs/react-query/alertsUpdateUserAlerts.js.map +1 -0
- package/dist/commonjs/react-query/index.d.ts +3 -0
- package/dist/commonjs/react-query/index.d.ts.map +1 -1
- package/dist/commonjs/react-query/index.js +3 -0
- package/dist/commonjs/react-query/index.js.map +1 -1
- package/dist/commonjs/react-query/vendorsGetNextUnansweredScreeningQuestion.d.ts +43 -0
- package/dist/commonjs/react-query/vendorsGetNextUnansweredScreeningQuestion.d.ts.map +1 -0
- package/dist/commonjs/react-query/vendorsGetNextUnansweredScreeningQuestion.js +97 -0
- package/dist/commonjs/react-query/vendorsGetNextUnansweredScreeningQuestion.js.map +1 -0
- package/dist/commonjs/react-query/vendorsGetVendorsDetails.d.ts +2 -0
- package/dist/commonjs/react-query/vendorsGetVendorsDetails.d.ts.map +1 -1
- package/dist/commonjs/react-query/vendorsGetVendorsDetails.js +2 -0
- package/dist/commonjs/react-query/vendorsGetVendorsDetails.js.map +1 -1
- package/dist/commonjs/react-query/vendorsListVendorCredentials.d.ts +3 -3
- package/dist/commonjs/react-query/vendorsListVendorCredentials.d.ts.map +1 -1
- package/dist/commonjs/sdk/alerts.d.ts +22 -0
- package/dist/commonjs/sdk/alerts.d.ts.map +1 -0
- package/dist/commonjs/sdk/alerts.js +33 -0
- package/dist/commonjs/sdk/alerts.js.map +1 -0
- package/dist/commonjs/sdk/sdk.d.ts +3 -0
- package/dist/commonjs/sdk/sdk.d.ts.map +1 -1
- package/dist/commonjs/sdk/sdk.js +4 -0
- package/dist/commonjs/sdk/sdk.js.map +1 -1
- package/dist/commonjs/sdk/vendors.d.ts +8 -0
- package/dist/commonjs/sdk/vendors.d.ts.map +1 -1
- package/dist/commonjs/sdk/vendors.js +11 -0
- package/dist/commonjs/sdk/vendors.js.map +1 -1
- package/dist/esm/__tests__/alerts.test.d.ts +2 -0
- package/dist/esm/__tests__/alerts.test.d.ts.map +1 -0
- package/dist/esm/__tests__/alerts.test.js +49 -0
- package/dist/esm/__tests__/alerts.test.js.map +1 -0
- package/dist/esm/__tests__/vendors.test.js +25 -0
- package/dist/esm/__tests__/vendors.test.js.map +1 -1
- package/dist/esm/__tests__/zones.test.js +3 -2
- package/dist/esm/__tests__/zones.test.js.map +1 -1
- package/dist/esm/admin-funcs/registerCompanies.d.ts +16 -0
- package/dist/esm/admin-funcs/registerCompanies.d.ts.map +1 -0
- package/dist/esm/admin-funcs/registerCompanies.js +6 -0
- package/dist/esm/admin-funcs/registerCompanies.js.map +1 -0
- package/dist/esm/admin-funcs/registerEmail.d.ts +9 -0
- package/dist/esm/admin-funcs/registerEmail.d.ts.map +1 -0
- package/dist/esm/admin-funcs/registerEmail.js +6 -0
- package/dist/esm/admin-funcs/registerEmail.js.map +1 -0
- package/dist/esm/admin-funcs/registerGeneralInfo.d.ts +23 -0
- package/dist/esm/admin-funcs/registerGeneralInfo.d.ts.map +1 -0
- package/dist/esm/admin-funcs/registerGeneralInfo.js +6 -0
- package/dist/esm/admin-funcs/registerGeneralInfo.js.map +1 -0
- package/dist/esm/admin-funcs/registerPassword.d.ts +7 -0
- package/dist/esm/admin-funcs/registerPassword.d.ts.map +1 -0
- package/dist/esm/admin-funcs/registerPassword.js +6 -0
- package/dist/esm/admin-funcs/registerPassword.js.map +1 -0
- package/dist/esm/funcs/alertsListAlerts.d.ts +21 -0
- package/dist/esm/funcs/alertsListAlerts.d.ts.map +1 -0
- package/dist/esm/funcs/alertsListAlerts.js +118 -0
- package/dist/esm/funcs/alertsListAlerts.js.map +1 -0
- package/dist/esm/funcs/alertsUpdateUserAlerts.d.ts +18 -0
- package/dist/esm/funcs/alertsUpdateUserAlerts.d.ts.map +1 -0
- package/dist/esm/funcs/alertsUpdateUserAlerts.js +81 -0
- package/dist/esm/funcs/alertsUpdateUserAlerts.js.map +1 -0
- package/dist/esm/funcs/vendorsGetNextUnansweredScreeningQuestion.d.ts +18 -0
- package/dist/esm/funcs/vendorsGetNextUnansweredScreeningQuestion.d.ts.map +1 -0
- package/dist/esm/funcs/vendorsGetNextUnansweredScreeningQuestion.js +90 -0
- package/dist/esm/funcs/vendorsGetNextUnansweredScreeningQuestion.js.map +1 -0
- package/dist/esm/funcs/vendorsGetVendorsDetails.d.ts +1 -0
- package/dist/esm/funcs/vendorsGetVendorsDetails.d.ts.map +1 -1
- package/dist/esm/funcs/vendorsGetVendorsDetails.js +1 -0
- package/dist/esm/funcs/vendorsGetVendorsDetails.js.map +1 -1
- package/dist/esm/index.extras.d.ts +10 -0
- package/dist/esm/index.extras.d.ts.map +1 -1
- package/dist/esm/index.extras.js +10 -0
- package/dist/esm/index.extras.js.map +1 -1
- package/dist/esm/lib/config.d.ts +4 -4
- package/dist/esm/lib/config.js +4 -4
- package/dist/esm/lib/config.js.map +1 -1
- package/dist/esm/lib/url.js +1 -1
- package/dist/esm/lib/url.js.map +1 -1
- package/dist/esm/models/components/alert.d.ts +79 -0
- package/dist/esm/models/components/alert.d.ts.map +1 -0
- package/dist/esm/models/components/alert.js +85 -0
- package/dist/esm/models/components/alert.js.map +1 -0
- package/dist/esm/models/components/credential.d.ts +6 -4
- package/dist/esm/models/components/credential.d.ts.map +1 -1
- package/dist/esm/models/components/credential.js +8 -4
- package/dist/esm/models/components/credential.js.map +1 -1
- package/dist/esm/models/components/credentialstatus.d.ts +3 -0
- package/dist/esm/models/components/credentialstatus.d.ts.map +1 -1
- package/dist/esm/models/components/credentialstatus.js +1 -0
- package/dist/esm/models/components/credentialstatus.js.map +1 -1
- package/dist/esm/models/components/expand.d.ts +6 -0
- package/dist/esm/models/components/expand.d.ts.map +1 -1
- package/dist/esm/models/components/expand.js +2 -0
- package/dist/esm/models/components/expand.js.map +1 -1
- package/dist/esm/models/components/facilitycalendarsummary.d.ts +68 -0
- package/dist/esm/models/components/facilitycalendarsummary.d.ts.map +1 -0
- package/dist/esm/models/components/facilitycalendarsummary.js +90 -0
- package/dist/esm/models/components/facilitycalendarsummary.js.map +1 -0
- package/dist/esm/models/components/facilitysummary.d.ts +2 -0
- package/dist/esm/models/components/facilitysummary.d.ts.map +1 -1
- package/dist/esm/models/components/facilitysummary.js +4 -0
- package/dist/esm/models/components/facilitysummary.js.map +1 -1
- package/dist/esm/models/components/index.d.ts +4 -0
- package/dist/esm/models/components/index.d.ts.map +1 -1
- package/dist/esm/models/components/index.js +4 -0
- package/dist/esm/models/components/index.js.map +1 -1
- package/dist/esm/models/components/screeninganswer.d.ts +112 -0
- package/dist/esm/models/components/screeninganswer.d.ts.map +1 -0
- package/dist/esm/models/components/screeninganswer.js +100 -0
- package/dist/esm/models/components/screeninganswer.js.map +1 -0
- package/dist/esm/models/components/screeningquestion.d.ts +98 -0
- package/dist/esm/models/components/screeningquestion.d.ts.map +1 -0
- package/dist/esm/models/components/screeningquestion.js +87 -0
- package/dist/esm/models/components/screeningquestion.js.map +1 -0
- package/dist/esm/models/components/userlocation.d.ts +1 -5
- package/dist/esm/models/components/userlocation.d.ts.map +1 -1
- package/dist/esm/models/components/userlocation.js +2 -3
- package/dist/esm/models/components/userlocation.js.map +1 -1
- package/dist/esm/models/components/vendor.d.ts +7 -2
- package/dist/esm/models/components/vendor.d.ts.map +1 -1
- package/dist/esm/models/components/vendor.js +11 -2
- package/dist/esm/models/components/vendor.js.map +1 -1
- package/dist/esm/models/errors/index.d.ts +1 -0
- package/dist/esm/models/errors/index.d.ts.map +1 -1
- package/dist/esm/models/errors/index.js +1 -0
- package/dist/esm/models/errors/index.js.map +1 -1
- package/dist/esm/models/operations/getnextunansweredscreeningquestion.d.ts +70 -0
- package/dist/esm/models/operations/getnextunansweredscreeningquestion.d.ts.map +1 -0
- package/dist/esm/models/operations/getnextunansweredscreeningquestion.js +82 -0
- package/dist/esm/models/operations/getnextunansweredscreeningquestion.js.map +1 -0
- package/dist/esm/models/operations/index.d.ts +3 -0
- package/dist/esm/models/operations/index.d.ts.map +1 -1
- package/dist/esm/models/operations/index.js +3 -0
- package/dist/esm/models/operations/index.js.map +1 -1
- package/dist/esm/models/operations/listalerts.d.ts +106 -0
- package/dist/esm/models/operations/listalerts.d.ts.map +1 -0
- package/dist/esm/models/operations/listalerts.js +107 -0
- package/dist/esm/models/operations/listalerts.js.map +1 -0
- package/dist/esm/models/operations/listvendorcredentials.d.ts +4 -4
- package/dist/esm/models/operations/listvendorcredentials.d.ts.map +1 -1
- package/dist/esm/models/operations/listvendorcredentials.js +4 -4
- package/dist/esm/models/operations/listvendorcredentials.js.map +1 -1
- package/dist/esm/models/operations/updateuseralerts.d.ts +57 -0
- package/dist/esm/models/operations/updateuseralerts.d.ts.map +1 -0
- package/dist/esm/models/operations/updateuseralerts.js +65 -0
- package/dist/esm/models/operations/updateuseralerts.js.map +1 -0
- package/dist/esm/react-query/alertsListAlerts.d.ts +75 -0
- package/dist/esm/react-query/alertsListAlerts.d.ts.map +1 -0
- package/dist/esm/react-query/alertsListAlerts.js +137 -0
- package/dist/esm/react-query/alertsListAlerts.js.map +1 -0
- package/dist/esm/react-query/alertsUpdateUserAlerts.d.ts +23 -0
- package/dist/esm/react-query/alertsUpdateUserAlerts.d.ts.map +1 -0
- package/dist/esm/react-query/alertsUpdateUserAlerts.js +42 -0
- package/dist/esm/react-query/alertsUpdateUserAlerts.js.map +1 -0
- package/dist/esm/react-query/index.d.ts +3 -0
- package/dist/esm/react-query/index.d.ts.map +1 -1
- package/dist/esm/react-query/index.js +3 -0
- package/dist/esm/react-query/index.js.map +1 -1
- package/dist/esm/react-query/vendorsGetNextUnansweredScreeningQuestion.d.ts +43 -0
- package/dist/esm/react-query/vendorsGetNextUnansweredScreeningQuestion.d.ts.map +1 -0
- package/dist/esm/react-query/vendorsGetNextUnansweredScreeningQuestion.js +87 -0
- package/dist/esm/react-query/vendorsGetNextUnansweredScreeningQuestion.js.map +1 -0
- package/dist/esm/react-query/vendorsGetVendorsDetails.d.ts +2 -0
- package/dist/esm/react-query/vendorsGetVendorsDetails.d.ts.map +1 -1
- package/dist/esm/react-query/vendorsGetVendorsDetails.js +2 -0
- package/dist/esm/react-query/vendorsGetVendorsDetails.js.map +1 -1
- package/dist/esm/react-query/vendorsListVendorCredentials.d.ts +3 -3
- package/dist/esm/react-query/vendorsListVendorCredentials.d.ts.map +1 -1
- package/dist/esm/sdk/alerts.d.ts +22 -0
- package/dist/esm/sdk/alerts.d.ts.map +1 -0
- package/dist/esm/sdk/alerts.js +29 -0
- package/dist/esm/sdk/alerts.js.map +1 -0
- package/dist/esm/sdk/sdk.d.ts +3 -0
- package/dist/esm/sdk/sdk.d.ts.map +1 -1
- package/dist/esm/sdk/sdk.js +4 -0
- package/dist/esm/sdk/sdk.js.map +1 -1
- package/dist/esm/sdk/vendors.d.ts +8 -0
- package/dist/esm/sdk/vendors.d.ts.map +1 -1
- package/dist/esm/sdk/vendors.js +11 -0
- package/dist/esm/sdk/vendors.js.map +1 -1
- package/docs/sdks/alerts/README.md +219 -0
- package/docs/sdks/companies/README.md +126 -0
- package/docs/sdks/datarequests/README.md +302 -0
- package/docs/sdks/events/README.md +1126 -0
- package/docs/sdks/fhirconfigs/README.md +551 -0
- package/docs/sdks/greensecurity/README.md +14 -0
- package/docs/sdks/invoices/README.md +324 -0
- package/docs/sdks/mobiledevices/README.md +100 -0
- package/docs/sdks/organizations/README.md +508 -0
- package/docs/sdks/supportarticles/README.md +249 -0
- package/docs/sdks/systems/README.md +136 -0
- package/docs/sdks/users/README.md +831 -0
- package/docs/sdks/vendors/README.md +4904 -0
- package/docs/sdks/vendorscans/README.md +104 -0
- package/docs/sdks/webhooks/README.md +352 -0
- package/docs/sdks/zones/README.md +344 -0
- package/examples/README.md +31 -0
- package/examples/package-lock.json +1 -1
- package/examples/vendorsCreateVendorRegistration.example.ts +1 -1
- package/jsr.json +1 -1
- package/package.json +1 -1
- package/src/__tests__/alerts.test.ts +55 -0
- package/src/__tests__/vendors.test.ts +32 -0
- package/src/__tests__/zones.test.ts +3 -2
- package/src/admin-funcs/registerCompanies.ts +23 -0
- package/src/admin-funcs/registerEmail.ts +16 -0
- package/src/admin-funcs/registerGeneralInfo.ts +30 -0
- package/src/admin-funcs/registerPassword.ts +14 -0
- package/src/funcs/alertsListAlerts.ts +245 -0
- package/src/funcs/alertsUpdateUserAlerts.ts +170 -0
- package/src/funcs/vendorsGetNextUnansweredScreeningQuestion.ts +188 -0
- package/src/funcs/vendorsGetVendorsDetails.ts +1 -0
- package/src/index.extras.ts +14 -1
- package/src/lib/config.ts +4 -4
- package/src/lib/url.ts +1 -1
- package/src/models/components/alert.ts +141 -0
- package/src/models/components/credential.ts +19 -10
- package/src/models/components/credentialstatus.ts +1 -0
- package/src/models/components/expand.ts +2 -0
- package/src/models/components/facilitycalendarsummary.ts +188 -0
- package/src/models/components/facilitysummary.ts +6 -0
- package/src/models/components/index.ts +4 -0
- package/src/models/components/screeninganswer.ts +195 -0
- package/src/models/components/screeningquestion.ts +163 -0
- package/src/models/components/userlocation.ts +3 -7
- package/src/models/components/vendor.ts +25 -4
- package/src/models/errors/index.ts +1 -0
- package/src/models/operations/getnextunansweredscreeningquestion.ts +191 -0
- package/src/models/operations/index.ts +3 -0
- package/src/models/operations/listalerts.ts +234 -0
- package/src/models/operations/listvendorcredentials.ts +8 -10
- package/src/models/operations/updateuseralerts.ts +140 -0
- package/src/react-query/alertsListAlerts.ts +308 -0
- package/src/react-query/alertsUpdateUserAlerts.ts +89 -0
- package/src/react-query/index.ts +3 -0
- package/src/react-query/vendorsGetNextUnansweredScreeningQuestion.ts +190 -0
- package/src/react-query/vendorsGetVendorsDetails.ts +2 -0
- package/src/react-query/vendorsListVendorCredentials.ts +3 -3
- package/src/sdk/alerts.ts +46 -0
- package/src/sdk/sdk.ts +6 -0
- package/src/sdk/vendors.ts +19 -0
|
@@ -0,0 +1,508 @@
|
|
|
1
|
+
# Organizations
|
|
2
|
+
(*organizations*)
|
|
3
|
+
|
|
4
|
+
## Overview
|
|
5
|
+
|
|
6
|
+
Organizations includes `Hospital Systems` and their component parts (such as `Facilities`, `Zones` and `Departments`)
|
|
7
|
+
|
|
8
|
+
### Available Operations
|
|
9
|
+
|
|
10
|
+
* [listOrSearchFacilities](#listorsearchfacilities) - List or search facilities
|
|
11
|
+
* [getFacility](#getfacility) - Get facility
|
|
12
|
+
* [listOrSearchDepartments](#listorsearchdepartments) - List or search departments
|
|
13
|
+
* [listOrSearchDepartmentContacts](#listorsearchdepartmentcontacts) - List or search department contacts
|
|
14
|
+
|
|
15
|
+
## listOrSearchFacilities
|
|
16
|
+
|
|
17
|
+
List or search facilities.
|
|
18
|
+
|
|
19
|
+
Available `expand` scopes are:
|
|
20
|
+
|
|
21
|
+
- facility.appointment_policy
|
|
22
|
+
- facility.contacts
|
|
23
|
+
- facility.vendor_counts
|
|
24
|
+
- facility.flu_credential
|
|
25
|
+
- facility.scrubs_policy
|
|
26
|
+
- facility.system
|
|
27
|
+
- facility.vendor_guest_policy
|
|
28
|
+
- facility.vendor_policy
|
|
29
|
+
- facility.visitor_policy
|
|
30
|
+
- facility.workflow
|
|
31
|
+
|
|
32
|
+
### Example Usage
|
|
33
|
+
|
|
34
|
+
<!-- UsageSnippet language="typescript" operationID="listOrSearchFacilities" method="get" path="/facilities" -->
|
|
35
|
+
```typescript
|
|
36
|
+
import { GreenSecurity } from "@greensecurity/javascript-sdk";
|
|
37
|
+
|
|
38
|
+
const greenSecurity = new GreenSecurity({
|
|
39
|
+
security: {
|
|
40
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
41
|
+
},
|
|
42
|
+
});
|
|
43
|
+
|
|
44
|
+
async function run() {
|
|
45
|
+
const result = await greenSecurity.organizations.listOrSearchFacilities({
|
|
46
|
+
sort: "job",
|
|
47
|
+
desc: true,
|
|
48
|
+
itemsPerPage: 25,
|
|
49
|
+
expand: [
|
|
50
|
+
"facility.system",
|
|
51
|
+
],
|
|
52
|
+
});
|
|
53
|
+
|
|
54
|
+
for await (const page of result) {
|
|
55
|
+
console.log(page);
|
|
56
|
+
}
|
|
57
|
+
}
|
|
58
|
+
|
|
59
|
+
run();
|
|
60
|
+
```
|
|
61
|
+
|
|
62
|
+
### Standalone function
|
|
63
|
+
|
|
64
|
+
The standalone function version of this method:
|
|
65
|
+
|
|
66
|
+
```typescript
|
|
67
|
+
import { GreenSecurityCore } from "@greensecurity/javascript-sdk/core.js";
|
|
68
|
+
import { organizationsListOrSearchFacilities } from "@greensecurity/javascript-sdk/funcs/organizationsListOrSearchFacilities.js";
|
|
69
|
+
|
|
70
|
+
// Use `GreenSecurityCore` for best tree-shaking performance.
|
|
71
|
+
// You can create one instance of it to use across an application.
|
|
72
|
+
const greenSecurity = new GreenSecurityCore({
|
|
73
|
+
security: {
|
|
74
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
75
|
+
},
|
|
76
|
+
});
|
|
77
|
+
|
|
78
|
+
async function run() {
|
|
79
|
+
const res = await organizationsListOrSearchFacilities(greenSecurity, {
|
|
80
|
+
sort: "job",
|
|
81
|
+
desc: true,
|
|
82
|
+
itemsPerPage: 25,
|
|
83
|
+
expand: [
|
|
84
|
+
"facility.system",
|
|
85
|
+
],
|
|
86
|
+
});
|
|
87
|
+
if (res.ok) {
|
|
88
|
+
const { value: result } = res;
|
|
89
|
+
for await (const page of result) {
|
|
90
|
+
console.log(page);
|
|
91
|
+
}
|
|
92
|
+
} else {
|
|
93
|
+
console.log("organizationsListOrSearchFacilities failed:", res.error);
|
|
94
|
+
}
|
|
95
|
+
}
|
|
96
|
+
|
|
97
|
+
run();
|
|
98
|
+
```
|
|
99
|
+
|
|
100
|
+
### React hooks and utilities
|
|
101
|
+
|
|
102
|
+
This method can be used in React components through the following hooks and
|
|
103
|
+
associated utilities.
|
|
104
|
+
|
|
105
|
+
> Check out [this guide][hook-guide] for information about each of the utilities
|
|
106
|
+
> below and how to get started using React hooks.
|
|
107
|
+
|
|
108
|
+
[hook-guide]: ../../../REACT_QUERY.md
|
|
109
|
+
|
|
110
|
+
```tsx
|
|
111
|
+
import {
|
|
112
|
+
// Query hooks for fetching data.
|
|
113
|
+
useOrganizationsListOrSearchFacilities,
|
|
114
|
+
useOrganizationsListOrSearchFacilitiesSuspense,
|
|
115
|
+
// Query hooks suitable for building infinite scrolling or "load more" UIs.
|
|
116
|
+
useOrganizationsListOrSearchFacilitiesInfinite,
|
|
117
|
+
useOrganizationsListOrSearchFacilitiesInfiniteSuspense,
|
|
118
|
+
|
|
119
|
+
// Utility for prefetching data during server-side rendering and in React
|
|
120
|
+
// Server Components that will be immediately available to client components
|
|
121
|
+
// using the hooks.
|
|
122
|
+
prefetchOrganizationsListOrSearchFacilities,
|
|
123
|
+
|
|
124
|
+
// Utilities to invalidate the query cache for this query in response to
|
|
125
|
+
// mutations and other user actions.
|
|
126
|
+
invalidateOrganizationsListOrSearchFacilities,
|
|
127
|
+
invalidateAllOrganizationsListOrSearchFacilities,
|
|
128
|
+
} from "@greensecurity/javascript-sdk/react-query/organizationsListOrSearchFacilities.js";
|
|
129
|
+
```
|
|
130
|
+
|
|
131
|
+
### Parameters
|
|
132
|
+
|
|
133
|
+
| Parameter | Type | Required | Description |
|
|
134
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
135
|
+
| `request` | [operations.ListOrSearchFacilitiesRequest](../../models/operations/listorsearchfacilitiesrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
136
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
137
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
138
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
139
|
+
|
|
140
|
+
### Response
|
|
141
|
+
|
|
142
|
+
**Promise\<[operations.ListOrSearchFacilitiesResponse](../../models/operations/listorsearchfacilitiesresponse.md)\>**
|
|
143
|
+
|
|
144
|
+
### Errors
|
|
145
|
+
|
|
146
|
+
| Error Type | Status Code | Content Type |
|
|
147
|
+
| ----------------------- | ----------------------- | ----------------------- |
|
|
148
|
+
| errors.ApiErrorResponse | 400, 401, 403 | application/json |
|
|
149
|
+
| errors.ApiErrorResponse | 500 | application/json |
|
|
150
|
+
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
151
|
+
|
|
152
|
+
## getFacility
|
|
153
|
+
|
|
154
|
+
Retrieve an individual facility.
|
|
155
|
+
|
|
156
|
+
### Example Usage
|
|
157
|
+
|
|
158
|
+
<!-- UsageSnippet language="typescript" operationID="getFacility" method="get" path="/facilities/{id}" -->
|
|
159
|
+
```typescript
|
|
160
|
+
import { GreenSecurity } from "@greensecurity/javascript-sdk";
|
|
161
|
+
|
|
162
|
+
const greenSecurity = new GreenSecurity({
|
|
163
|
+
security: {
|
|
164
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
165
|
+
},
|
|
166
|
+
});
|
|
167
|
+
|
|
168
|
+
async function run() {
|
|
169
|
+
const result = await greenSecurity.organizations.getFacility({
|
|
170
|
+
id: 767404,
|
|
171
|
+
});
|
|
172
|
+
|
|
173
|
+
console.log(result);
|
|
174
|
+
}
|
|
175
|
+
|
|
176
|
+
run();
|
|
177
|
+
```
|
|
178
|
+
|
|
179
|
+
### Standalone function
|
|
180
|
+
|
|
181
|
+
The standalone function version of this method:
|
|
182
|
+
|
|
183
|
+
```typescript
|
|
184
|
+
import { GreenSecurityCore } from "@greensecurity/javascript-sdk/core.js";
|
|
185
|
+
import { organizationsGetFacility } from "@greensecurity/javascript-sdk/funcs/organizationsGetFacility.js";
|
|
186
|
+
|
|
187
|
+
// Use `GreenSecurityCore` for best tree-shaking performance.
|
|
188
|
+
// You can create one instance of it to use across an application.
|
|
189
|
+
const greenSecurity = new GreenSecurityCore({
|
|
190
|
+
security: {
|
|
191
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
192
|
+
},
|
|
193
|
+
});
|
|
194
|
+
|
|
195
|
+
async function run() {
|
|
196
|
+
const res = await organizationsGetFacility(greenSecurity, {
|
|
197
|
+
id: 767404,
|
|
198
|
+
});
|
|
199
|
+
if (res.ok) {
|
|
200
|
+
const { value: result } = res;
|
|
201
|
+
console.log(result);
|
|
202
|
+
} else {
|
|
203
|
+
console.log("organizationsGetFacility failed:", res.error);
|
|
204
|
+
}
|
|
205
|
+
}
|
|
206
|
+
|
|
207
|
+
run();
|
|
208
|
+
```
|
|
209
|
+
|
|
210
|
+
### React hooks and utilities
|
|
211
|
+
|
|
212
|
+
This method can be used in React components through the following hooks and
|
|
213
|
+
associated utilities.
|
|
214
|
+
|
|
215
|
+
> Check out [this guide][hook-guide] for information about each of the utilities
|
|
216
|
+
> below and how to get started using React hooks.
|
|
217
|
+
|
|
218
|
+
[hook-guide]: ../../../REACT_QUERY.md
|
|
219
|
+
|
|
220
|
+
```tsx
|
|
221
|
+
import {
|
|
222
|
+
// Query hooks for fetching data.
|
|
223
|
+
useOrganizationsGetFacility,
|
|
224
|
+
useOrganizationsGetFacilitySuspense,
|
|
225
|
+
|
|
226
|
+
// Utility for prefetching data during server-side rendering and in React
|
|
227
|
+
// Server Components that will be immediately available to client components
|
|
228
|
+
// using the hooks.
|
|
229
|
+
prefetchOrganizationsGetFacility,
|
|
230
|
+
|
|
231
|
+
// Utilities to invalidate the query cache for this query in response to
|
|
232
|
+
// mutations and other user actions.
|
|
233
|
+
invalidateOrganizationsGetFacility,
|
|
234
|
+
invalidateAllOrganizationsGetFacility,
|
|
235
|
+
} from "@greensecurity/javascript-sdk/react-query/organizationsGetFacility.js";
|
|
236
|
+
```
|
|
237
|
+
|
|
238
|
+
### Parameters
|
|
239
|
+
|
|
240
|
+
| Parameter | Type | Required | Description |
|
|
241
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
242
|
+
| `request` | [operations.GetFacilityRequest](../../models/operations/getfacilityrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
243
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
244
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
245
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
246
|
+
|
|
247
|
+
### Response
|
|
248
|
+
|
|
249
|
+
**Promise\<[components.Facility](../../models/components/facility.md)\>**
|
|
250
|
+
|
|
251
|
+
### Errors
|
|
252
|
+
|
|
253
|
+
| Error Type | Status Code | Content Type |
|
|
254
|
+
| ----------------------- | ----------------------- | ----------------------- |
|
|
255
|
+
| errors.ApiErrorResponse | 400, 401, 403, 404 | application/json |
|
|
256
|
+
| errors.ApiErrorResponse | 500 | application/json |
|
|
257
|
+
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
258
|
+
|
|
259
|
+
## listOrSearchDepartments
|
|
260
|
+
|
|
261
|
+
List or search departments.
|
|
262
|
+
|
|
263
|
+
### Example Usage
|
|
264
|
+
|
|
265
|
+
<!-- UsageSnippet language="typescript" operationID="listOrSearchDepartments" method="get" path="/facilities/{id}/departments" -->
|
|
266
|
+
```typescript
|
|
267
|
+
import { GreenSecurity } from "@greensecurity/javascript-sdk";
|
|
268
|
+
|
|
269
|
+
const greenSecurity = new GreenSecurity({
|
|
270
|
+
security: {
|
|
271
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
272
|
+
},
|
|
273
|
+
});
|
|
274
|
+
|
|
275
|
+
async function run() {
|
|
276
|
+
const result = await greenSecurity.organizations.listOrSearchDepartments({
|
|
277
|
+
id: 218294,
|
|
278
|
+
sort: "job",
|
|
279
|
+
desc: true,
|
|
280
|
+
itemsPerPage: 25,
|
|
281
|
+
});
|
|
282
|
+
|
|
283
|
+
for await (const page of result) {
|
|
284
|
+
console.log(page);
|
|
285
|
+
}
|
|
286
|
+
}
|
|
287
|
+
|
|
288
|
+
run();
|
|
289
|
+
```
|
|
290
|
+
|
|
291
|
+
### Standalone function
|
|
292
|
+
|
|
293
|
+
The standalone function version of this method:
|
|
294
|
+
|
|
295
|
+
```typescript
|
|
296
|
+
import { GreenSecurityCore } from "@greensecurity/javascript-sdk/core.js";
|
|
297
|
+
import { organizationsListOrSearchDepartments } from "@greensecurity/javascript-sdk/funcs/organizationsListOrSearchDepartments.js";
|
|
298
|
+
|
|
299
|
+
// Use `GreenSecurityCore` for best tree-shaking performance.
|
|
300
|
+
// You can create one instance of it to use across an application.
|
|
301
|
+
const greenSecurity = new GreenSecurityCore({
|
|
302
|
+
security: {
|
|
303
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
304
|
+
},
|
|
305
|
+
});
|
|
306
|
+
|
|
307
|
+
async function run() {
|
|
308
|
+
const res = await organizationsListOrSearchDepartments(greenSecurity, {
|
|
309
|
+
id: 218294,
|
|
310
|
+
sort: "job",
|
|
311
|
+
desc: true,
|
|
312
|
+
itemsPerPage: 25,
|
|
313
|
+
});
|
|
314
|
+
if (res.ok) {
|
|
315
|
+
const { value: result } = res;
|
|
316
|
+
for await (const page of result) {
|
|
317
|
+
console.log(page);
|
|
318
|
+
}
|
|
319
|
+
} else {
|
|
320
|
+
console.log("organizationsListOrSearchDepartments failed:", res.error);
|
|
321
|
+
}
|
|
322
|
+
}
|
|
323
|
+
|
|
324
|
+
run();
|
|
325
|
+
```
|
|
326
|
+
|
|
327
|
+
### React hooks and utilities
|
|
328
|
+
|
|
329
|
+
This method can be used in React components through the following hooks and
|
|
330
|
+
associated utilities.
|
|
331
|
+
|
|
332
|
+
> Check out [this guide][hook-guide] for information about each of the utilities
|
|
333
|
+
> below and how to get started using React hooks.
|
|
334
|
+
|
|
335
|
+
[hook-guide]: ../../../REACT_QUERY.md
|
|
336
|
+
|
|
337
|
+
```tsx
|
|
338
|
+
import {
|
|
339
|
+
// Query hooks for fetching data.
|
|
340
|
+
useOrganizationsListOrSearchDepartments,
|
|
341
|
+
useOrganizationsListOrSearchDepartmentsSuspense,
|
|
342
|
+
// Query hooks suitable for building infinite scrolling or "load more" UIs.
|
|
343
|
+
useOrganizationsListOrSearchDepartmentsInfinite,
|
|
344
|
+
useOrganizationsListOrSearchDepartmentsInfiniteSuspense,
|
|
345
|
+
|
|
346
|
+
// Utility for prefetching data during server-side rendering and in React
|
|
347
|
+
// Server Components that will be immediately available to client components
|
|
348
|
+
// using the hooks.
|
|
349
|
+
prefetchOrganizationsListOrSearchDepartments,
|
|
350
|
+
|
|
351
|
+
// Utilities to invalidate the query cache for this query in response to
|
|
352
|
+
// mutations and other user actions.
|
|
353
|
+
invalidateOrganizationsListOrSearchDepartments,
|
|
354
|
+
invalidateAllOrganizationsListOrSearchDepartments,
|
|
355
|
+
} from "@greensecurity/javascript-sdk/react-query/organizationsListOrSearchDepartments.js";
|
|
356
|
+
```
|
|
357
|
+
|
|
358
|
+
### Parameters
|
|
359
|
+
|
|
360
|
+
| Parameter | Type | Required | Description |
|
|
361
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
362
|
+
| `request` | [operations.ListOrSearchDepartmentsRequest](../../models/operations/listorsearchdepartmentsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
363
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
364
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
365
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
366
|
+
|
|
367
|
+
### Response
|
|
368
|
+
|
|
369
|
+
**Promise\<[operations.ListOrSearchDepartmentsResponse](../../models/operations/listorsearchdepartmentsresponse.md)\>**
|
|
370
|
+
|
|
371
|
+
### Errors
|
|
372
|
+
|
|
373
|
+
| Error Type | Status Code | Content Type |
|
|
374
|
+
| ----------------------- | ----------------------- | ----------------------- |
|
|
375
|
+
| errors.ApiErrorResponse | 400, 401, 403 | application/json |
|
|
376
|
+
| errors.ApiErrorResponse | 500 | application/json |
|
|
377
|
+
| errors.APIError | 4XX, 5XX | \*/\* |
|
|
378
|
+
|
|
379
|
+
## listOrSearchDepartmentContacts
|
|
380
|
+
|
|
381
|
+
List or search department contacts.
|
|
382
|
+
|
|
383
|
+
Available `expand` scopes are:
|
|
384
|
+
|
|
385
|
+
- department_membership.contact
|
|
386
|
+
- department_membership.department
|
|
387
|
+
|
|
388
|
+
### Example Usage
|
|
389
|
+
|
|
390
|
+
<!-- UsageSnippet language="typescript" operationID="listOrSearchDepartmentContacts" method="get" path="/departments/{id}/contacts" -->
|
|
391
|
+
```typescript
|
|
392
|
+
import { GreenSecurity } from "@greensecurity/javascript-sdk";
|
|
393
|
+
|
|
394
|
+
const greenSecurity = new GreenSecurity({
|
|
395
|
+
security: {
|
|
396
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
397
|
+
},
|
|
398
|
+
});
|
|
399
|
+
|
|
400
|
+
async function run() {
|
|
401
|
+
const result = await greenSecurity.organizations.listOrSearchDepartmentContacts({
|
|
402
|
+
id: 962833,
|
|
403
|
+
sort: "job",
|
|
404
|
+
desc: true,
|
|
405
|
+
itemsPerPage: 25,
|
|
406
|
+
expand: [
|
|
407
|
+
"facility.system",
|
|
408
|
+
],
|
|
409
|
+
});
|
|
410
|
+
|
|
411
|
+
for await (const page of result) {
|
|
412
|
+
console.log(page);
|
|
413
|
+
}
|
|
414
|
+
}
|
|
415
|
+
|
|
416
|
+
run();
|
|
417
|
+
```
|
|
418
|
+
|
|
419
|
+
### Standalone function
|
|
420
|
+
|
|
421
|
+
The standalone function version of this method:
|
|
422
|
+
|
|
423
|
+
```typescript
|
|
424
|
+
import { GreenSecurityCore } from "@greensecurity/javascript-sdk/core.js";
|
|
425
|
+
import { organizationsListOrSearchDepartmentContacts } from "@greensecurity/javascript-sdk/funcs/organizationsListOrSearchDepartmentContacts.js";
|
|
426
|
+
|
|
427
|
+
// Use `GreenSecurityCore` for best tree-shaking performance.
|
|
428
|
+
// You can create one instance of it to use across an application.
|
|
429
|
+
const greenSecurity = new GreenSecurityCore({
|
|
430
|
+
security: {
|
|
431
|
+
token: process.env["GREEN_SECURITY_TOKEN"] ?? "",
|
|
432
|
+
},
|
|
433
|
+
});
|
|
434
|
+
|
|
435
|
+
async function run() {
|
|
436
|
+
const res = await organizationsListOrSearchDepartmentContacts(greenSecurity, {
|
|
437
|
+
id: 962833,
|
|
438
|
+
sort: "job",
|
|
439
|
+
desc: true,
|
|
440
|
+
itemsPerPage: 25,
|
|
441
|
+
expand: [
|
|
442
|
+
"facility.system",
|
|
443
|
+
],
|
|
444
|
+
});
|
|
445
|
+
if (res.ok) {
|
|
446
|
+
const { value: result } = res;
|
|
447
|
+
for await (const page of result) {
|
|
448
|
+
console.log(page);
|
|
449
|
+
}
|
|
450
|
+
} else {
|
|
451
|
+
console.log("organizationsListOrSearchDepartmentContacts failed:", res.error);
|
|
452
|
+
}
|
|
453
|
+
}
|
|
454
|
+
|
|
455
|
+
run();
|
|
456
|
+
```
|
|
457
|
+
|
|
458
|
+
### React hooks and utilities
|
|
459
|
+
|
|
460
|
+
This method can be used in React components through the following hooks and
|
|
461
|
+
associated utilities.
|
|
462
|
+
|
|
463
|
+
> Check out [this guide][hook-guide] for information about each of the utilities
|
|
464
|
+
> below and how to get started using React hooks.
|
|
465
|
+
|
|
466
|
+
[hook-guide]: ../../../REACT_QUERY.md
|
|
467
|
+
|
|
468
|
+
```tsx
|
|
469
|
+
import {
|
|
470
|
+
// Query hooks for fetching data.
|
|
471
|
+
useOrganizationsListOrSearchDepartmentContacts,
|
|
472
|
+
useOrganizationsListOrSearchDepartmentContactsSuspense,
|
|
473
|
+
// Query hooks suitable for building infinite scrolling or "load more" UIs.
|
|
474
|
+
useOrganizationsListOrSearchDepartmentContactsInfinite,
|
|
475
|
+
useOrganizationsListOrSearchDepartmentContactsInfiniteSuspense,
|
|
476
|
+
|
|
477
|
+
// Utility for prefetching data during server-side rendering and in React
|
|
478
|
+
// Server Components that will be immediately available to client components
|
|
479
|
+
// using the hooks.
|
|
480
|
+
prefetchOrganizationsListOrSearchDepartmentContacts,
|
|
481
|
+
|
|
482
|
+
// Utilities to invalidate the query cache for this query in response to
|
|
483
|
+
// mutations and other user actions.
|
|
484
|
+
invalidateOrganizationsListOrSearchDepartmentContacts,
|
|
485
|
+
invalidateAllOrganizationsListOrSearchDepartmentContacts,
|
|
486
|
+
} from "@greensecurity/javascript-sdk/react-query/organizationsListOrSearchDepartmentContacts.js";
|
|
487
|
+
```
|
|
488
|
+
|
|
489
|
+
### Parameters
|
|
490
|
+
|
|
491
|
+
| Parameter | Type | Required | Description |
|
|
492
|
+
| ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ | ------------------------------------------------------------------------------------------------------------------------------------------------------------------------------ |
|
|
493
|
+
| `request` | [operations.ListOrSearchDepartmentContactsRequest](../../models/operations/listorsearchdepartmentcontactsrequest.md) | :heavy_check_mark: | The request object to use for the request. |
|
|
494
|
+
| `options` | RequestOptions | :heavy_minus_sign: | Used to set various options for making HTTP requests. |
|
|
495
|
+
| `options.fetchOptions` | [RequestInit](https://developer.mozilla.org/en-US/docs/Web/API/Request/Request#options) | :heavy_minus_sign: | Options that are passed to the underlying HTTP request. This can be used to inject extra headers for examples. All `Request` options, except `method` and `body`, are allowed. |
|
|
496
|
+
| `options.retries` | [RetryConfig](../../lib/utils/retryconfig.md) | :heavy_minus_sign: | Enables retrying HTTP requests under certain failure conditions. |
|
|
497
|
+
|
|
498
|
+
### Response
|
|
499
|
+
|
|
500
|
+
**Promise\<[operations.ListOrSearchDepartmentContactsResponse](../../models/operations/listorsearchdepartmentcontactsresponse.md)\>**
|
|
501
|
+
|
|
502
|
+
### Errors
|
|
503
|
+
|
|
504
|
+
| Error Type | Status Code | Content Type |
|
|
505
|
+
| ----------------------- | ----------------------- | ----------------------- |
|
|
506
|
+
| errors.ApiErrorResponse | 400, 401, 403 | application/json |
|
|
507
|
+
| errors.ApiErrorResponse | 500 | application/json |
|
|
508
|
+
| errors.APIError | 4XX, 5XX | \*/\* |
|