Tuesday, 3 May 2022

MuleSoft 4 Fundamentals

 We need software that integrates multiple systems seamlessly.

API-led Connectivity :

API-led connectivity is a methodical way to connect data to applications through reusable and purposeful APIs. 

These APIs are developed to play a specific role, unlocking data from systems, composing data into processes, or delivering an experience.


Three Types of API's :


1.System APIs

2.Process APIs

3.Experience APIs


System APIs :


System APIs, these usually access the core systems of records and provide a means of isolating the user from the complexity of any changes to the underlying systems. 

Once built, many users can access data without any need to learn the underlying systems and can reuse these APIs in multiple projects. 

Think of APIs to access a database, at least the common operations or APIs to ease the access of certain errorless resources.


Note : Encapsulate data systems into an API.


Process APIs :


These APIs interact with and shape the data within a single system or across systems, breaking down the data silos, 

and are created here without dependence on the source systems from which the data originates. 

They only call the system APIs, and, as well as they don't depend on the target channels for which the data is delivered. 

A given process API, you have to think of a transformation, the data coming, for example, from the database to a certain schema delivered by a 

certain web page. Regardless of the web page API and the database API, in the middle, the logic is the same.


Note : Aggregate and process the result of System APIs.


Experience APIs :


Experience APIs are how data can be reconfigured so that it is most easily consumed by its intended audience, all from a common data source rather than setting up separate point-to-point integrations from each channel. 

An experience API is usually created with API-first design principles where the API is designed for this specific user experience in mind.


Note : Expose the data for frontend



API Language :


There are many, but the main ones are Swagger, or you may hear Open API 3.0, and RAML v1. 

RAML is native to MuleSoft.


RAML is a YAML-style language to define an API. 


Main Changes from Mule 3 :


1.Migrating MEL to Dataweave 2.0

2.Added Design Center

3.Flow Designer

4.Exchange


Monday, 2 May 2022

Salesforce Platform Events

 1.Platform events are a special type of object (__e).

2.Platform events only support create/read permission.

3.No SOQL support,you must replay events to retrieve.

4.Fields limited to base data types only (i.e text,date,number,Boolean).

5.you can subscribe to events via Apex,Process Builder and CometD utility (Java or javascript).


Note :

The what happens with the platform event in an event bus is that you have decoupled your information publishers and your information subscribers.


The publisher of information doesn't have to know anything about anybody that's listening. And the subscriber, 

if it happens to fail or have an exception or something like that doesn't walk anybody else from performing actions. 

That's one of the real powers of this platform event model.


The only way to get events is to subscribe to them and potentially to republish them, 

which has to go through the entire stream events from that point onward.


Platform events cannot be edited their immutable.


Platform events have two publication types :


1.Publish Immediately disregards any form of rollback.

2.Publish On Commit honors transaction controls.



Note :

1.You can publish a platform event immediately, which means it hits that bus and it goes. No matter what else is happening in the system.

2.The second option is to wait until after the committee of the current transaction to publish them. 

If you're trying to do something because if you're trying to throw a platform event because a record change successfully, 

you'd want to wait till after commit But if I have an heir, I wanna publish that thing right away.


Note :

1.'Processes' utilize the SAME user that fired the event.

2.'Triggers' utilize the AUTOMATED PROCESS user.


Asynchronous processing :

=========================

It's now known has changed data capture what happens with change. 

Data capture is any record event that happens on that particular object has a platform event published, 

and the body of that event is the fields that are changed.


Events are processed in batches that can scale up quickly.

-> Monitor limits in the transaction and pick up where you left off 

with TriggerContext.setResumeCheckpoint(replayId).

-> Abort and retry a batch from the beginning by throwing an EventBus.RetryableException.

Sunday, 1 May 2022

Salesforce Omni-channel

 Omni-channel Channel Types :


Omni-channel is capable of working with two types of channels :


1.Real-time Channels 

2.Asynchronous Channels 


1.Real-Time Channels :

Real-Time Channels are Channels where the person asking support is expecting a real-time answer to their request.

For example, Phone calls or live chat.

2.Asynchronous Channels

Asynchronous Channels are Channels where the person asking support is expecting a reply to their request at a later time.

