Category : Opinion

Mobile Opinion

Emerging technologies and their role in shaping banking experiences

Can you imagine taking financial advice from sophisticated robots and AI-based apps before making an investment on a real-time basis? This will be the norm sooner than you can imagine. Online banking has become the primary interface channel for most consumers today. It is now becoming evident that the mounting pace of technological reforms is the most powerful force driving the financial services ecosystem globally.

The banking industry has seen radical technology-led transformations over the last decade. Most banking executives look to their IT support teams to maximize efficiency and facilitate groundbreaking innovation, while supporting the legacy systems & lowering costs. In the interim, FinTech start-ups are exploiting established markets and winning with customer- friendly solutions. Customers today have a slew of options and have scaled their expectations demanding agile, responsive, real-time, seamless, innovative and an integrated experience. And the pace of change & technology trends shows no sign of slowing.

As per a trend analysis from Gartner, within 12 years, “80% of financial firms will run out of business or be rendered inoperable due to changing customer expectations, competition and technology advancements.”

In 2018 alone, banks worldwide had planned to invest $9.7bn to improve and enhance their customer-facing digital banking tools. In the coming years, digital solutions in banking will include more nuanced approaches with big data, advanced analytics, and new platforms that automate tasks—enabling banks to increase both personalization and quality of customer service. To stay relevant to the ever evolving customer who is increasingly aware, time poor and tech savvy banks need to reevaluate customer interaction frameworks for a more personalized, flexible and value-driven experience.

Trends Impacting the Financial Services Industry

According to a research from Atos, the most transformational challenges and opportunities for the future of banking include, response to customer needs, cost optimization, creation of new revenue streams, developing security & compliance systems, expanding digitalization and innovation. All of these have a few things in common: a customer-centric approach, real -time & intelligent data integration & an open platform foundation. While some of these transformations would require modernization of outdated technologies & rethinking the traditional legacy models, the others would demand strategic partnerships & collaboration with Fin-tech firms. But there’s one thing that’s certain – the need for transformation. Financial firms that use advanced digital tools could potentially see a 30% reduction in IT costs if implemented effectively.

The choice is clear – lead the industry with customer-friendly digital experiences or be led by the competition.

The banking landscape is set to evolve at a greater magnitude in the next few years. While safety-features like biometrics and cryptography will explore ways to arrest scams faster, technology applications will make banking more of a virtual experience without having to visit one. The good news is that many of the new technologies that are threatening the banking industry today also present significant opportunities. Organizations that can capture analytics, data and technologies to enhance user experience can inspire customer trust which is the key contributor to success.

Here are 6 technologies banks must consider, to deliver an exemplary customer experience:

Here are 6 technologies banks must consider, to deliver an exemplary customer experience

1. Personalize with AI

The benefits of using Artificial Intelligence in banks and credit unions include optimizing back-end operations, data management, customer experience, compliance, product delivery and risk management. It’s not just about products and services on a well-integrated digital interface anymore; customers expect personalized experiences that are aligned with their preferences and behavior patterns. In other words, they expect you to give them practical & profitable alternatives that they did not think of themselves. Customers want you to assess their financial moves and reward them regardless of the platform they use. Bank of America piloted its popular chatbot, Erica, in late 2017 and boasts of 6 million users as of March 2019. With AI-backed models, the potential to transform banking experiences with a holistic overview of the customer behavior is truly exponential. What’s needed is a robust integration of an AI model infused with human expertise to provide personalized experiences for different customer prototypes.

2. Voice-ready banking

Just as how voice assistant Alexa was unfathomable a decade ago, so will be the trend for banking experiences without voice-first devices, where more than 50% of banking interactions will be voice-based.

As per a report from Analyst Firm Juniper Research, voice-based commerce will reach $80 billion by 2023. Voice-first devices are becoming an integral tool with consumers accomplishing tasks such as shopping, banking and home automation more seamlessly, due to which many banks and credit unions are taking to voice-first applications. Moving from the basic dialogues & account inquiries to more sophisticated transactions like executing payments, account transfers & setting account alerts using voice commands.

3. Instant Payment Gateways

The payments industry is by far one of the most dynamic areas of innovation in the banking industry. With the heightened surge of instant payment platforms, banks can influence greater customer satisfaction with customers expecting faster & seamless payment experiences.

Today, instant payment methods are available across most countries and a few where banks collaborate to offer an instant P2P payment experience, catering to a larger customer base. While large fintech firms, tech players and financial institutions continue to innovate based on evolving customer expectations and technology advances, this industry will soon be a part of everything customers do. Innovative payment trends will occur in conjunction with the Internet of Things (IoT), point of sale (POS), mobile wallets, cryptocurrencies, and blockchain. By diversifying and infusing instant payment capabilities across the e- and m-commerce space, banks and credit unions have a greater scope to build an innovative portfolio of customer-friendly services. And organizations that value customer payment insights as an intellectual organizational asset, can further segment and create personalized customer experiences basis their core behavior patterns.

4. Robotic Process Automation (RPA)

The robotic process automation refers to the use of virtual assistants that can perform repetitive and laborious tasks; making it ideal for the banking industry. As per a report from P&S Market Research, the global RPA market is expected to reach $8.6 billion by 2023. RPA in banking can disrupt the business-process-outsourcing models, as it minimizes costs while maximizing productivity.

The robotic process automation (RPA) is assisting banks to create meaningful customer engagement that is real time, quick, efficient and productive. It helps in executing pre-programmed rules across structured & unstructured data, for both customer-facing and back-office functions. RPA helps in minimizing costs & simplifies compliance with detailed logs to extract automated reports & enables automated decisions, based on previous data patterns, eliminating room for human error.

Deutsche Bank is deploying RPA to manage repetitive tasks more efficiently. It has reported 30- to 70-percent automation in areas where software is integrated and noted a remarkable decrease in the time required for employee training. With effective RPA implementation, banks can reduce manual work and enable banking executives to focus on the more complex strategy driven tasks.

5. Open Banking with API Platforms

Open Banking is based on open application programming interfaces (APIs), that allow trusted third-party developers to build services & technology interface for financial institutions.

APIs help to develop innovative products for a better customer experience, where the bank serves as a platform, over which third party companies build applications using the bank’s data. In this context, the Mastercard offering is designed to assist open banking efforts in better connectivity, consulting, dispute resolution and security & compliance. Emphasizing how Europe and its regulators inspired the Open Banking and the associated PSD2 regulatory regime, the Mastercard service is currently focused around UK & Poland and includes several payment and financial service providers including Alior Bank and Kikapay. Mastercard’s vision is to develop a host of Open banking services with optimal standards of clarity and consistency. If you are looking to deliver financial innovations, API partnerships are the fastest way to get there.

6. Wearable Technology

Being able to pay with just a gesture takes a lot more than a gadget on your wrist. It requires a huge amount of data available anytime, anywhere. The device needs to store payment & location information while authenticating the user, to avoid fraudulent transactions. This is possible through a host of technologies like sensors, communication devices, servers, analytics engines, and decision-making aids that gather data and analyze it before making any decisions.

Wearables offer extensive personalization with an individual focus to every single customer. Banks can use Bluetooth beacons for personal greetings every time a customer enters or exits a location via their smart watches. Smart glasses can help bank tellers process customer banking information while simultaneously doing other customer service tasks, as per a report from Deloitte. The ever-evolving consumer behavior and smart device trends are scaling the consumer banking experience to a whole new level of convenience. Wearable Technology helps to seek customer insights through interaction with other apps, services and technology. Embracing the technology crossover for instance is an ideal method to achieve this. Delivering a bank statement to a customer’s Apple watch or enabling them to make voice-based transactions while driving are two examples of how the banking interactions can be a part of the customer life cycle without being intrusive.

The Way Forward

The pace of the banking technology landscape is increasing and shows no sign of slowing. To excel in this rapidly evolving ecosystem, financial institutions need to devise a clear strategy with a laser-sharp focus on customer preferences; even if this means partnering with FinTech firms or adapting strategies from other industries. Here’s what you can get started with:

  1. Minimize costs by simplifying legacy systems
  2. Develop technological capabilities that can help predict customer intent & retrieve behavior patterns
  3. Build an integrated & user-friendly architecture to connect to anything, anywhere

While all these priorities are equally important and most certainly achievable, to stay relevant, the trick is to combine short-term & long-term initiatives that are aligned to your overall brand vision.

Summary

Even with the best of technologies in place, no one can predict what the future holds for the banking industry. What seems certain however, is that the disruption in the banking sector will continue at a steady pace and banks will continue to transform and embrace digital technologies that are here to simplify the customer experience. Developing a proactive approach rather than responding to trends will define your success in the long run. There is no single technology that is a universal solution, finding the right combination that aligns with your vision will determine your success in the near future.

Read More
Mobile Opinion

6 Revolutionary Technologies That Are Driving Personalization in Retail

Personalization has inherently been associated with digital commerce where technology and data often go hand-in-hand. But owing to the proliferation of new-age tech inside brick-and-mortar stores, the trend is now seeping into retail.

In the past, in-store personalization was mainly attributed to a sales assistant interacting with customers and asking them relevant questions to map their shopping behaviors and needs. Modern-day technologies have been able to capture and scale this behavior towards better avenues of segmentation, customization, and contextualization. Armed with a plethora of solutions, retailers are now able to combine historical cross-platform knowledge of every visitor with a real-time context. A study from Accenture reiterates the importance of such a strategy. According to it, 75% of the customers are more likely to buy from a retailer that leverages personalization elements such as their name, personal recommendations, and preferences.

Image source

The same research also reveals that most of the consumers comfortably share their data with businesses that are transparent about how they use their data and lets them control how the data is used.

Leading Technologies Personalizing Retail

Image source

Even after all this, there is a knowledge gap between the expectations of the market and the response from retailers. For instance, research by Retail Week in the UK revealed that only 14% of retailers consider personalization as an essential consumer experience strategy.

Key Technologies Personalizing Retail

To successfully leverage personalization, it requires a prompt understanding of the customers and their needs in a way that collects, analyzes, and streamlines data. Here’s a look at the various technologies are helping retail companies in this regard:

1. Artificial Intelligence and Machine Learning

Retailers are leveraging AI and Machine Learning to Automate workflows and drive better decisions. With AI, they are now able to track the buying behaviors and lifestyle choices of customers, automate redundant tasks, and improving the productivity of employees. Emerging AI trends in retail include:

  • Customer Insights and Journey Mapping: Natural Language Processing and Machine Learning can sift through copious amounts of customer data to understand them better and accordingly personalizing product recommendations, designs, and end-to-end shopping experiences.
  • Virtual Personal Assistants (VPAs): VPAs such as conversational chatbots can now address customer queries in real-time and at scale. Digital retailers can cater to thousands of customer queries simultaneously, boosting response time and query resolution.
  • Predictive Analytics: By analyzing data about historical sales, marketing campaigns, website interactions, and customer support, prescriptive and predictive modeling is being used in marketing, merchandising, and even hiring.

Sephora

Image source

Case Study: Sephora is equipping its employees with hand-held devices that can scan the faces of customers, capture their exact skin tone, and recommend products by matching it with relevant shades. The AI-powered device even creates a four-digit code that is known as the Color IQ of the customer. All associated data with every ID is then securely stored to personalize future shopping experiences.

2. Voice Recognition Technology

