TwkApiV1DemoJsonImpl class
Methods
-
addDocument({required String documentName, required String documentContent, required String referenceNumber, required int categoryId})
→ Future<void>
-
Add document to user's storage
Corresponds to: window.TWK.addDocument(documentName, documentContent, referenceNumber, categoryId)
override
-
apiLog({required String url, required int methodType, String? requestBody, DateTime? requestDateTime, String? responseBody, DateTime? responseDateTime, required int responseCode})
→ Future<void>
-
API log with detailed request/response information
Corresponds to: window.TWK.apiLog(url, methodType, requestBody, requestHeaders, requestDateTime, responseBody, responseHeaders, responseDateTime, responseCode)
override
-
askCameraPermission()
→ Future<Map<String, dynamic>>
-
Ask user for camera permission
Corresponds to: window.TWK.askCameraPermission()
override
-
askGalleryPermission()
→ Future<Map<String, dynamic>>
-
Ask user for gallery permission
Corresponds to: window.TWK.askGalleryPermission()
override
-
askPushNotificationPermission()
→ Future<Map<String, dynamic>>
-
Ask user for push notification permission
Corresponds to: window.TWK.askPushNotificationPermission()
override
-
askUserLocationPermission()
→ Future<Map<String, dynamic>>
-
Ask user for location permission
Corresponds to: window.TWK.askUserLocationPermission()
override
-
askUserPreciseLocationPermission()
→ Future<Map<String, dynamic>>
-
Ask user for precise location permission
Corresponds to: window.TWK.askUserPreciseLocationPermission()
override
-
authenticateBiometric()
→ Future<Map<String, dynamic>>
-
Authenticate using biometric
Corresponds to: window.TWK.authenticateBiometric()
override
-
deleteDocument({required String referenceNumber, required int categoryId})
→ Future<void>
-
Delete document
Corresponds to: window.TWK.deleteDocument(referenceNumber, categoryId)
override
-
generalLog({required String eventName, required int logType, required String logMessage})
→ Future<void>
-
General log with event name, log type, and message
Corresponds to: window.TWK.generalLog(eventName, logType, logMessage)
override
-
generateToken()
→ Future<Map<String, dynamic>>
-
Generate authentication token
Corresponds to: window.TWK.generateToken()
override
-
getCameraPhoto()
→ Future<Map<String, dynamic>?>
-
Capture photo using camera
Corresponds to: window.TWK.getCameraPhoto()
override
-
getCameraVideo()
→ Future<Map<String, dynamic>?>
-
Capture video using camera
Corresponds to: window.TWK.getCameraVideo()
override
-
getDeviceInfo()
→ Future<Map<String, dynamic>>
-
Get device information and capabilities
Corresponds to: window.TWK.getDeviceInfo()
override
-
getFileBase64()
→ Future<String?>
-
Get file as base64 string
Corresponds to: window.TWK.getFileBase64()
override
-
getFileId()
→ Future<String?>
-
Get file ID
Corresponds to: window.TWK.getFileId()
override
-
getGalleryMulti()
→ Future<List<Map<String, dynamic>>>
-
Get multiple images from gallery
Corresponds to: window.TWK.getGalleryMulti()
override
-
getGalleryMultiVideo()
→ Future<List<Map<String, dynamic>>>
-
Get multiple videos from gallery
Corresponds to: window.TWK.getGalleryMultiVideo()
override
-
getGallerySingle()
→ Future<Map<String, dynamic>>
-
Get single image from gallery
Corresponds to: window.TWK.getGallerySingle()
override
-
getGallerySingleVideo()
→ Future<Map<String, dynamic>>
-
Get single video from gallery
Corresponds to: window.TWK.getGallerySingleVideo()
override
-
getImage(String nationalId)
→ Future<Uint8List?>
-
Get image by national ID
Corresponds to: window.TWK.getImage(nationalId)
override
-
getRawData(TwkFile file)
→ Future<Uint8List>
-
Get raw data from a file
Corresponds to: window.TWK.getRawData(file)
override
-
getUserBirthCity()
→ Future<Map<String, dynamic>>
-
Get user's birth city
Corresponds to: window.TWK.getUserBirthCity()
override
-
getUserBirthDate()
→ Future<Map<String, dynamic>>
-
Get user's birth date
Corresponds to: window.TWK.getUserBirthDate()
override
-
getUserBloodType()
→ Future<Map<String, dynamic>>
-
Get user's blood type
Corresponds to: window.TWK.getUserBloodType()
override
-
getUserDegreeType()
→ Future<Map<String, dynamic>>
-
Get user's degree/education type
Corresponds to: window.TWK.getUserDegreeType()
override
-
getUserDisabilityType()
→ Future<Map<String, dynamic>>
-
Get user's disability type
Corresponds to: window.TWK.getUserDisabilityType()
override
-
getUserDocumentNumber()
→ Future<Map<String, dynamic>>
-
Get user's document number
Corresponds to: window.TWK.getUserDocumentNumber()
override
-
getUserEmail()
→ Future<Map<String, dynamic>>
-
Get user's email
Corresponds to: window.TWK.getUserEmail()
override
-
getUserFamilyMembers({int? minAge, int? maxAge, int? gender})
→ Future<Map<String, dynamic>>
-
Get user's family members with optional filters
Corresponds to: window.TWK.getUserFamilyMembers(minage, maxage, gender)
override
-
getUserFullName()
→ Future<Map<String, String>>
-
Get user's full name (Arabic and English)
Corresponds to: window.TWK.getUserFullName()
override
-
getUserGender()
→ Future<Map<String, dynamic>>
-
Get user's gender
Corresponds to: window.TWK.getUserGender()
override
-
getUserHealthStatus()
→ Future<Map<String, dynamic>>
-
Get user's health status
Corresponds to: window.TWK.getUserHealthStatus()
override
-
getUserId()
→ Future<Map<String, dynamic>>
-
Get user's national ID
Corresponds to: window.TWK.getUserId()
override
-
getUserIdExpiryDate()
→ Future<Map<String, dynamic>>
-
Get user's ID expiry date
Corresponds to: window.TWK.getUserIdExpiryDate()
override
-
getUserIqamaType()
→ Future<Map<String, dynamic>>
-
Get user's iqama type
Corresponds to: window.TWK.getUserIqamaType()
override
-
getUserLocation()
→ Future<Map<String, dynamic>>
-
Get user's location
Corresponds to: window.TWK.getUserLocation()
override
-
getUserMaritalStatus()
→ Future<Map<String, dynamic>>
-
Get user's marital status
Corresponds to: window.TWK.getUserMaritalStatus()
override
-
getUserMobileNumber()
→ Future<Map<String, dynamic>>
-
Get user's mobile number
Corresponds to: window.TWK.getUserMobileNumber()
override
-
getUserNationalAddress()
→ Future<Map<String, dynamic>>
-
Get user's national address
Corresponds to: window.TWK.getUserNationalAddress()
override
-
getUserNationality()
→ Future<Map<String, dynamic>>
-
Get user's nationality name
Corresponds to: window.TWK.getUserNationality()
override
-
getUserNationalityIso()
→ Future<Map<String, dynamic>>
-
Get user's nationality ISO code
Corresponds to: window.TWK.getUserNationalityISO()
override
-
getUserOccupation()
→ Future<Map<String, dynamic>>
-
Get user's occupation
Corresponds to: window.TWK.getUserOccupation()
override
-
getUserPaidViolations()
→ Future<Map<String, dynamic>>
-
Get user's paid violations
Corresponds to: window.TWK.getUserPaidViolations()
override
-
getUserPassports()
→ Future<Map<String, dynamic>>
-
Get user's passports
Corresponds to: window.TWK.getUserPassports()
override
-
getUserProfilePhoto()
→ Future<Map<String, dynamic>>
-
Get user's profile photo
Corresponds to: window.TWK.getUserProfilePhoto()
override
-
Get user's sponsors with optional filters
Corresponds to: window.TWK.getUserSponsors(minage, maxage, gender)
override
-
getUserType()
→ Future<Map<String, dynamic>>
-
Get user's type (citizen, resident, visitor, etc.)
Corresponds to: window.TWK.getUserType()
override
-
getUserUnPaidViolations()
→ Future<Map<String, dynamic>>
-
Get user's unpaid violations
Corresponds to: window.TWK.getUserUnPaidViolations()
override
-
getUserVehicles()
→ Future<Map<String, dynamic>>
-
Get user's vehicles
Corresponds to: window.TWK.getUserVehicles()
override
-
livenessCheckCamera({List<Map<String, dynamic>>? configurations})
→ Future<Map<String, dynamic>?>
-
Liveness check using camera with configurations
Corresponds to: window.TWK.livenessCheckCamera(configurations)
override
-
livenessCheckImageFromFiles({List<Map<String, dynamic>>? configurations})
→ Future<Map<String, dynamic>?>
-
Liveness check from file image with configurations
Corresponds to: window.TWK.livenessCheckImageFromFiles(configurations)
override
-
livenessCheckImageFromGallery({List<Map<String, dynamic>>? configurations})
→ Future<Map<String, dynamic>?>
-
Liveness check from gallery image with configurations
Corresponds to: window.TWK.livenessCheckImageFromGallery(configurations)
override
-
noSuchMethod(Invocation invocation)
→ dynamic
-
Invoked when a nonexistent method or property is accessed.
inherited
-
openScreen({required String screenType, Map<String, dynamic>? params})
→ Future<void>
-
Open screen with parameters
Corresponds to: window.TWK.openScreen(screenType, valuesParam)
override
-
openService({required String serviceId, Map<String, dynamic>? params})
→ Future<void>
-
Open service by ID with parameters
Corresponds to: window.TWK.openService(serviceId, valuesParam)
override
-
openUrl({required String url, required int urlType})
→ Future<void>
-
Open URL with specified type
Corresponds to: window.TWK.openUrl(url, urlType)
override
-
postCard({required String actionType, required Map<String, dynamic> payload})
→ Future<void>
-
Post card with action type and payload
Corresponds to: window.TWK.postCard(actionType, payload)
override
-
scanCode()
→ Future<String?>
-
Scan QR/Barcode
Corresponds to: window.TWK.scanCode()
override
-
setPaymentConfiguration({required List<String> callbackSuccessUrlList, required List<String> callbackFailureUrlList, required String successPageName, required String failurePageName})
→ Future<void>
-
Set payment configuration
Corresponds to: window.TWK.setPaymentConfiguration(callbackSuccessUrlList, callbackFailureUrlList, successPageName, failurePageName)
override
-
share({required String fileName, required String content, required String mimeType})
→ Future<void>
-
Share file with base64 content
Corresponds to: window.TWK.share(fileName, content, mimetype)
override
-
shareScreenShot()
→ Future<void>
-
Share screenshot
Corresponds to: window.TWK.shareScreenShot()
override
-
startApiIntercept()
→ Future<void>
-
Start API interceptor to automatically log API calls
Corresponds to: window.TWK.startApiIntercept()
override
-
toString()
→ String
-
A string representation of this object.
inherited
-
updateDocument({required String documentName, required String documentContent, required String referenceNumber, required int categoryId})
→ Future<void>
-
Update existing document
Corresponds to: window.TWK.updateDocument(documentName, documentContent, referenceNumber, categoryId)
override