For example emails or contact forms.


Omni-channel Routing Destinations :


Omni-channel can route Work Items to 3 different destinations.

1.Route to Queue

2.Route to Skill

3.Route to Agent 


1.Route to Queue :


Work items fall in a Queue of Users where Users are then picking up work first-in first-out.


2.Route to Skill :


Work Items are Assigned to the Agents that have the proper skills to work on the request.


3.Route to Agent :


Work Items are assigned to a specific Agent directly.


Omni-Channel Agent Properties :


Agents have properties that Omni-Channel uses in order to select which agent is 

better suited to receive a work Item based on its Routing Destination.


1.Status & Capacity

2.Skills

3.Queue Membership


1.Status & Capacity :

Agents all have a Status,which models their availability, and a Capacity,which models the maximum amount of work they can take.


Examples of Statuses are : Away,Available,On Break


2.Skills :

Agents have a set of Skills that they can leverage to take certain work items.

Work Items can require one or multiple skills to be assigned.


Example of Skills are : English, 2nd Tier,Robot Butler Maintenance


3.Queue Membership:


Agents can be assigned to specific queues,and thus work on Work Items that fall in those Queues.


Examples of Queues are : Billing,Complaint


Omni Supervisor Features :


Supervisors get access to the Omni Supervisor function in Omni-Channel in order to monitor their team easily.


1.Monitor Agents 

2.Monitor Work Backlogs

3.Monitor Assigned Work


Monitor Agents :


Supervisors can monitor the Agents they have access to through the Supervisor Configuration assigned to them.


This includes,the Agent status and status timeline,the Agent's current work and open capacity,how long they've been logged in.


Monitor Work Backlogs :


Supervisors can monitor specific Skill & Queue backlogs to gauge how much work is left to be assigned to agents.


This allows them to have simple visibility on where to focus their efforts.


Monitor Assigned Work :


Supervisors can monitor work that's being worked on.


Using specific channel functionalities,they can even listen in on phone calls,

or see what agents are typing in the chat even before they've sent it.


TelePhony in Salesforce Service Cloud :


1.Open CTI


Open CTI is a telephony javascript API allowing vendors of telephony systems to develop integrations to interact with a 

Salesforce Softphone directly on the end-user's browser.


2.Vendor-Specific Implementation


Vendors also have the possibility to integrate deeper into Salesforce by integrating

with specific Service Cloud functionalities like Omni-Channel or Service Cloud Voice.


Vendor TelePhony Integration Levels :

1.Simple Integration-pure Open CTI integration


A vendor that integrates with Open CTI will only provide a Web-based softphone client for end-users to 

interact with. This means the integration is limited and doesn't integrate with Omni-Channel.


2.Partial Integration -Open CTI with additional functionalities 


A vendor can also add additional functionalities to their integration.

In that case, you have to look at your vendor's documentaion to ensure 

Omni-Channel is included as part of their additional functionalities.


3.Complete Integration - Service Cloud Voice 


A vendor that maintains a Serice Cloud Voice implementation is the most complete 

telephony integration you can find as this leverages Salesforce as the central place

for all telephony actions to happen.


TelePhony & Omni-Channel Integration Benefits :


1.Bi-Directional Agent Status Syncing

One of the key benefits of integrating your telephony in Omni-Channel is that the agent's status 

synchronizes on both systems,allowing your agents to do it in one place only.

2.Handle Phone Calls right from Omni-Channel

 Once integrated,phone calls can be managed inside of Omni-Channel instead of your agents having to manage 

 two different windows,one for the softphone , and the other for Omni-Channel.

3.Record & Transcribe Phone Calls, and much more

 If your vendor implements those functionalities,you can even record and transcribe phone calls right from Salesforce.

 Other functionalities like 'Supervisor Listen In,'Queued Callbacks' or 'Mean Opinion Score'

 are functionalities your vendor cloud provide to you too.

 

Salesforce Chat :


To set up Chat in Service Cloud and route it to Omni-Channel.

 

1.Omni-Channel

Used to route the chat conversations based on your Omni-Channel routing.


2.Emabedded Service 


Used to embed your Salesforce Chat wherever you want (ex: website,app).