With numerous voice-powered devices such as Amazon Alexa, Apple Home Pod, and Google Home being launched by tech giants, use cases of voice technology in retail have been on the rise. It is revolutionizing shopping by making it more accessible and conversational. This has presented retailers unique opportunities to target more customers by optimizing their digital listings for voice searches. Marketing opportunities that retailers can leverage in this regard include:

  • SEO Optimization: By targeting long-tail keywords that are more oriented towards conversational searches, retailers can optimize their SEO scores and increase their voice search rankings on SERPs.
  • Platform Listings: Product listings on e-commerce websites such as Amazon and Flipkart can also be optimized to improve the chances of being recommended by voice search assistants such as Alexa.
  • Content Marketing: By creating niche content that is specifically targeted for voice searches, retailers can increase the organic footfall on their websites and shift their marketing stance towards inbound.

Starbucks

Image source

Case Study: Coffee giant Starbucks has embraced voice recognition by going a step ahead and including the capability in the My Starbucks Barista app. Customers can directly place their orders with voice commands before they visit their local Starbucks and find their orders waiting for them.

3. Mobile Point-of-Sale Terminals

Research suggests that in the United States alone, more than 50% of all digital shopping would be executed via mobile devices. Retailers are catching on with this trend and leveraging Mobile POS (mPOS) devices inside their stores that are blending the boundaries between digital and in-store shopping.

A mPOS is a smartphone, tablet, or a wireless device that functions as an electronic point of sale terminal. It enables sales associates to conduct financial transactions. Various benefits of this technology include:

  • Reduced queuing and idle time of customers, especially during times of peak footfall.
  • The system can easily collect and store personal information of customers such as their email IDs. Feeding the data in the ERP system and connecting it with marketing campaigns, such as a loyalty program, can then help to retarget these customers in the future.
  • Since the mPOS devices run on a high-caliber point of sale software, they include an added level of security that is backed by reliable servers.

Case Study: Apple has been successful in eliminating cash registers from its stores around the world with the implementation of mPOS. Every store associate is equipped with a mobile device that includes the information of customers and multiple digital payment capabilities. This has helped them to eliminate checkout lines and improve customer experience in a manner that fares well with their brand strategy.

4. Computer Vision and Sensor Fusion

Powered by computer vision, deep learning, heavy-surveillance and sensors, retail giants like Amazon have been working towards the implementation of a next-gen shopping ecosystem. This is being executed with the aim of eliminating redundant steps associated with purchases, checkout, supply chain, and inventory management.

Interestingly, the result amalgamation of these technologies has been dubbed as ‘Just Walk Out’ and works similar to that of a self-driving car. In order to remove human cashiers from the workflow of such a store, it leverages a high level of surveillance on all shoppers. Although there is no intervention of facial recognition technology, the store would use hundreds of cameras to monitor the activities of shoppers.   Powered by computer vision, the core system would be able to identify every object in front of it. As soon as customers pick up products and place them in their shopping carts, the same would be placed in their virtual carts as well. It can even remove the item from this digital cart if a product is put back on the shelf.

Amazon Go stores

Image source

Case Study: Amazon Go stores are leveraging these technologies to extend a cashless and instant shopping experience to their customers. Powered by deep learning and a plethora of smart algorithms, the system is able to identify customers with the help of advanced pattern recognition that draws conclusions from vast datasets. As a result, customers are automatically charged from their credit cards or digital wallets as soon as they walk out of the stores.

5. Robotic Process Automation (RPA)

RPA in the retail industry is paving the way for better productivity by catering to administrative processes such as product scanning, data analytics, and inventory management. This results in better customer relationship management, easier and quicker auditing, reduction in administrative costs, and more. The various use cases of the technology in retail include:

  • Returns Processing: With the ability to make automated changes to the inventory database and billing details, RPA can drive redundant tasks like product returns.
  • Workflow Management: Management of shifts, measurement of time and attendance, auditing of sales activities, performance monitoring, and payroll management can be easily executed.
  • Customer Support Management: Sending real-time updates to customers, extending round the clock customer support, and capturing feedback from customers after the sale.
  • ERP Integration: Tracking price changes, generating reports, monitoring employee vacancies, managing billing, and more.
  • Supply Chain Management: Automation of emails among customers, suppliers, and distributors along with monitoring inventory levels and tracking shipments.

Walmart

Image source

Case Study: Walmart is leveraging RPA along with smart robots to patrol stores and automatically scan shelves for missing items. This will allow them to identify the products that need to be restocked while also identifying pricing details and misplaced items.

6. Indoor Positioning Systems (IPS) and Geofencing

IPS is another leading technology that is overhauling the retail industry by empowering brands to stitch together digital and physical shopping experiences. With IPS, retailers can:

  • Track the movement and location of customers inside their brick-and-mortar stores.
  • Help customers by empowering them to find their way around it and locate the products.
  • Send personalized discounts and offers to customers based on their shopping needs and preferences.
  • Boost the conversion rates of customers by making physical shopping more targeted and personalized.

On the other hand, Geofencing creates a virtual boundary around a physical location. The boundary then acts as a trigger system when customers cross it. For instance, as soon as a customer walks into the store of a particular brand, the app on his/her phone can identify this and automatically switch to the in-store mode. A navigation map can then pop up that displays the exact location of all product types inside the store.

Case Study: Aswaaq, a leading supermarket chain in Dubai, has equipped its stores with a connected lighting system that communicates with its customers. It enables them to find items that are on their shopping lists with an accuracy of 30 cms through the brand’s app.

The Verdict

Successfully mapping the present technological backdrop in retail and planning for future disruptions requires meticulous knowledge about consumer behaviors. Retailers that are able to use data as a precursor to change management while adopting these technologies would be able to foster a sustainable technological ecosystem.

Read More
Mobile Opinion

Building a Meaningful Notification System for Digital Platforms

We all have experienced that annoying feeling when we get too many notifications, seeking actions for tasks that are not particularly important at that moment. Timely notifications are integral to the overall proposition of a platform, but they are fast becoming intrusive in nature. Today’s apps and websites send notifications regarding things that often don’t really require our immediate attention, and they send them repeatedly. These frequent and thoughtless notifications don’t mean anything to the user after a point. We just shut ourselves and cancel them out completely.

The next logical question would be — how do we, as designers, design notification systems, which serve the primary goal of increasing user engagement without disturbing users with unimportant pieces of information?

Firstly, it is important to understand that there are many variables that can affect how people may feel and respond to notifications. A person’s attitude towards a notification on any given day can depend on many factors such as:

  • What is the notification?
  • How is the tone of voice?
  • What is the person doing when he/she receives the notification?
  • What time of the day are they getting the notification?
  • How many times are they getting notified?
  • What is the location of the person when he/she receives the notification?

Before we proceed further, I want to share with you some personal experiences of different notification systems.

Exhibit A

A notification sent by Ola cabs

A notification sent by Ola cabs

Let’s breakdown this notification that I got from Ola Cabs:

  • It is asking me if I fancy an international trip at an hour when I am most probably having my lunch.
  • I usually travel in the mornings or evenings via Ola. Getting this message at a time when I am most likely to book a cab, would have made me interested in it.
  • And at that moment, let’s say I was more interested in going to Bangkok than Nepal. So clearly, I ignored the notification.

Exhibit B

 

Box8 message

Box8 message

  • A notification to save money on lunch, around month end is relevant. I usually order my lunch between 11:30 am – 12:00 pm. And this notification from Box8 meals was timed well. In terms of content, the message or value was conveyed easily.
  • Another factor to decide the importance of this message for me would be my location. This message wouldn’t be of any importance to me if I was at a location where Box8 meals are not available.

As designers, it becomes imperative to consider factors like timing and location of the user that affect their decision, in a positive manner and design notification systems that are pleasing and non-intrusive in nature.

Exhibit C

Picture this — it’s Monday morning, I am late for work. Just as I reached the railway station, I realize that my pass has expired. I need to renew it online or stand in a long queue to buy one. I quickly fill in all the details to buy the pass online. To make the payment, I need to login to my digital wallet. I enter my number and wait to get an OTP.

And the platform sends me this notification:

OTP for Railway Pass Booking

OTP notification for railway pass booking

As you can see, the notification has been constructed in such a way that the OTP number is not visible here. To see the number, I had to leave the platform and open my messages to get the OTP. This may not be a big deal, but it did increase the journey time.

Once I logged in, I proceeded with the payment through my debit card. Another OTP was sent to my phone. But this time I got the following message:

Bank OTP for Railway Pass Booking

Bank OTP notification for railway pass booking

The above notification was created in a way that the first thing I read was the OTP number (which was the only piece of information that mattered to me). And finally, the transaction was successful.

Like me, I am sure many of you have had some bad experiences (and sometimes good too) with notifications on different digital platforms. As designers, we are constantly striving to improve users’ experience on our digital platforms, and notifications are an integral part of this structure.

Design Thinking Workshops to Accelerate Digital Product Development

I am going to share with you a framework for designing effective and meaningful notification systems.

Framework for Notification System

In order to build a notification system that is engaging and does not irk users to the point that they uninstall the application, there are few parameters or “steps” that we can follow:

Framework for Notification System

Identify the intent and value of the notification

The foremost thing to be done is to understand the intent and value of a particular notification to the user. There is no point in wasting a user’s time with meaningless content. A person wouldn’t mind being interrupted as long as what they are getting in return is valuable and interesting. It is human nature to ignore things that are of no value to them. In this context, it is crucial to understand users’ needs and goals.

Nowadays, data analytics plays an important role in helping designers understand users habits and behavior on digital platforms. For example: Discovery+, Amazon Prime, Netflix and Hotstar do a great job of personalizing their push notifications. They use push notifications to let users know when their favorite shows or movies are available. They also analyze the type of content users are watching or the shows they follow and recommend similar content.

Discovery plus recommendations

Recommendations on Discovery+ based on titles you have watched

Origin of the notification

Based on the structure of the digital platform, there are multiple channels through which notifications are directed to the user. The source of these channels is the point of origin for notifications.

Instagram notification

Instagram notification for likes on picture

For example on Instagram, notifications regarding the number of likes your picture gets are part of the activity update channel. These updates are then shown in the notification center as a collective figure.

Building the Message

This section is about the message that is to be delivered to the user through the digital platform. The message content will help the user understand the purpose of the notification and what needs to be done on the platform to achieve his/her goal. Here are a few points that can help build personalized notifications:

A. Information (What)

Users appreciate information that is directly related to their personal interests. They tend to ignore the high frequency of notifications delivering valuable information. While building the information section, we first start with “What”; What information are we passing to the user that would help achieve their goal?

Once you have figured out the “What”, it is time to focus on the tone of voice of the information to be conveyed. It plays an important role in the overall user experience. Language used in the communication is an opportunity through which you can connect the user with the brand. It will help build trust and make the user more attached to your platform. To determine your tone of voice, consider these questions:

  • How is this message going to affect the user?
  • What emotions do you want the user to feel while using your platform?
  • What situation is the user in at the moment?
  • How can you maintain the user’s state of mind or put them in a better one?

Based on the situation, the tone of voice of the message could be serious, authoritative, or even instructive in nature. Take for example, a banking or finance services applications. Sense of security among users is of primary importance to the brand. Hence, they have to take extra care when giving instructions and write content in a manner which exudes a sense of security.

Users also welcome a break from the mundane and enjoy the experience when brands go for a playful and lighter tone of voice. I ordered one of my meals from Box8 and they added a playful touch to the notification regarding my delivery by using the word “Sooperman”.

Box8 delivery update

Box8 delivery update

B. Timing and Location (When)

In order to deliver a successful notification strategy, it’s necessary to provide customers with the right message at the right time. But timing means much more than simply segmenting your users by time zones, or customizing messages according to the seasonal calendar. It means delivering information at the precise moment a customer is likely to take action. Nobody likes to be disturbed in the middle of the night because of a notification to avail discount on a purchase on an eCommerce site.

