@phygitallabs/tapquest-core 6.7.6 → 6.7.8

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@phygitallabs/tapquest-core",
3
- "version": "6.7.6",
3
+ "version": "6.7.8",
4
4
  "private": false,
5
5
  "publishConfig": {
6
6
  "access": "public"
@@ -38,6 +38,16 @@ export const ServicesProvider: React.FC<ServicesProviderProps> = ({
38
38
  const { environment, version } = apiConfig;
39
39
  const [commonServiceConfig, setCommonServiceConfig] = useState<ServiceConfig | null>(null);
40
40
 
41
+ const [deviceUid, setDeviceUid] = useState<string>("");
42
+
43
+ useEffect(() => {
44
+ const initDeviceUid = async () => {
45
+ const deviceUid = await checkDeviceUid();
46
+ setDeviceUid(deviceUid);
47
+ }
48
+ initDeviceUid();
49
+ }, []);
50
+
41
51
  // Init client
42
52
  useEffect(() => {
43
53
  const initClient = async () => {
@@ -132,11 +142,14 @@ export const ServicesProvider: React.FC<ServicesProviderProps> = ({
132
142
  baseURL={`${serviceApiUrl[environment].API_GENERATE_CERTIFICATE_URL}/v1`}
133
143
  >
134
144
  <PhygitalConsentProvider
135
- queryClient={commonServiceConfig.queryClient as any}
136
- axiosConfig={commonServiceConfig.axiosConfig}
137
- requestInterceptors={commonServiceConfig.requestInterceptors}
138
- responseInterceptors={commonServiceConfig.responseInterceptors}
139
- baseURL={`${serviceApiUrl[environment].API_CONSENT_URL}/${version}`}
145
+ {...commonServiceConfig}
146
+ deviceId={deviceUid}
147
+ baseURL={`${serviceApiUrl[environment].API_CONSENT_URL}/v1`}
148
+ axiosConfig={{
149
+ headers: {
150
+ "Content-Type": "application/json",
151
+ }
152
+ }}
140
153
  >
141
154
  {children}
142
155
  </PhygitalConsentProvider>