3.Einstein Bots


Used to filter your chats and gather pre-information before they arrive to your agents.


4.Agent Chat Console


Used by your agents in order to interact with the chats they have open with customers.

Sunday, 3 April 2022

Dealing with View All Data & Modify All Data access in Salesforce

 Do you know if you remove View All/Modify All access from the Object level in profile, the View All Data/Modify All Data system permission gets removed as well.

For example, if you have enabled View All Data permission in a profile, it will give view all access for all the available objects. Now, if you remove view all access from one of the object, it will disable the View All Data access.

So, we need to be extremely careful while dealing with View All Data & Modify All Data access.

Sunday, 27 March 2022

GraphQL

 GraphQL is a query language for your API.

It has been developed as a more flexible and efficient alternative to REST.


GraphQL - Query language for API


1.Provides clients the power to ask for exactly what they need and nothing more.

2.GraphQL APIs get all the data your app needs in a single request.

3.Language agnostic - Plenty of client and server libraries are avaialble.



Note :

In GraphQL we can compose the request in the form of a GraphQL query and ask

for exactly what I need to build the app.It then responds with the JSON object with exactly what I asked for.


No multiple round-trips like REST. No Over-fetching or under-fetching.


REST vs GraphQL :


REST :

1.Multiple round trips to collect the information form multiple resources.

2.Over fetching and under fetching data resources.

3.Frontend teams rely heavily on backend teams to deliver the APIs.

4.Caching is built into HTTP spec.


GraphQL :

1.One single request to collect the information by aggregation of data.

2.you only get what you ask for.Tailor made queries to your exact needs.

3.Frontend and backend teams can work independently.

4.Doesn't use HTTP spec for caching (Libraries like APollo,Relay come with caching options).


Sunday, 13 March 2022

Salesforce Experience Cloud Deployments

 There are two key deployment methods when it comes to deploying your Salesforce community.

1.Change sets 

This is a point and click-based toolset that represents a list of customizations that can be deployed 

to any connected org within your Salesforce organization.

Note :

1.Point-and-click-based.

2.Under Setup menu in Salesforce.

3.Migrate changes between your orgs.


There are some considerations when it comes to change sets.

-> Experience Template Changes :

The first of those is Experience template changes. So if you make changes to your template within, say, stage or dev, 

you're going to need to make those changes manually in the upstream environment before deploying your broader change set.

-> audience target :

So if you make any updates to any of your audiences, to any assignments around audiences, 

you're going to need to make those manually within that upstream environment.



2.Metadata API

This is more of a code-based tool set that allows you to deploy a set of customizations more programmatically to any org that you choose.


1.Code-based

2.Utilizes app or command line

3.Migrate from one org to another.

4.Experience Bundle 


what the ExperienceBundle allows us to do is it allows us to extract granular site metadata so that we can quickly update and deploy bits 

and pieces of our site without having to deploy the entire site at once. So the ExperienceBundle is a nice way, if you've made a very small change 

to your site and you just want to deploy that change, the Metadata API using the Experience Bundle allows this to happen.


Experience Cloud Moderation :


There are three core areas when it comes to moderation.

1.moderation criteria

2.moderation rules

3.moderation settings


Note :

Essential for healthy site collaboration.

core areas of moderation.

-> Member and content criteria.

-> Rules to block ,review ,replace and flag content.

-> user content flagging.

-> Moderation workspace.


moderation criteria :


Within Salesforce communities, there are two types of moderation criteria.


1.member criteria

2.Content criteria


-> Member Criteria :

Member criteria utilizes member information to designate which member to target with a moderation rule. 

This could be the type of member such as customer, partner or internal or even based upon their profile. 

This can also be based upon their join date or whether they've posted or commented in the community. 

-> Content Criteria :

Content criteria is all about keyword searching. This could be used to protect from profanities being used in the community 

or flagging competitor names or certain keywords that you want to call out from a moderator's perspective.


Moderation Rules :


There are two types of moderation rules within Salesforce communities.


1.Content rules

2.Rate rules


-> Content rules :


Content rules are used to moderate the content that's being posted within your community.