While figuring out the timing, we must also consider the frequency of notifications. Is it something crucial that the user needs to see twice everyday or would one message a day suffice?

Insider notification

Insider Notification

Let’s consider this message from Insider – it references topical subjects like Avengers and Game of Thrones in the message. The tone of voice no doubt may be great, but the timing of this message could have been planned better. I got this notification on a Saturday morning, when I am not at work and am most likely sleeping. Most of my weekend plans are made on Friday, at work. Had I received this message on Friday, I would definitely have booked something via the app. Notifications at the wrong time are completely useless. Untimely pings get ignored and the sound they create dilutes user interest and may even cause frustration.

Another important variable to consider is the location of the user. Users tend to use an app more if it sends them push notifications triggered by their selected hometown. Let’s say I have recently relocated to Mumbai from my hometown. What if food ordering apps used my location to notify me about the best deals on food near my location or the must-visit restaurants in the new city.

C. Type of notification (How)

Once you have figured out the “what” and “when”, the next step is to figure out the type of notification which is the “how”. In general, notifications can be categorized in the following categories:

User Generated Notifications: This type of notifications are targeted towards specific people. Their content is created by an action of a user on the app. Mobile messaging or WhatsApp messaging are examples for this category.

Context Generated Notifications: These notifications are generated by the digital platform based on user permission. One example of this could be the location based notifications from Zomato or Swiggy, where the apps send you offers and recommendations based on current location.

System Generated Notifications: These notifications are generated by the digital platform based on application needs. These type of notifications can help in re-engagement or some users may term it as spam based on the value they provide.

Push Notifications: All the above notification types can be push notifications also. They ideally appear on the locked screen or at the top without interrupting the user’s activity. These messages have a limited word count as well. Push notifications are of two types. One that requires you to take immediate action and the second one is passive notification. Most of the examples shown above are passive notifications. The image below shows a notification of a Medium article that seeks an immediate reaction:

Push notification with action

Push notification with action

Earlier we only had mobile apps and desktop notifications to design for the user. But the introduction of smart wearables like smartwatches and apple watches have widened the spectrum. These watches are capable of concisely showing the push notifications in a much smaller and personal screen.

Voot notification on a smart watch

Voot notification on a smart watch

Discovery+ notification on an Apple watch

Discovery+ notification on an Apple watch

Output

“Output” is the part where the notification will be displayed on the digital platform. The output section can showcase notifications from multiple sources or just one. Some digital platforms have a separate notification center, where all the notifications are shown to the user, eg. Pinterest and Facebook or LinkedIn. They bundle information about who liked your posts, what people you are following are doing, etc. into a single notification center.

Facebook and Pinterest notification

Single Notification Center Platforms: Facebook & Pinterest

Single Notification Center Platform: LinkedIn

Single Notification Center Platform: LinkedIn

On other digital platforms, every notification is connected to a navigation option which is the origin of the notification as well. For example, WhatsApp has navigation channels like Status, Calls, Chats that are both, the origin and output points for respective notifications.

WhatsApp Navigation Channel

WhatsApp Navigation Channel

Final Thoughts

We, as users, have learnt to identify and avoid notifications, just as we have learned to identify and avoid ads. As designers we need to understand that, if not carefully designed, notifications can become less effective in engaging users with your platform. We need to design notification systems in a manner that messages sent by brands bring value to the users journey.

The framework explained above can be used to design an effective and meaningful notification system for any digital platform. Think of it as a template, that could be applied to any user journey on your platform to enhance its overall notification experience.

Read More
Mobile Opinion

Blockchain and its role in customer experiences across industries

For the last 10 years or so, blockchain technology has gained great visibility and ‘buzz’ in media. Originally meant to serve as the underlying technology for the cryptocurrency Bitcoin, it has been portrayed as a panacea for many industries or at least as a ‘must-have’ for enterprises. Aside from the hype, it has received its share of ridicule too from different quarters. So what is the reality? What are the use case of blockchain across industries? Let’s start with the basics:

What is blockchain?

Blockchain is a universally distributed open ledger system. It comprises a sequential list which records every transaction that has ever occurred in a process. A blockchain is made up of many blocks containing user transactions – and each block points to the previous block. The process of adding new blocks is called mining – a concept made popular in the context of Bitcoin, the crypto currency system. It needs to be clarified that blockchain is not  bitcoin – the technology behind the latter is blockchain. Interestingly, blockchain is referred to as a meta technology as it impacts other technologies. Over the years many blockchain systems have been developed: Ethereum, Hyperledger Fabric and Ripple to name a few.

Some of the hallmarks of blockchain which play a role in its acceptance include:

  • Distributed trust
  • Chronological nature and time stamp
  • Immutability
  • Cryptographic seal

Blockchain: impact beyond finance

The popular perception is that blockchain technology is utilized only by the finance industry. However, the basic nature of the technology makes it suitable for usage across domains.

The blockchain is an incorruptible digital ledger of economic transactions that can be programmed to record not just financial transactions but virtually everything of value.

~ Don & Alex Tapscott, authors Blockchain Revolution (2016).

A few major applications of blockchain include:

A few major applications of blockchain include

 

  • Smart Contracts: any contractual transaction and agreement which is digital
  • Record Keeping: usage across healthcare, real estate, voting
  • Securities: global payments, P2P lending
  • Digital Currency: equity markets, crowdfunding

There are several types of blockchain systems including:

There are several types of blockchain systems including

 

  • Ethereum: Mature Smart Contracting Cross-Industry Platform
  • Hyperledger Fabric: B2B-focused Modular Blockchain Platform
  • R3 Corda: an Operating System for Financial Services
  • Ripple: Enterprise Blockchain Solution for Global Payments
  • Quorum: Enterprise-focused Version of Etheruem

Let’s look at some use cases across select domains:

Retail

Blockchains can help retailers that offer gift cards and loyalty programs make those systems cheaper and more secure. Gyft, an online platform for buying, sending and redeeming gift cards that is owned by First Data, has partnered with blockchain infrastructure provider Chain to run gift cards for thousands of small businesses on the blockchain — the new program is called Gyft Block.

Travel

Singapore Airlines launched KrisPay – a digital blockchain wallet that allows frequent fliers to convert air-miles into digital currency. It will enable travelers to spend their air miles at retail establishments, hotels, petrol stations and other partner merchants.

Logistics

Moving freight is a complex process involving different parties with different priorities. An IoT enabled blockchain can store the temperatures, position, arrival times, and status of shipping containers as they move through the system. Indelible blockchain transactions ensure that all parties can trust the data and take action to move the product quickly and efficiently.

Banking

Majority of banking systems are built on a centralized database, which makes them more susceptible to attacks as all information is stored locally in one place. Also, many banking systems are outdated and are, therefore, more vulnerable to new forms of cyber-attacks. With banking systems built on top of blockchain technology chances of fraud and data theft can be reduced as the distributed ledger technology encrypts and verifies every single bit of data in a transaction.

Automobile Industry

Volkswagen AG is testing three concrete potential applications for distributed ledger technology: mileage clocking system, protecting cars from hackers (for Porsche) and streamlining business contact between providers and customers of electric charging stations.

Real Estate

Blockchain can play a role in buying property to conducting due diligence to enabling crowd-sourced investments. For example, Hilton Worldwide has begun using a blockchain-based property management system. The Dubai Land Department authority used blockchain in Ownership verification, property sale by the developer and smart leasing process.

While Blockchain has use cases across domains its use in Digital Health, Pharma & Life Sciences can perhaps be the most impactful. Currently the healthcare industry faces three major challenges in data collection, data accessibility and data privacy.  To illustrate, counterfeit drugs is a major problem in the healthcare industry: 10% to 30% of the drugs sold in developing countries are counterfeit. WHO estimates that 16% of counterfeit drugs contain the wrong ingredients, while 17% contain the wrong levels of necessary ingredients. Blockchain technology can play a role in drug traceability as the manufacturer produces the drug and marks it with a unique code after which a hash is produced. According to a definition, hashing is the process of taking an input of any length and turning it into a cryptographic fixed output through a mathematical algorithm. Various subsequent steps between the wholesaler, pharmacist and the patient are then added to the blockchain.

Applications of blockchain in healthcare include:

Applications of blockchain in healthcare include

 

  • Solving for Interoperability
  • Securing supply chain
  • Giving patients control of their data
  • GDPR and HIPAA compliance
  • Smart contracts and automation
  • Accelerating clinical trials and R&D

Clinical trials have data management issues leading to inefficiencies in time management. Blockchain can solve such issues by standardizing data sharing. Robosoft’s Blockchain Solution utilizing distributed ledger scripted smart contracts based on Hyperledger Fabric offers guaranteed anonymity required for PHI, fully audited verification of data and more.

As a Top App Development Companies for enterprises, we truly appreciate the role of emerging technologies in crafting digital experiences. Among emerging technologies which have the potential to deeply impact the digital experience and the process behind it, blockchain seems to garner great share of voice. Connect with us to discover how blockchain can play a role in your enterprise.

Read More
Mobile Opinion

Leveraging Technologies to Reshape the Real Estate Industry

Rapid advances in technology have permeated several sectors that anchor a country’s economy. This is a precedent that can also be applied to the real estate industry. Real estate, an asset class worth USD 217 trillion globally, has gradually embraced disruptive technology. It is a dynamic catalyst that will transform the way businesses are conducted in the future. Today, the growing influence of millennials and an investment boom in real estate technology has reshaped this industry around the world, including the Middle East.

Benefits of Technology in Real Estate

Digital transformation in real estate has made it easier for buyers to connect with sellers online and establish meaningful connections. Some of the benefits include:

1. Online 3D Tours

Technology allows global investors to get 3D views of the entire property, which gives the feel of a personal tour, all this at a single click and from anywhere in the world.

2. Real-Time Data

Real estate investors are no longer just looking at the price of a property. Factors such as return on investment, cash flow, and capitalization rate have become critical for investors to make informed decisions. To access such data in real-time, disruptive technologies provide all information at your fingertips. With growing accessibility to such data, the real estate industry has become more transparent and regulated.

3. Portal and Apps

The advent of real estate apps and portals have made it convenient for buyers to search for properties they like, instead of aimlessly driving around the neighborhood. Real estate portals powered by predictive analytics offer personalized and highly-customized data and are rapidly gaining popularity.

Technology in Real Estate in the Middle East

There are nearly 15,000 real estate offices in the Middle East, offering various types of properties, according to Global Real Estate Experts. In an article by Forbes, the UAE is leading the way to embrace digital transformation in the region, creating initiatives aimed at promoting innovation and driving the adoption of digital technologies in the real estate industry. More specifically, Dubai is working towards a strategy focused on blockchain technology to transform its real estate market and implement impactful tech reforms.

According to a plan shared by the Smart Dubai Office, blockchain technology is expected to be implemented for all government documents by 2020. This is a significant step for the real estate sector as most of its investors are seeking innovative ways. According to a study by HSBC, a whopping 72% of buyers in the UAE prefer using technology to gather information about the property, while 67% use technology to check the value of their home, and 64% look at prices of potential homes.

Saudi Arabia, not far behind in its quest to adopt technology in real estate, intends to build its own smart city called Neom. This smart city is part of the kingdom’s Vision 2030, a plan to lower the country’s dependence on oil, diversify its economy, and build public service sectors. Neom will incorporate various smart city technologies and also act as a tourist destination.

How Technology will Transform the Real Estate Industry

How Technology will Transform the Real Estate Industry

Blockchain

