Desk360 Docs
Search…
Flutter SDK
Desk360 Flutter SDK helps you embedding customer support in your Flutter mobile applications with ease. This package gives wrapper methods for desk360 sdks. iOS - Android​

Features

  • Turn all your customer support requests into tickets and interact with these messages using our powerful platform.
  • Flutter SDK has highly customizable and flexible UI options.
  • Push notifications and deep linking support options are both available.
  • Give multilingual support for your customers: It supports 40+ languages.
  • Flutter SDK supports different types of media and file formats.
  • It's easy to use and integrate. After writing only a few lines of code, you're ready to use!
​

Installation

Getting started

Add below code into your pubspec.yaml file under dependencies section.
1
desk360flutter:
2
git:
3
url: https://github.com/Teknasyon-Teknoloji/desk360-flutter-sdk.git
4
ref: 0.1.0
Copied!
And run $ flutter pub get

Installation Notes

  • IOS
    • Set minimum ios version 10.0 or higher in ios/Podfile like: platform :ios, '10.0'
    • Add use_frameworks! into ios/Podfile if not exists.
    • Run $ cd ios && pod install
  • ANDROID
    • Set kotlin_version "1.4.32" or higher in android/build.gradle
    • Set minSdkVersion to 21 or higher in android/app/build.gradle
    • Add maven { url 'https://raw.githubusercontent.com/Teknasyon-Teknoloji/desk360-android-sdk/master/' } into android/build.gradle (Add into repositories under allprojects)
​

Usage

Let's start

Important footnot

You must add your info.plist file.
1
<key>NSPhotoLibraryUsageDescription</key>
2
<string>Allow the app to access your photos.</string>
Copied!
Permission text is optional. you can type whatever you want. But this permission not optional. If you didn't add this permission. Desk360 Images attachment property doesn't work

Start Desk360 with appId -and an optinal deviceId, an optional language-

Note: If no deviceId is provided, Desk360 will use device's UUID, which might cause your app to lose tickets when the application is deleted. If use environment type .production, Desk360 will look at prod url. If no application language is provided, Desk360 will use device's language.
1
import 'package:desk360flutter/enums/environments.dart';
2
import 'package:desk360flutter/enums/platforms.dart' as Platforms;
3
import 'package:flutter/material.dart';
4
import 'package:desk360flutter/desk360flutter.dart';
5
​
6
if (Platform.isIOS) {
7
Desk360flutter.start(properties: {
8
"appID": "aOJe1THakL03kwONmc2U4utYCeW16zJr",
9
"deviceID": "34567",
10
"languageCode": 'en',
11
"environment": Environment.SANDBOX.value,
12
"countryCode": 'tr',
13
"bypassCreateTicketIntro": true,
14
});
15
Desk360flutter.show(animated: true);
16
} else {
17
var androidDeviceInfo = await deviceInfo.androidInfo;
18
var deviceId = androidDeviceInfo.androidId;
19
Desk360flutter.initialize({
20
"appID": "aOJe1THakL03kwONmc2U4utYCeW16zJr",
21
"appVersion": "1.0.0",
22
"languageCode": 'en',
23
"environment": Environment.SANDBOX.value,
24
"platform": Platforms.Platform.GOOGLE.value,
25
"countryCode": 'tr',
26
"name": "Test-092021"
27
}, "", deviceId);
28
Desk360flutter.start();
29
}
Copied!

Using Desk360

1
import 'package:desk360flutter/desk360flutter.dart';
2
​
3
Desk360flutter.getTicketId()
4
.then((value) => {print("Ticket ID: $value")});
Copied!

Getting the unread tickets

If you would like to get a list of the unread tickets you can do so like follows:
1
Desk360flutter.getUnreadTickets().then( (results) {
2
print(results);
3
});
Copied!
You can show the unread tickets the way that fits your app design and expierence. If you want to navigate to a specific ticket detail you can do so so by following:
1
Desk360flutter.ticketDetailsViewController(unreadTicket);
Copied!

Support

For further information, please with contact us [email protected]​
​
Visit our GITHUB page for usage, technical setup and detailed info.
​