This is comprised of a couple different settings.

 a.content type

   Do you want this rule to apply to a post or a comment or both.

 b.moderation action

   This is where you choose one of several actions, whether to block, flag, replace or review that item. 

 c.member message

  This is where you can give a message to the member, notating the action you're taking and why you're taking it.

 d.member's and content criteria 

   So utilizing that member and content criteria you have previously set up, you configure them here within your rule, 

   and it will only apply to those members and those keywords you've previously designated

   

-> Rate rules :


Rate rules are there to help limit the number of times somebody has posted within your community. 


a.content type 

This is comprised of content type. So again, do you want this to apply to a post, a comment, as well as other content types such as private messages 

or files? Then what members do you want it to apply to?

b.member criteria

So you can reuse your member criteria here within a rate rule to determine which members this rate rule should apply to.

c.rate limits

Now there's several different options when setting your rate limits.

The first of those is the time period you're looking at, and that can either be 3 minutes or 15 minutes. 

And then you're going to set how many times are they posting within that time period before you notify a moderator and then before you freeze them as a user.

  

what moderation actions are available within our moderation rules?

->  block   

This prevents the content from being published at all. 

So if it contains a keyword, it will be blocked, and that user won't be able to post it until they remove that particular keyword.


Note : Prevents content from being published.


-> review

This allows a moderator to review a post or a comment before it is published within the community. 

So it allows the user to post it., but it puts it in a review status to where only a moderator or the poster can see that post 

until a moderator approves it within the moderation workspace.


Note : Allows Moderators to review before being published.


-> replace

This allows publishing, but replaces the keywords that are found within that post or comment with asterisks. 


Note : Allows Publishing but replaces keyword(s) with asterisks.


-> flag

This allows publishing, but it automatically flags that content for a moderator's review. So it's still available within the community. 

Other members are able to see that, but it's flagged so the moderator can review it and take action on it, if necessary. 


Note : Allows publishing but automatically flags content.



Moderation settings :


Moderation settings are a couple areas where I can further my moderation within my community.


-> user content flagging

This is a checkbox under community administration where I can allow my users to flag posts as they see fit to bring to a moderator's attention. 

So if something slips through a moderation rule, a user could flag it, and it would appear within my moderation workspace as a moderator for me 

to review and take action on. 

-> file types and sizes 

This is where I can set the types of files and the sizes of those files that can be uploaded to my community as a moderator.

-> moderation workspace


Home/Overviewpage :


This is where a moderator would go to do their work. They would get an overview page to see how many pending discussions 

are out there or how many flagged posts are out there right from a Home and Overview tab.

moderator Page :


That's where I can go to my moderate page where I can review the list of items I need to moderate as a moderator, 

and then I can take action on them, as necessary.


Rules Page :


The rules page where I can manage all of my moderation rules, my moderation content criteria, and my moderation member criteria.


Summary :


1.moderation is necessary for a healthy site.

2.moderation criteria for members and content.

3.moderation rules can be used for monitoring member-generated content.


Experience Cloud Analytics :


1.reports and dashboards package


The reports and dashboards package that Salesforce provides. 

This is a package on the AppExchange that comes with a set of dashboards, reports, 

and custom report types to help you get off the ground when reporting on your Experience Cloud site.


2.dashboard workspace


Once you have the package installed, then you're going to take a look at the dashboard workspace. 

This is the analytics landing page for your Experience managers where they're going to go for all things reporting on the Experience Cloud site. 


Sunday, 20 February 2022

Salesforce Data management & Integration

 1.Big objects

2.External Objects.

3.Canvas APP.


Big objects :

A big object stores and manages massive amounts of data on the Salesforce platform. 

We can archive data from other objects or bring massive datasets from outside systems into a big object to get a full view of your customers. 

Clients and external systems use a standard set of APIs to access big object data. A big object provides consistent performance, 

whether we have 1 million records, 100 million, or even 1 billion. This scale gives a big object its power and defines its features.


Big Object Use Cases

Some of the use cases for Big Object are: -


360° view of the customer— Extend your Salesforce data model to include detailed information from loyalty programs, feeds, clicks,

billing and provisioning information, and more. 

Auditing and tracking— Track and maintain a long-term view of Salesforce or product usage for analysis or compliance purposes.