Blockchain technology has gained prominence in real estate because it helps lower the fees and processes associated with the industry. It reduces the intermediaries involved and streamlines processes for investors purchasing commercial real estate. This disruptive technology in real estate creates computer-based processes to eliminate paper title deeds, paper licenses, etc. for seamless cross-border transactions. Several companies in Dubai, such as ValuStrat, have integrated blockchain ledgers for the government to issue instant online title deed for properties. However, despite all these benefits, blockchain’s adoption rate seems rather unclear in the near future.

Augmented Reality and Virtual Reality

According to International Data Corporation, in Africa and the Middle East, the VR and AR technologies market is likely to increase from $181.59 million in 2017 to $6 billion in 2020. The use of VR is increasing as it allows visitors and investors to virtually check the properties regardless of their geographic location. The VR experience is not just limited to property touring. It also enables users to visualize any space with various customized design elements, thereby helping the interior design process. Dubai’s real estate giant Jumeirah Group is one of the many companies in the Arabian Gulf Region that are gradually embracing VR or 360 videos to provide virtual tours to buyers and promote their properties.

Smart Cities and Buildings

Smart buildings and cities are no longer a thing of the future. A smart building refers to a structure that deploys technology to automate operations such as lighting, security, and heating. Controlled partly by the Internet of Things (IoT) such technologies help boost efficiency and reduce energy waste. Technology giants like Google, Amazon, and Apple are aggressively investing in the concept of smart home technologies to transform the way people live.

IoT has also paved the way for the Smart City concept, which is being envisioned by the Kingdom of Saudi Arabia for Neom. The primary aim of smart cities is to enhance the quality of life using technology. A smart city integrates IoT solutions with information and communication technology to monitor its assets such as schools, water, libraries, waste management, etc. Technology in real estate can also help control parking, streetlights, and monitor air quality and noise.

3D Printing and Robotics

Construction technology, popularly known as ConTech, is revolutionizing the future of construction in real estate. Presently, construction is heavily dependent on manual processes to operate heavy machines. But companies like Komatsu have created unmanned bulldozers and drones to construct buildings and monitor the construction site.

Unmanned drones are capable of monitoring deliveries, inventory, and progress at the site and then create a 3D map of it. The information gathered by these drones is then used to instruct unmanned bulldozers to allot courses around the site. Construction technology in real estate removes worker safety issues, allowing robots to do manual work while humans focus on more strategic tasks. In 2018, HE Saif Bader Al Qubaisi, General Manager of Abu Dhabi City Municipality, launched the trial phase of using drones in engineering inspection of construction sites in Abu Dhabi.

Project Management Software

Several project management software solutions such as Re-Leased, ProofHub, Qube Project Manager are being deployed in real estate to assist in construction management. This is done to boost efficiency, clarity, and accountability of stakeholders involved in the project and aid in real-time conversations between them.

Chatbots

AI-driven chatbots are not new, with several industries leveraging them to enhance sales and marketing performance. Most of the real estate companies with an online presence have started using chatbots to help investors with standard information related to the property, along with pictures and videos without any human intervention. Since chatbots are 24×7 available, they provide support around the clock and assist buyers in filling contact forms even during odd hours of the day. Chatbots lower the overhead marketing and sales cost and results in higher conversion rates.

Property Management Software

Property management software is being implemented to monitor the performance and downtime of building equipment. This information is given to helpdesk support services and used by maintenance teams to carry out day to day tasks. Property management software tracks the asset’s performance to make the whole process efficient.

Final Thoughts

Technology in real-estate has slowly pervaded the industry, with advancements in nearly all sectors. The efficient adoption of relevant technologies can make or break companies in the future. While the pace at which it is being adopted differs hugely across different parts of the world, one thing is for sure, it will become indispensable in the coming years.

Read More
Mobile Opinion

Customers Are Here To Stay: How AI can Boost Customer Lifetime Value

Retaining customers and building customer lifetime value is a crucial aspect to increase conversions. Digital disruption with the advent of Artificial Intelligence and Machine Learning has resulted in a unique challenge for marketers. Though it allows them to provide customers with experiences like never before, it also opens a myriad of options for consumers to choose from. This may have made customer retention a tricky task for organizations. After all, repeat purchases from existing customers is a sign of a healthy brand, since acquiring new customers can be expensive and may often impact the bottom line. While expanding the value and building lasting loyalty cannot be created overnight, disruptive technologies can help.

Let’s understand how organizations around the world are deploying cognitive technologies such as AI to create brand loyalty and adopt agile strategies using their existing data.

Current Scenario

Most organizations understand the importance of collecting data and do it through several digital marketing strategies. But analyzing and implementing this data still remains a distant dream. At best, companies analyze data in silos for a specific campaign. The result is that these organizations only influence a few touchpoints of the buyer’s journey while focusing on specific data related to online conversion rates. To combat this problem, businesses have slowly started embracing AI and ditching data processing through traditional methods.

Harnessing the Power of AI

There are several ways in which organizations can harness the power of AI to empower decision making. The low hanging fruits such as sales forecasting and cross-sell/up-sell can help companies showcase proof-of-concept while understanding how vital it is to change the company culture for it to be successful. A mindset shift is required if teams want to adopt agile strategies by acting on crucial insights and create longer customer lifetime value. Some of the ways that AI can be incorporated into effective decision making include:

Sales forecasting

Traditionally considered a nightmare by management teams, AI algorithms can predict revenues for the upcoming quarter with higher accuracy. This helps the sales team and leadership to take a data-driven decision and achieve operational excellence.

Cross-sell/up-sell

Cross-selling and or up-selling is the easiest way to increase marketing ROI. To determine which customer segments will have a bigger value, use AI to identify the clients that are likely to upgrade or broaden their purchases across various products/services.

Price optimization

AI-enabled campaigns can help you identify what type of promotions incite buyers to make a purchase.

Up the Ante on Digital Marketing

2019 is the year to up the game in terms of digital marketing. Customers are no longer going to just click targeted ads based on their demographic information. As such, several organizations have started using AI to detect how consumers are engaging with content across different touchpoints. It also identifies marketing messages that may boost audience engagement. These insights are instrumental in refining marketing campaigns and boost overall ROI.

By mapping out the factors that affect customer lifetime value, both marketing and sales teams can create customer loyalty and advocacy programs targeting their most valued customers. AI is no longer being used to only improve the value, it is also forcing marketers to use it as a major KPI metric. Since AI is vital to understand the impact of several aspects of customer behavior, it also helps the team fine-tune their strategies and make metric-driven decisions for improved user experience.

How AI Increases Customer Lifetime Value

How AI Increases Customer Lifetime Value

 

Create Personalised Experiences

AI’s ability to analyze data makes it possible for marketers to deliver personalized experiences to customers and make them feel special. Armed with insights from AI algorithms, teams can deliver relevant content that can further strengthen the relationship and build customer loyalty. Not so long ago, Netflix and Spotify started using AI-driven insights to provide recommendations to its customers, and today, all other brands are trying to provide the same level of personalized recommendations to its customers.

More Sales

AI can transform the way organizations engage customers with their products. By taking advantage of data, AI can be used to create a holistic and hyper-targeted approach that compels customers to purchase more. E-commerce giant, Amazon does a great job by suggesting other products, based on the historical preferences of the customer. As teams gain a deeper understanding of personal preferences, they can deliver tailor-made offers for their customers. In other words, AI equips organizations with tools to create trust and change short-term sales pitches into long-term loyalty.

Renew Faster

When customers are made to feel more valued and understood, they tend to stick around and become advocates of the brand. And as an AI-empowered marketer, the insights will predict what your customers might need next. By incentivizing longer-term commitments, businesses can grow their customer lifetime value at a fraction of the cost when acquiring a new customer.

Visual Search

Customers are gradually moving away from text-based search to more visual searches thanks to advances in AI image recognition and analysis. Platforms like Pinterest and technology such as Google Lens are making it possible for brands to improve merchandising and provide a personalized shopping experience. US retail giant Target’s partnership with Pinterest in 2017 shows their determination to integrate visual search in their e-commerce experience. The partnership allows users to take a picture of an item and find similar products on Target’s website.

Evangelize Eagerly

Implementing AI demands marketers to focus more on lifetime value. When this shift happens, customers see brands as an indispensable entity and start loving it. And with AI’s help in calculating lifetime customer value, organizations can determine the reward for their best customers.

Summary

Traditional marketing channels have considered all customers to be equal. But today, things have changed. Customers demand personalized experiences to make them feel special and build better brand affinity. For this purpose, organizations are embracing AI to make full use of their data, collected at various touchpoints of the customer’s journey. Primarily because not all metric-driven decisions make it easy for everyone to collaborate and create a customer-centric business model.

AI-driven marketing empowers teams to deliver better ROI (Return on Investment) from their marketing investment. It also helps businesses and companies make data-driven decisions and see what works for their brand and what doesn’t by forecasting sales, up-selling/cross-selling, and renewing clients’ contracts. Thereby, accelerating customers ‘ purchasing decisions and help organizations better tailor their content strategies.

Read More
Mobile Opinion

Configuring iOS Builds – a step-by-step guide

Build configuration is a way of arranging, tweaking and changing the settings of a build using a build system. The configuration defines how a build generation process should work, what properties should be applied to the build and what all aspects should be taken care of. In our earlier article, we outlined how to configure Android builds. In this article, we will talk about why developers must configure iOS builds and how to do it. Read on.

Why configure?

  • There are various reasons to configure builds. A few of them are;
  • If a project requires to support multiple environments like DEV, QA, STAGING and PROD
  • If a project requires different build types (like debug and release)
  • If a project requires a way to modify dependencies without changing the application source code
  • If project requires to have builds automated
  • If a project has different API keys for different environments. This might be required for each library integrated within the application
  • If a project has a requirement not to commit keys and secrets it uses to source code management system
  • If a customer wants builds of different environments to co-exist in the device

These are only a handful. There might be other reasons too.

It’s recommended to store our keys and secrets securely. In a real application, we would either get these from our server or encrypt and store them using standard encryption techniques.

The fields shown here are for demonstration purposes only.

It’s also important not to commit secure configuration properties to SCM (Git/SVN), especially, if SCM is in a public repository.

Utilise techniques such as .gitignore to prevent these from being committed to SCM.

We can also have template config files with only keys (with values being empty) while committing. We can get these inserted to build systems before generating the builds.

How to Configure?

Before jumping onto see how to configure builds in iOS, let’s assume our requirements so that it will be easy for us to scope the discussion. Our assumptions are;

  • Our project has three different ENVs (environments) namely, dev (development), stg (staging) and prod (production)
  • We want to use different API URLs, keys and secrets for each ENVs
  • We want to use different bundle identifiers for each of the ENVs so that, builds with different ENVs can co-exist in a device
  • We want to use labelled app icons for dev and staging

Now that we know what all we have to do, let’s dive in to see how to do them.

Xcode provides fantastic support for configuring builds in iOS. It has a build settings pane where we can add/edit build settings, it has a scheme editor pane where we can create multiple schemes and it also provides special type of files with extension .xcconfig to support configuration supply to the build system.

Our application is called Places. It allows users to add and share details of the places they visit. Let’s start by adding three configuration settings files to our project.

Configuration settings files are provided in Xcode for specifying build settings. These files have an extension .xcconfig and are used to define and override build settings for a build configuration of a project or target.

More on these files can be found at https://help.apple.com/xcode/mac/current/#/dev745c5c974

In Xcode, goto menu File → New → File… (or press ⌘N). Locate Configuration Settings File and click Next.

Locate Configuration Settings File and click Next.

Name it dev.xcconfig. Leave Targets checkbox as is. Click on Create.

Name it dev.xcconfig. Leave Targets checkbox as is. Click on Create.