Historical archive— Maintain access to historical data for analysis or compliance purposes while optimizing the performance of your 

core CRM or Lightning Platform applications.


Implementation - Key Consideration :-


Big Objects have few limitations which should be considered before making any decision: -


Big objects support custom Lightning and Visualforce components rather than standard UI elements home pages, detail pages, list views, and so on.

Big Object storage doesn't count against organization data storage limit. Based upon Salesforce edition, up to 1 million records are free. 

Additional record capacity can be bought in blocks (50M but can vary) and price is negotiable.

We can query big objects using standard SOQL or with Async SOQL. Async SOQL schedules and runs queries asynchronously in the background, 

so it can run queries that normally time out with regular SOQL. Async SOQL is the most efficient way to process the large amount of data in a 

big object. Async SOQL is available as add-on license.

Big objects support only object and field permissions (FLS and CRUD), not regular or standard sharing rules.

Search, Reports and Dashboards are not allowed on Big Objects - As Big Objects are designed for very large data volumes, 

these features are not yet available in Salesforce. However, there are a few workarounds for reporting on Big Objects : -

Use Einstein Analytics, which you can report on Big Objects

Summarize the information you want to report for Async SOQL, and store the result in an intermediate custom object. 

Then we can report on that custom object

Big Objects support only Lookup, Date/Time, Email, Number, Phone, Text, Text Area (Long) and URL data type. 

However, we can use workarounds — like creating a formula field on custom object and copying that value as text in the targeted Big Object.

Salesforce does not support flows, triggers, and process builder on Big Objects.

Big objects don't support encryption. If you archive encrypted data from a standard or custom object, it is stored as clear text on the big object.

You can’t use Salesforce Connect external objects to access big objects in another org.


How can We Query Big Objects?


If we know that you are querying small amount of records then you can use SOQL


And the another way is “Async SOQL”


AsyncSOQL: To manage millions and millions of records in your custom big objects salesforce introduced AsyncSOQL. 

But Async SOQL is included only with the licensing of additional big object capacity.


SOQL – Can retrieve records within the governor limits


Async SOQL – Can retrieve billions of records


2.External Objects:


How to Connect?

Salesforce Connect provides multiple options to connect to external systems with the help of the following adaptors:

1.OData 2.0 adapter or OData 4.0 adapter

2.Cross-org adapter

3.Custom adapter created via Apex


Note :

Record level access is not configurable for External Objects.

Record access ("all or nothing") is provided via Object Permissions at the Profile level.

For example, given External Object alpha__x a Profile could be configured to have "Read" access or no visibility at all,

depending on your business requirements.


External Object Relationships :


Two special types of lookup relationships are available for external objects: external lookups and indirect lookups.


Custom web Application run on external Server :


Salesforce Connect Limitations :

Salesforce Connect has some limitations that are important to remember and follow while using it:


The maximum number of external objects that can be created per organization: 100

The maximum number of joins per query across external objects and other types of objects: 4

The maximum length of the OAuth token issued by an external system: 4,000 characters

The maximum page size for server-driven paging: 2,000 rows


Canvas apps :


What is Canvas ?


1.Canvas is a set of tools and JavaScript APIs that allow for easy integration with a 3rd party application. 

2.It allows you to take your new or existing applications and make them available to your users as part of their Salesforce experience. 

3.Under the hood, Canvas apps are loaded into Salesforce through an iframe.


What is a Canvas app ?


A Canvas app is a special type of connected app within Salesforce that allows users to access the external system directly 

from within the Salesforce UI. Canvas includes tools that handle:


1.Authentication

2.Context

3.Cross-domain XHR

4.Events


The Canvas SDK :

The Canvas SDK is used from JavaScript in an app that supports JavaScript to access Salesforce data that the user has access to. 

The data requests that Canvas apps make happen in the context of the Salesforce user.


You will include the Canvas SDK in your external app in order to access Salesforce Data and publish/subscribe to events using the Streaming API. 

This is easily included from your Salesforce org using a URL:


<script type="text/javascript" 

src="https://curious-impala-skkpwh-dev-ed.lightning.force.com/canvas/sdk/js/52.0/canvas-all.js">

</script>