Repeat the above steps to add stg.xcconfig and prod.xcconfig files. These config files we just added are plain text files which can be edited even outside of Xcode. They are ideal for supplying build settings and other configurable properties to the build system without modifying the source code. Hence, if we have a requirement not to commit these config files to SCM, we can omit them.

Contents of these files are key-value pairs and they take the form Key = Value. Various value types are supported. A few of them are – boolean, string, string list, path and path list.

Now that we have added three files, they should look like as shown in below image.

Now that we have added three files, they should look like as shown in below image.

Our app development connects to our server to fetch places data which has three different ENVs namely dev, stg and prod. Hence, the base URLs are;

Dev: http://api.places.com/dev/ (Note the http scheme)
Stg: https://api.places.com/stg/
Prod: https://api.places.com/

Also, we would name our app bundle identifiers as;

Dev: com.places.ios.dev
Stg: com.places.ios.stg
Prod: com.places.ios

As you can see above, the base URLs and bundle identifiers have some components in common. URLs have same host components. Bundle identifiers have com.places.ios as common. Hence, instead of repeating these in all three files, we can have a common.xcconfig file and define them there. Later, we can include this file in all three files.

Add common.xcconfig by following previous steps. Now add the common properties in common.xcconfig so that it looks like below.

Add common.xcconfig by following previous steps.

Since our schemes differ for dev and other two configurations, we use a separate SCHEME field in the common.xcconfig and set it to https (imagine it as a default value).

Notice that we have also added BUNDLE_VERSION_STRING and BUILD_NUMBER fields to the common.xcconfig. Moving forward, we can change application version and build number directly from config file.

Now, let’s include these in other three files and add ENV specific properties. Our dev.xcconfig now looks like below.

#include "common.xcconfig"
 
SCHEME = http
 
// ENV specific
ENV_NAME = dev
 
// Bundle Id suffix
BUNDLE_ID_SUFFIX = .$(ENV_NAME)
 
// API path
API_PATH = $(ENV_NAME)/
 
// Analytics API key and secret
ANALYTICS_API_KEY = 783fa804f48d2952c22bf6653ce4474f
ANALYTICS_API_SECRET = f93754758b5b7f242f89b8d38223e836

#include statement in the first line imports build configurations from common.xcconfig file. Property ENV_NAME is assigned a value of dev so that, this can be substituted in other required places. Notice how we are substituting value of ENV_NAME property to BUNDLE_ID_SUFFIX and API_PATH properties using $() syntax. Later, we are going to construct complete base URL and bundle identifiers using these respectively. Last two lines represent API key and secret required by the analytics SDK we are planning to integrate. As we want to keep analytics specific to ENVs, we use different keys and secrets for dev, stg and prod. Similarly, if we have any other ENV specific properties, we can add them to respective .xcconfig files.

Below are the contents of stg.xcconfig file

#include "common.xcconfig"
 
// ENV specific
ENV_NAME = stg
 
// Bundle Id suffix
BUNDLE_ID_SUFFIX = .$(ENV_NAME)
 
// API path
API_PATH = $(ENV_NAME)/
 
// Analytics API key and secret
ANALYTICS_API_KEY = 8b383b32443c343d8e97ae2a2cbbb986
ANALYTICS_API_SECRET = e335d54b5043dcda6ee13a688a7539fc

and prod.xcconfig file.

#include "common.xcconfig"
 
// ENV specific
ENV_NAME =
 
// Bundle Id suffix
BUNDLE_ID_SUFFIX = 
 
// API path
API_PATH = 
 
// Analytics API key and secret
ANALYTICS_API_KEY = b76748fc63ede06d366f0e55cb447ded
ANALYTICS_API_SECRET = 78e6376ebbab8cf71c5cbc388e7f24cb

Notice in prod.xcconfig, we have omitted BUNDLE_ID_SUFFIX and API_PATH values, as they are not required (Remember, our prod URL is api.places.com/ and prod bundle id is com.places.ios, which are already mentioned in common.xcconfig). Also note that, we haven’t added SCHEME field in neither stg nor prod configs. They take the default value of https mentioned in common.xcconfig.

In case you have same schemes (say https) for all ENVs, we can construct the URL with scheme and host together in a single BASE_URL field like https://api.places.com/

However, there is a catch. Settings configuration files do not directly support URLs. If you try adding a full URL with scheme and host as above, substring that starts with // is treated as comment and when it’s read we will only see https:
Even wrapping them in double quotes does not work.

The solution is to use a dirty trick to reconstruct the URL as below.

BASE_URL = https:/$()/api.places.com/

The $() above substitutes the empty string in between forward slashes.

Now that we have added and filled our config files, let’s inform Xcode where to use them. Go to project navigator, click on your project file and in the editor area, select Places under PROJECT section as shown below.

Configurations

In the above image, under Info tab, notice the Configurations section marked as #3. It already contains Debug and Release as two default configurations (#4). Since we have three different ENVs, we would like to have Debug and Release configurations for each of the ENVs. Click on the + button below the Configuration section and select Duplicate “Debug” Configuration option. A new configuration named Debug copy will be created in an editable format .Change the name of the configuration to Debug(dev). Similarly, create one more copy of Debug and rename it to Debug(stg).

Repeat the same process to create two copies of Release configuration (by selecting Duplicate “Release” Configuration option) and name them Release(dev) and Release(stg). Now we have created Debug and Release configurations corresponding to dev and stg ENVs. Let’s keep the original Debug and Release configurations for prod. Once completed, they look like as shown in the image below.

 “Release” Configuration

Now, let’s link our .xcconfig files to these configurations we just created. Click on the small disclosure triangle placed left to Debug configuration. When it is disclosed, it shows a project file and a target below it. Click on the popup button in front of the project file and select prod from the options. Similarly, disclose Debug(dev) and choose dev from the popup in front. Repeat this for all the configurations so that the section looks like as shown in below image.

Config_set

In the above image, under each configuration, we have a project file icon and a target icon. It’s possible to have multiple targets under the one project. We are adding our settings configuration files at project level. This indicates, the target under that project also gets those settings.

By default, project level settings are carried over to targets belonging to the project. However, each target can override these settings if needed.

In case we are planning to use CocoaPods for our dependencies, then target specific .xcconfig files are added by CocoaPods automatically.

Let’s add Crashlytics to our project using CocoaPods. Close the Xcode project if it’s open already. Open a terminal window and cd to our projects base directory. Create a Podfile using command below (assuming our project directory is in user’s Desktop directory).

Vishnus-MacBook-Pro:~ vishnu$ cd ~/Desktop/Places
Vishnus-MacBook-Pro:Places vishnu$ vi Podfile

In the window that opens vi editor, enter character i so that vi goes into edit mode. Enter below code.

platform :ios, ‘10.0’

target ‘Places’ do
use_frameworks!

pod ‘Fabric’
pod ‘Crashlytics’
end

Press ESC key then : (colon). At the colon prompt that appears, enter wq keys to save and quit vi. Now do a pod install. Terminal looks as below.

Vishnus-MacBook-Pro:~ vishnu$ pod install
Analyzing dependencies
Downloading dependencies
Using Crashlytics (3.10.2)
Using Fabric (1.7.7)
Generating Pods project
Integrating client project
Sending stats
Pod installation complete! There are 2 dependencies from the Podfile and 2 total pods installed.
Vishnus-MacBook-Pro:Places vishnu$

Now go to the project base folder in the Finder and open Places.xcworkspace file by double clicking it. From now on, we’ll use Places.xcworkspace to open our project instead of Places.xcodeproj.

If you are configuring an existing project which already has CocoaPods integrated, just delete <ProjectName>.xcworkspace, Podfile.lock and Pods folder and redo a pod install. This will recreate pod specific .xcconfig files.

Now if we open our .xcworkspace file and check configurations section, pod specific .xcconfigs will be added for each target, as shown in below image.

.xcworkspace file and check configurations section

Now that we have our configurations ready, let;’s check where these are available for us as settings. Select project file in navigation area → select Places under TARGETS section → select Build Settings tab → scroll down to User-Defined section, as shown in the image below. All fields added in .xcconfig files will be available here.

select Places under TARGETS section → select Build Settings tab → scroll down to User-Defined section

We have added these as build settings. So, they will be available for the build system while building. But, we need to access some of these in code (ex: BASE_URL). For this, we’ll have to expose these to our Info.plist file, so that those fields can be available to us at runtime. Let’s add those fields to our Info.plist file by editing it (We can add new entries by going to Editor menu → Add Item or by Control click → Add Row).

After this, our Info.plist looks like as shown in the image below.

Editor menu → Add Item or by Control click → Add Row)

We have added BaseURL, APIKey and APISecret entries and substituted values from build configurations. Notice how values are constructed from components to make final values.

BaseURL has a value $(SCHEME)://${BASE_URL}$(API_PATH)
If we take dev.xcconfig values and replace above keys, we get http://api.places.com/dev/

Similarly, we have edited few existing keys to give new values from our .xcconfig files. We have modified Bundle identifier, Bundle name, Bundle version string, short and Bundle version so that we can control these from our configs.

Now that we have our Info.plist ready, let’s see how we can make it update based on the ENVs that we have. Also, let’s examine how to generate builds based on ENVs. Notice that, above we have modified our Info.plist to name our application based on ENV, that is, $(PRODUCT_NAME)$(BUNDLE_ID_SUFFIX) (Ex: Places.dev, Places.stg).

Select scheme menu at the top left corner of the Xcode toolbar and choose Manage Schemes… as shown in the image below.

Select_manage_schemes

In the window that opens, select Places row and click on gear icon below. Select Duplicate as shown below.

Select Duplicate

In the new panel that opens with editable name field, rename scheme to Places(Dev) and click Close button as shown below.

Rename scheme to Places(Dev) and click Close button

Repeat the above steps to create Places(Stg) scheme. When done, the list of schemes will be as shown in below image.

Scheme_list

Notice the Shared column with checkboxes in the image above. Make sure they are checked for all the schemes we added. If these are unchecked, the schemes will not be available to others, when you check-in your code.

Now, we need to define the build types for each of the tasks. Double-lick on the Places(Dev) row above to go to the edit scheme screen. For each of the tasks listed in left, change the build configuration to respective configuration, as shown in the example image below.

Edit_configs

Run → Info tab → Build Configuration → Select Debug(dev)
Test → Info tab → Build Configuration → Select Debug(dev)
Profile → Info tab → Build Configuration → Select Release(dev)
Analyze → Build Configuration → Select Debug(dev)
Archive → Build Configuration → Select Release(dev)
Repeat the above steps for Places(Stg) scheme as well.

Once the scheme editing is done, let’s see if things we have done till now are in place. Let’s try to access keys we have added in our Info.plist so that we can verify if we are getting expected values at runtime. Open ViewController.swift file and change viewDidLoad method to look like below.

override func viewDidLoad() {
    super.viewDidLoad()
    // Do any additional setup after loading the view, typically from a nib.
   
    print("Name: (Bundle.main.infoDictionary?["CFBundleName"]! ?? "")")
    print("Version: (Bundle.main.infoDictionary?["CFBundleShortVersionString"]! ?? "")")
    print("Build#: (Bundle.main.infoDictionary?["CFBundleVersion"]! ?? "")")
    print("Base URL: (Bundle.main.infoDictionary?["BaseURL"]! ?? "")")
    print("API Key: (Bundle.main.infoDictionary?["APIKey"]! ?? "")")
    print("API Secret: (Bundle.main.infoDictionary?["APISecret"]! ?? "")")
  }

Select Places(Dev) from the scheme menu and run the application. You will see logs like below in the console.

Name: Places.dev
Version: 0.1
Build#: 1
Base URL: http://api.places.com/dev/
API Key: 783fa804f48d2952c22bf6653ce4474f
API Secret: f93754758b5b7f242f89b8d38223e836

These output values correspond to the values we have configured for the dev.xcconfig file. Try selecting other schemes from scheme menu and observe the output. We can also observe that, once these schemes are run, three separate apps co-existing in the device/simulator.

Apps_homescreen

Those icons are default and not looking great. Let’s see how we can add scheme specific icons now.

Open Assets.xcassets folder in Xcode sidebar and click on AppIcon and drag & drop all the icons for prod scheme as shown below.

Prod_icons

To add dev and stg icons, create a new iOS App Icon set, by clicking + button below, select App Icons & launch Images → New iOS App Icon. Rename it to AppIcon-dev as shown in below image. Add all icons. Repeat the above steps to create AppIcon-stg app icon set as well.

App_iconset

Finally, let Xcode know which app icon set to use for each build. Open target settings → select Build Settings tab, search for AppIcon. In the Asset Catalog App Icon Set Name settings, edit the app icon set names for respective configurations as shown below.

Set_icons

Build and run all the schemes to see three separate apps installed on the device/simulator with respective icons (Preview app in OS X can be used to add labels on the icons).

(Preview app in OS X can be used to add labels on the icons).

One last thing related to configuration. Sometimes, we might need to include bespoke files based on environments in the build. One such example is GoogleService-Info.plist file which we download from google console and include in the project, for google API services. In case we need to maintain separate GoogleService-Info.plist file, one per environment, then we can achieve this by creating a custom run script build phase in Xcode.

Start by creating three folders inside your project target directory namely dev, stg and prod. Copy respective GoogleService-Info.plist files downloaded from Firebase to respective directories created.

Google_services_plist

In Xcode, go to project target, select Build Phases tab and click on the + button, select New Run Script Phase as shown below. Rename the run script phase to Copy GoogleService-Info.plist.

New_run_script

Expand the disclosure triangle to edit the run script phase. In the script editor area, add the script to copy respective GoogleService-Info.plist file to the app bundle as shown below.

Copy_script

Below is the script to copy file.

# Name of the file we're copying
GOOGLESERVICE_INFO_PLIST="GoogleService-Info.plist"
 
# Reference to the destination location for the GoogleService-Info.plist
PLIST_DESTINATION=${BUILT_PRODUCTS_DIR}/${PRODUCT_NAME}.app
 
# Target directory of our project
TARGET_ROOT=${PROJECT_DIR}/${TARGET_NAME}
 
# Check and copy files
if [ "${ENV_NAME}" == "dev" ]
then
 
    SOURCE_FILE_PATH="${TARGET_ROOT}/dev/${GOOGLESERVICE_INFO_PLIST}"
    echo "Source: $SOURCE_FILE_PATH"
 
    if [ ! -f $SOURCE_FILE_PATH ]
    then
        echo "No Development GoogleService-Info.plist found. Aborting!"
        exit 1
    else
        echo "Copying GoogleService-Info.plist from dev directory"
        cp "${SOURCE_FILE_PATH}" "${PLIST_DESTINATION}"
    fi
 
elif [ "${ENV_NAME}" == "stg" ]
then
 
    SOURCE_FILE_PATH="${TARGET_ROOT}/stg/${GOOGLESERVICE_INFO_PLIST}"
    echo "Source: $SOURCE_FILE_PATH"
 
    if [ ! -f $SOURCE_FILE_PATH ]
    then
        echo "No Staging GoogleService-Info.plist found. Aborting!"
        exit 1
    else
        echo "Copying GoogleService-Info.plist from stg directory"
        cp "${SOURCE_FILE_PATH}" "${PLIST_DESTINATION}"
    fi
 
else
    SOURCE_FILE_PATH="${TARGET_ROOT}/prod/${GOOGLESERVICE_INFO_PLIST}"
    echo "Source: $SOURCE_FILE_PATH"
 
    if [ ! -f $SOURCE_FILE_PATH ]
    then
        echo "No Production GoogleService-Info.plist found. Aborting!"
        exit 1
    else
        echo "Copying GoogleService-Info.plist from prod directory"
        cp "${SOURCE_FILE_PATH}" "${PLIST_DESTINATION}"
    fi
fi

This article was in continuation of – Configuring Android Builds – a Step-by-Step Guide.

Read More
Mobile Opinion

Gig Economy and the Impact of Technology on Vendor Management Systems

The gig economy is going global. In the US, estimates show that more than one-third of the people work as freelancers. Asia leads the freelancer market globally and is still growing.

There are several factors that have led to the growth of the freelance economy over the years.

  • There is a growing number of Gen-Z into the workforce and for them having a flexible schedule is important, hence they choose to work independently over a regular day’s job.
  • By 2020, millennials will be largest workforce in the global economy. They are very clear and specific with what they want from their employers, and freelancing gives them the opportunity to work with a wide spectrum of organizations.
  • The rising cost of living is another major reason for the growth of freelancers. People are working on multiple short-term projects including their day-job to augment their income. According to a survey, 4 out of 10 people have a side job to supplement their current income.
  • Beyond all the above examples, technological advancement remains one of the major reasons why the freelancer economy is growing. Cloud has opened up innumerable opportunities with the scope of accessing data anywhere, with a decent internet connection. This fact has helped enterprises hire freelance workers with specialized skills on a short-term basis.

The Growing Freelancer Economy

With the rise of a generation that demands flexible timings and looking to supplement their earning potential, the freelancer economy is growing and a number of people are becoming comfortable with it. According to a report:

  • 72% have the amount (or more) of work that they want
  • 92% expect work opportunities for freelancers to increase in the future
  • 90% believe the best days are ahead for freelancing

There are ample opportunities in freelance work, where gig workers can earn substantially. The report mentioned above also found that 82% of freelancers have earned more when compared to others, with similar experiences or work.

Owing to the popularity of this trend, even enterprises are cashing in on this huge pool of talent from multiple domains and skillsets – marketers, designers, developers, recruiters, and many more. Almost every skillset an enterprise requires can be found in freelancer marketplaces such as Upwork or Yoss.

Enterprises of Every Scale are Choosing Freelancers

According to a recent survey, business leaders expect to achieve a 66:34 split between permanent and temporary workers by 2023. Some of the biggest enterprises like Bloomberg, Conde Nast, and even Facebook employ freelancers for multiple projects.

Facebook engages freelancers for a number of purposes such as content writing, checking technical bugs, advertisements, etc. Conde Nast has a team of freelancers for an array of jobs such as beauty closet freelancers, bookings assistant, magazine photo assistant, and photo producer. It often uses freelance writers for filling up editorial spaces in many of its publications. Similarly, Walmart employs freelancers to execute jobs like digital content designers, pricing analysts, and temporary bilingual specialists.

There are various reasons why enterprises of every scale are choosing to work with freelancers. Some of these are:

  • Increasing adoption of new technologies that allow for greater workplace flexibility such as collaboration tools and offer businesses a more flexible approach to how they manage key project initiatives and workload fluctuations
  • Difficulty in acquiring specific skills on a permanent basis owing to the worldwide war for talent
  • Ever-evolving complexity and dynamic nature of traditional job roles.

Challenges of Working With a Contingent Workforce

While there are numerous benefits of having a contingent workforce, it also comes with its set of challenges to manage them. Some of these are-

Challenges of Working With a Contingent Workforce

 

  • Compliance risk – Not always will an enterprise find a freelancer who may match its standards and work according to compliance practices. It is important to choose a vendor who meets the requirements of an organization in terms of both compliance and performance.
  • Quality risk – It is difficult to gauge the delivery quality of a vendor beforehand and check if references and work samples provided are authentic. It can also become tedious to do background checks for every vendor while working with multiple of them.
  • Limited visibility in a multiple vendor set up – While engaging multiple vendors it becomes extremely difficult to manage the data of each one of them. It is important to have a centralized data storage solution for managing vendor data, and also manage & allocate resources efficiently.
  • Data management – While it is really important to have a consolidated storage solution for managing vendor data, this also benefits the organization from a centralized view and enhanced visibility that can lead to better resource allocation and improved efficiency.
  • The complexity of data storage – Depending on the number of vendors it can become extremely complex to store, retrieve and manage data from multiple vendors on multiple projects.
  • Complexity in vendor payments – Managing vendor payments is extremely important. While working with multiple vendors it is essential to adhere to different payment terms in reference to the vendor data and ensure timely payments, which can become tedious without an automated platform.

Benefits of Deploying a Vendor Management System (VMS)

Vendor management can empower enterprises in controlling costs, reducing risks source and manage & deliver value from the contingent workforce. Some of the benefits of employing vendor management systems are –

Benefits of Deploying a Vendor Management System (VMS)

 

  • Efficient Selection of Vendors – The right vendor management system can provide your, organization with a large selection of vendors, and ensure that you can choose the correct vendor in the given budgets.
  • Efficient Contract Management – Managing a multiple vendor scenario requires managing multiple documentations, contracts, compliance management, etc. A vendor management system can provide a centralized view of all contracts and other useful information, thereby helping in efficient vendor management and enable you to achieve better decision-making capabilities to save valuable time.
  • Better Vendor Performance Management – Implementing a vendor management system can provide your enterprise with an integrated view of the performance of all vendors. It also helps to gather timely intelligence about all the operations and take timely actions, ultimately leading to improved efficiency that in turn enhances the organization’s overall performance.
  • Better Vendor Relationship – Managing multiple vendors can be an uphill task in the lack of an automated platform. A vendor management system can help your organization easily manage, pay and maintain a long-term relationship with all your vendors.

Technologies Augmenting VMS Platforms

As the technology landscape evolves, legacy VMS platforms are evolving too by adopting new-age technologies. The ones reshaping the industry are –

  • Machine Learning and Artificial Intelligence

ML and AI technology can also help choose the right vendor and assign the right work model, based selected vendor’s work history and also manage legal compliance. ML and AI can also help in building customized dashboards to manage and view vendor data as required.

  • Mobile Device Platforms and Apps

Mobile platforms can help in managing multiple vendors on-the-go. Vendors and managers can engage with the VMS anytime and from anywhere and log-in relevant information, status, etc. Mobile can help in offering a great user experience to vendors and managers.

  • Predictive Analytics

With the increase in data volume and data capture fields, technologies like predictive analytics are helping track and measure past behavior and provide predictive analytics on market trends. Besides, it can also help manage vendor data and drive insights from the data.

One example of how predictive analytics augments vendor management is IQN’s cognitive intelligence engine, named ATOM (Automated Talent Ontology Machine). This harnesses predictive analytics to provide real-time recommendations on rates, time-to-fill, labor demand modeling and industry benchmarking

The Future of Vendor Management System

With various forms of freelancer work-force evolving – be it individual or through a staffing firm – the VMS platforms will assist to compare, vet, select and onboard different types of third-party talent side-by-side through integrated systems. The VMS of the future will be about sourcing, provisioning and managing all forms of non-employee talent.

With the rise of the contingent workforce an organization uses, a VMS will need to provide a more secure and efficient platform for risk management. In this scenario, there is an opportunity for the evolution of a blockchain-like architecture ultimately be used to manage this sort of information, tied to a platform-as-a-service (PaaS) model for sharing across diverse VMS and services procurement systems.

Also, technologies like AI/ML, etc. will help to create VMS platforms that not just help organizations with vendor intelligence but business and market intelligence as well. Giving information beyond labor rate intelligence.

As the contingent workforce and employees work side-by-side for enterprises, VMS platforms will help talent teams bridge the gap between managing both and tap into & manage workers with specialized skills and drive value to the businesses.

Read More
Mobile Opinion

Configuring Android Builds – a step-by-step guide

Build configuration is a way of arranging, tweaking and changing the settings of a build using a build system. The configuration defines how a build generation process should work, what properties should be applied to the build and what all aspects should be taken care of.

In this article, we will outline why developers must configure builds and how to do it. Read on.

Why configure?

There are various reasons to configure builds. A few of them are;

  • If a project requires to support multiple environments like DEV, QA, STAGING and PROD
  • If a project requires different build types (like debug and release)
  • If a project requires a way to modify dependencies without changing the application source code
  • If project requires to have builds automated
  • If a project has different API keys for different environments. This might be required for each library integrated within the application
  • If a project has a requirement not to commit keys and secrets it uses to source code management system
  • If a customer wants builds of different environments to co-exist in the device
  • These are only a handful. There might be other reasons too.

It’s recommended to store our keys and secrets securely. In a real application, we would either get these from our server or encrypt and store them using standard encryption techniques.

The fields shown here are for demonstration purpose only.

It’s also important not to commit secure configuration properties to SCM (Git/SVN), especially, if SCM is in a public repository.

Utilise techniques such as .gitignore to prevent these from being committed to SCM.

We can also have template config files with only keys (with values being empty) while committing. We can get these inserted to build systems before generating the builds.

How to Configure?

Before jumping onto see how to configure builds in Android, let’s assume our requirements so that it will be easy for us to scope the discussion. Our assumptions are;

  • Our project to have three different ENVs (environments) namely, dev (development), stg (staging) and prod (production)
  • We want to use different API URLs, keys and secrets for each ENVs
  • We want to use different application IDs for each of the ENVs so that, builds with different ENVs can co-exist in a device
  • We want to use labelled app icons for dev and staging

Now that we know what all we have to do, let’s dive in to see how to do them.

Android Studio uses Gradle as the default build system. Gradle allows us to configure builds using build.gradle file entries, where we can define multiple build types, add product flavours and come up with build variants.

For the purpose of this article, let’s assume an application called Places. It allows users to add and share details of the places they visit. Let’s see how we can setup three different environments of our app.

Gradle scripts (build.gradle files) in Android Studio are written in a Domain Specific Language (DSL) called Groovy. It allows us to read external files from within the script so that we can separate out our configurable properties.

More on groovy can be found at http://groovy-lang.org/

We can achieve external configurations read in various ways in Android. We can store different environment properties in xml files, which are placed in respective flavour directories. Or we can create different .properties files and read the configurations from them during build. Or we can directly add them in build.gradle. However, as we want to secure our properties by keeping them in separate files, let’s go with creating .properties files.

This article walks through the configuration steps on a Mac OS. Same steps hold good for Windows and Linux systems too.

Create a new directory named config in the project root directory.

Create a new directory named config in the project root directory.

Create three files namely dev.properties, stg.properties and prod.properties in the config directory created as shown in the image below.

config directory

These config files we just added are plain text files which can be edited using any text editor. They are ideal for supplying build settings and other configurable properties to the Gradle build system without modifying the source code. Hence, if we have a requirement not to commit these config files to SCM, we can omit them.

Contents of these files are key-value pairs and they take the form Key = Value. Various value types are supported. A few of them are – boolean, string, number.

Our app connects to our server to fetch places data which has three different ENVs namely dev, stg and prod. Hence, the base URLs are;

Dev: http://api.places.com/dev/ (Note the http scheme)
Stg: https://api.places.com/stg/
Prod: https://api.places.com/

Also, we would name our app bundle identifiers as;

Dev: com.places.android.dev
Stg: com.places.android.stg
Prod: com.places.android

Notice that we have also added VERSION_CODE and VERSION_NAME fields to the .properties files. Moving forward, we can change application version number and version string directly from these .properties files.

Our dev.properties now looks like below.

# Bundle Id
APPLICATION_ID = "com.places.android.dev"
 
# Bundle versions string, short
VERSION_CODE = "1"
VERSION_NAME = "0.1"
 
# Base URL
BASE_URL = "http://api.places.com/dev/"
 
# Analytics API key and secret
ANALYTICS_API_KEY = "783fa804f48d2952c22bf6653ce4474f"
ANALYTICS_API_SECRET = "f93754758b5b7f242f89b8d38223e836"

Last two lines represent API key and secret required by the analytics SDK we are planning to integrate. As we want to keep analytics specific to ENVs, we use different keys and secrets for dev, stg and prod. Similarly, if we have any other ENV specific properties, we can add them to respective .properties files.

Below are the contents of stg.properties file

# Bundle Id
APPLICATION_ID = "com.places.android.stg"
 
# Bundle versions string, short
VERSION_CODE = "1"
VERSION_NAME = "0.1"
 
# Base URL
BASE_URL = "https://api.places.com/stg/"
 
# Analytics API key and secret
ANALYTICS_API_KEY = "8b383b32443c343d8e97ae2a2cbbb986"
ANALYTICS_API_SECRET = "e335d54b5043dcda6ee13a688a7539fc"

and prod.properties file.

# Bundle Id
APPLICATION_ID = "com.places.android"
 
# Bundle versions string, short
VERSION_CODE = "1"
VERSION_NAME = "0.1"
 
# Base URL
BASE_URL = "https://api.places.com/"
 
# Analytics API key and secret
ANALYTICS_API_KEY = "b76748fc63ede06d366f0e55cb447ded"
ANALYTICS_API_SECRET = "78e6376ebbab8cf71c5cbc388e7f24cb"

Note that, url schemes of BASE_URL for stg and prod are https.

Notice the key-value pairs added in the above files. They are all mentioned as strings within quotes. We are doing it purposely as we are reading them from within gradle files. More on this later.

Now that we have added and filled our config files, let’s inform Gradle where to use them. The idea is to read these configuration files based on the need and assign properties to build configuration so that, they can be read in our code. Some of the properties like APPLICATION_ID, VERSION_CODE and VERSION_NAME can also be substituted in our build.gradle file at build time.

Let’s open our project level build.gradle file in Android Studio and add an ext (ExtraPropertiesExtension) entry in it like below.

ext {
   // Get the current flavor of the build Ex: dev, stg, prod
   flavor = getCurrentFlavor()
   if (flavor.isEmpty()) {
       flavor = "dev"
   }
 
   // Read the .properties for config
   config = getProps('config/' + flavor + '.properties')
}

We are doing two things in above code block. First, identifying the current build flavor (ex: dev, stg or prod). Second, read the corresponding .properties file located in the config directory. That is, if the current build flavor is dev, read dev.properties file and save it in config variable.

We haven’t created build flavors yet. We’ll get to it moving on.

We also have two methods being called in the above code getCurrentFlavor() and getProps(). Let’s check what they look like.

def getCurrentFlavor() {
   Gradle gradle = getGradle()
 
   // match optional modules followed by the task
   // [a-z]+([A-Za-z]+) will capture the flavor part of the task name onward (e.g., assembleDevRelease --> Dev)
   def pattern = Pattern.compile("([A-Z][A-Za-z]+)(Release|Debug)")
   def flavor = ""
 
   gradle.getStartParameter().getTaskNames().any { name ->
       Matcher matcher = pattern.matcher(name)
       if (matcher.find()) {
           flavor = matcher.group(1).toLowerCase()
           return true
       }
   }
 
   return flavor
}

The above method extracts the flavor name from one of the gradle tasks and returns. It uses a regex to do this job.

def getProps(path) {
   Properties props = new Properties()
   props.load(new FileInputStream(file(path)))
   return props
}

getProps() reads a properties file from given path and returns its contents.

The complete project level build.gradle is given below. Notice the import statements for Matcher and Pattern classes utilised in our custom methods.

import java.util.regex.Matcher
import java.util.regex.Pattern
 
// Top-level build file where you can add configuration options common to all sub-projects/modules.
 
buildscript {
   ext.kotlin_version = '1.3.11'
   repositories {
       google()
       jcenter()
      
   }
   dependencies {
       classpath 'com.android.tools.build:gradle:3.3.0'
       classpath "org.jetbrains.kotlin:kotlin-gradle-plugin:$kotlin_version"
       // NOTE: Do not place your application dependencies here; they belong
       // in the individual module build.gradle files
   }
}
 
allprojects {
   repositories {
       google()
       jcenter()
      
   }
}
 
ext {
   // Get the current flavor of the build Ex: dev, stg, prod
   flavor = getCurrentFlavor()
   if (flavor.isEmpty()) {
       flavor = "dev"
   }
 
   // Read the .properties for config
   config = getProps('config/' + flavor + '.properties')
}
 
def getProps(path) {
   Properties props = new Properties()
   props.load(new FileInputStream(file(path)))
   return props
}
 
def getCurrentFlavor() {
   Gradle gradle = getGradle()
 
   // match optional modules followed by the task
   // [a-z]+([A-Za-z]+) will capture the flavor part of the task name onward (e.g., assembleDevRelease --> Dev)
   def pattern = Pattern.compile("([A-Z][A-Za-z]+)(Release|Debug)")
   def flavor = ""
 
   gradle.getStartParameter().getTaskNames().any { name ->
       Matcher matcher = pattern.matcher(name)
       if (matcher.find()) {
           flavor = matcher.group(1).toLowerCase()
           return true
       }
   }
 
   return flavor
}
 
task clean(type: Delete) {
   delete rootProject.buildDir
}

Let’s open the app (module) level build.gradle and see how we can substitute the properties read earlier.

Let’s open the app (module) level build.gradle

Under the android block, add flavorDimensions and productFlavors properties. Here we are specifying our build flavors to contain three flavors. Notice the flavor names and our .properties file names match. This helped us earlier in the project level build.gradle to read .properties files dynamically.

def envConfig
flavorDimensions "default"
productFlavors {
   dev {
       envConfig = getProps("../config/dev.properties")
       applicationId envConfig.getProperty("APPLICATION_ID").replace(""", "")
       versionCode envConfig.VERSION_CODE.replace(""", "").toInteger()
       versionName envConfig.VERSION_NAME.replace(""", "")
   }
   stg {
       envConfig = getProps("../config/stg.properties")
       applicationId envConfig.getProperty("APPLICATION_ID").replace(""", "")
       versionCode envConfig.VERSION_CODE.replace(""", "").toInteger()
       versionName envConfig.VERSION_NAME.replace(""", "")
   }
   prod {
       envConfig = getProps("../config/prod.properties")
       applicationId envConfig.getProperty("APPLICATION_ID").replace(""", "")
       versionCode envConfig.VERSION_CODE.replace(""", "").toInteger()
       versionName envConfig.VERSION_NAME.replace(""", "")
   }
}

We are also reading .properties file in respective flavor and assign the values to applicationId, versionCode, and versionName fields. Let’s examine the above lines a bit. We are substituting applicationId using envConfig.APPLICATION_ID.replace(“””, “”). Here we are using the app id specified in the respective config file. All our config property values are specified as string within double quotes. Gradle generates BuildConfig.java file on the fly while building and uses the values specified in the substitutions. Hence, we make sure to strip double quotes using replace(“””, “”).

versionCode is an integer and is substituted with value of VERSION_CODE by converting the string value to integer.

Change the properties under defaultConfig block as shown below.

defaultConfig {
   minSdkVersion 21
   targetSdkVersion 28
   testInstrumentationRunner "android.support.test.runner.AndroidJUnitRunner"
 
   // Add config properties as build configs
   rootProject.ext.config.each { p ->
       if (p.key != 'VERSION_CODE' && p.key != 'VERSION_NAME' && p.key != 'APPLICATION_ID') {
           buildConfigField 'String', p.key, p.value
       }
   }
}

In the end of the code block, we iterate over the config key-value pairs read from properties file and add each of them as build config fields. The if condition there prevents us from adding duplicate entries into BuildConfig.java, as versionCode, versionName and applicationId are already part of build.gradle.

Now that our configs are added as build configs, let’s see how we can access them in code. Open MainActivity.kt file and add below lines in onCreate method.

override fun onCreate(savedInstanceState: Bundle?) {
   super.onCreate(savedInstanceState)
   setContentView(R.layout.activity_main)
   setSupportActionBar(toolbar)
 
   Log.d("VersionCode ", BuildConfig.VERSION_CODE.toString())
   Log.d("VersionName ", BuildConfig.VERSION_NAME)
   Log.d("Base URL ", BuildConfig.BASE_URL)
   Log.d("API Key ", BuildConfig.ANALYTICS_API_KEY)
   Log.d("API Secret ", BuildConfig.ANALYTICS_API_SECRET)
}

Select Build Variants tab from side bar and select devDebug as the variant as shown in the image below.

Build_variants

Run the app to see the logs as shown below.

2019-01-23 23:29:43.829 2245-2245/com.places.android.dev D/VersionCode:: 1
2019-01-23 23:29:43.829 2245-2245/com.places.android.dev D/VersionName:: 0.1
2019-01-23 23:29:43.832 2245-2245/com.places.android.dev D/Base URL:: http://api.places.com/dev/
2019-01-23 23:29:43.832 2245-2245/com.places.android.dev D/API Key:: 783fa804f48d2952c22bf6653ce4474f
2019-01-23 23:29:43.832 2245-2245/com.places.android.dev D/API Secret:: f93754758b5b7f242f89b8d38223e836

These output values correspond to the values we have configured for the dev.properties file. Try selecting other variants from Build Variant menu and observe the output. We can also observe that, once these builds are run, three separate apps co-existing in the device/emulator.

Build Variant menu and observe the output

Observe the icons and app names. They are exactly the same. As we have different application IDs for each of the flavors, we see three installed apps. Let’s address the app name next.

Let’s name our app based on the flavor. That is, Places(Dev), Places(Stg) and Places for dev, stg, and prod flavors respectively. This can be done in various ways.

By default in Android, the app name is specified as a string resource in AndroidManifest.xml file like android:label=”@string/app_name” under application tag. Here, the resource app_name is actually defined in the localizable string resource file named strings.xml, under res/values directory.

Renaming App – Method 1

In this method, we can create flavor specific directories under app/src directory and place res/values/strings.xml file under each of them. Each strings.xml file has an app_name value defined as shown in below image.

strings_xml

In this case, there will be four strings.xml files. Three from flavor specific directories and one under main/res/values/ directory. While building, strings.xml in current flavor directory is given the first preference and next main/res/values/strings.xml will be treated. In the process, duplicates will be eliminated by keeping those coming from strings.xml under current flavor directory and discarding the same resources from main/res/values/strings.xml.

Renaming App – Method 2

In this method, we can specify the app name as a string resource in app level build.gradle file. We do this in the productFlavors block we defined earlier as shown below.

productFlavors {
   dev {
       resValue "string", "app_name", "Places(Dev)"
   }
   stg {
       resValue "string", "app_name", "Places(Stg)"
   }
   prod {
       resValue "string", "app_name", "Places"
   }
}

Note, however that, duplicate resource names cause a build failure in this method. We have to make sure to remove the duplicate entry of app_name from main/res/values/strings.xml file.

This method is convenient if we don’t need a way to change the app name externally, via a config (.properties) file.

Renaming App – Method 3

In this method, we specify the app name in our flavor specific config (.properties) files so that we can handle name change without changing the code. This is the approach we proceed with in this article.

Add a new property called APP_NAME in dev.properties, stg.properties and prod.properties files, as shown below.

For dev,

# App name
APP_NAME = "Places(Dev)"

For stg,

# App name
APP_NAME = "Places(Stg)"

For prod,

# App name
APP_NAME = "Places"

In app level build.gradle file let’s read this value and add it as a string resource dynamically as shown below. We just modify config iteration block within defaultConfig by checking for APP_NAME key and adding it as a string resource, if found.

// Add config properties as build configs
rootProject.ext.config.each { p ->
   if (p.key == 'APP_NAME') {
       resValue 'string', p.key.toLowerCase(), p.value.replace(""", "")
   }
   else if (p.key != 'VERSION_CODE' && p.key != 'VERSION_NAME' && p.key != 'APPLICATION_ID') {
       buildConfigField 'String', p.key, p.value
   }
}

Notice the resValue syntax for adding a string resource.

resValue ‘string’, p.key.toLowerCase(), p.value

The type should be string and NOT String. We are also converting key to lower case to make it app_name to keep consistency in the naming in resource xmls.

Also, duplicate resource names cause a build failure in this method as well. We have to make sure to remove the duplicate entry of app_name from main/res/values/strings.xml file.

After following one of the three methods mentioned above, if we now run all the flavors, below is how it would look like.

App_icons

Now, let’s see how we can provide separate icons for each of the flavors.

When we define flavors in build.gradle, the build system searches for resources in the flavor specific directories first. If flavor directories are not found, then the search happens in main directory under app/src. Let’s start by creating flavor specific directories in side app/src directory as shown in below image.

Flavor_dir

Flavors_project

As we are interested in adding icons, let’s create a res directory under each flavor directory containing different dimension directories within as shown below. Each of the dimension directories, in-turn contain respective icon files.

Flavored_icons

Next, delete mipmap-xxxx directories under src/main/res directory, as we already provided icons in specific flavor directories. Change android:icon and android:roundIcon properties in AndroidManifest.xml file as shown below.

 <application
       android:icon="@mipmap/icon"
       android:roundIcon="@mipmap/icon_round"

Note that, icon file names specified in AndroidManifest.xml should match the actual icon files added in mipmap directories.

Build and run the application with all variants one by one. The respective apps now will have flavored icons as shown below.

Final_icons

We can also include other bespoke resources required within flavor specific directories, if these resources require to be different per flavor. One such example is the google-services.json file we require to integrate google APIs into our app development. If we happen to maintain separate google-services.json file per configuration, we can keep them in these flavor directories and at build time, these will be referenced automatically based on the build variant selected for build.

In this article, we spoke about Build Configurations for Android, in the next article of this series, we will talk about creating Build Configurations for iOS. Stay tuned.

Read More
Mobile Opinion

Everything You Need to Know About Smart Home Automation Technologies

What Is Smart Home Technology?

Did you remember to turn off all your house lights in the morning, adjust your thermostat, or arm your security system before you left for work or on an extended trip? Smart home technology today enables users to manage these small but significant tasks to reduce the stress and costs associated with these household necessities.

“Smart home” is an umbrella term for the automation, digitization and interconnection of household tasks that can be set up automatically and controlled remotely, thereby making our daily lives more efficient. The United States alone will see over 42 million smart home devices installed by end of 2019. Globally, experts predict the home automation market will reach $21.6 billion by 2020 and upwards of $53.5 billion by 2022.

Smart Home Automation Technologies

Smart home technology as we know it began with the invention of the thermostat; today’s uses include home security, energy use monitoring, remote elderly or disability care, appliance and lighting control, and many more. The Internet of Things, or IoT, is the connecting of devices to the Internet (home appliances, thermostats, vehicles); tech like voice assistants and AI also form a part of home automation. According to ADT, a leading home & business security provider, nearly 4 in 5 smart home device owners preferred to control their device through voice command.  In this post, we cover technologies that are fuelling the growth of home automation, the security concerns associated with these innovations, and a few notes on the future of home automation.

Recent Innovations in Smart Home Technology

In the past, home automation technology varied from country to country, but advances in industry standards have enabled manufacturers to focus their efforts in improving the connectivity through mesh networking. Current major players include Google (Nest), Alexa, Apple (HomeKit), Amazon (Echo), Belkin, Wink, Logitech and Honeywell. Smart speakers are the second most common type of smart devices in home (with Smart TVs being the most popular) with wireless audio gaining in popularity.

Throughout most of 2017, home automation applications revolved primarily around security and thermostat control. In 2018, however, these devices were actually speaking to each other, connecting users to their homes and devices through a platform-focused approach. We saw data and analytics give homeowners a more comprehensive understanding of household operating expenses, and remote access gave them control over how effective those devices were practically helping them live simpler lives.

One of the recent innovations in smart home tech, WooHoo is a central hub for controlling all IoT devices in your home. This wifi-enabled device uses a 360-degree camera to detect which household member is speaking, using both voice- and facial-recognition software to learn the commands and preferences of each member. “If you’re in a smart car and you’re coming home,” explains Joseph Santos, Chief Digital and Marketing Officer at Smart Beings, “it will interact with your vehicle and know that someone is coming home, so it will turn on the thermostat, turn on the lights.”

Smart Home Automation Tech

Image source

Reactive Technologies uses smart meters and IoT devices (smart grid technology) to merge the telecommunications and energy sectors to better manage energy consumption for its users across specific regions. Through a recent project in France, Reactive is changing the “energy consumption of fridges and freezers in hundreds of retail locations, making adjustments throughout the day to free up energy when energy demand is high.”

While these changes don’t make a huge impact per household, smart home devices can collectively help reduce energy consumption and not only cut costs per household but also ensure that energy is better distributed to reduce both shortages and overages in the long run.

Security and Privacy Concerns

Convenience in the Digital Age has prompted us to share our digital footprint with a number of companies, which they use to create and market products they think we’ll use. With the advent of smart home technology, users are also sharing their physical footprint, both at home and while away. “It is not a matter of if but when these systems will be compromised, and the consequences could be much more severe than lost social security numbers,” shares Dimitri Stiliadis of Aporeto. “Addressing security and privacy will become a fundamental concern that will shape this industry.”

For example, many people leave their lights on while they’re traveling in the interest of deterring would-be burglars. Security concerns that can be addressed with something as simple as a lighting system app that allows you to remotely access your lights with a variety of controls while away offers the peace of mind needed to enjoy a vacation.

Homeowners may also be concerned that their home could be vulnerable to a hack or break-ins, such as having their home security apps fail, being robbed, or having their passwords leaked. For others, they’re concerned “about the privacy implications of living and working among so many Internet-connected cameras and microphones.” Some experts are also worried that IoT is “a security nightmare” because many technology companies don’t possess the technical and practical expertise required to ensure their consumers’ data is protected at a high level.

As with anything technology-related that handles consumers’ personal information, companies in the smart home space must prioritize privacy and security strategies to minimize the risks involved when these situations arise.

The Future of Home Automation

The latest home automation devices not only use wifi but also AI, “the ability to learn patterns, recognize faces and voices”, to gather and learn about the user and what their preferences are. The smart home tech that harnesses the power of voice control through your phone, television, and car is becoming more ubiquitous; companies that prioritize devices that can seamlessly integrate with smart home features and apps will see a distinctive edge in the marketplace.

Devices sharing homeowners’ data with businesses will be the next big thing…imagine having your refrigerator order your groceries for you because it already knows what items you are low on, or your light fixtures sending an order to Amazon for new bulbs when they’re nearing the end of their lifecycle.

Expect to see greater cross-compatibility across devices and platforms, and apps that allows users to control more than one aspect of their home (ie: not just lighting, but also heating, security and appliance control). IoT appliances will also take on more of the workload, alleviating the burden on homeowners…such as having your crockpot connected to your smartphone, so you know when dinner will be ready, or heating your home to your preferred temperature 30 minutes before you arrive, rather than waiting for the heat to kick in after you walk in the door.

As the technology continues to evolve, we won’t even need to manually set up these automations. AI tech will enable these devices to not only learn our preferences over time, but to also anticipate our needs and those of our family, leading to a truly automated lifestyle.

Read More
1 3 4 5 6 7 22