1. Home
  2. Docs
  3. Communities
  4. Pickups
Live Chat

Communities Schedule Pickups

Scheduling Pickups via communities can be done one of two ways. By allowing your users to enter the pickup details for a particular shipment, or by setting up the custom address source to schedule the pickup automatically.

1

Install Multi-Carrier

To install, begin by going to the Salesforce AppExchange and finding the Multi-carrier for Salesforce listing. You can find the app through Search or by clicking this link.

Click on the Get It Now button and select the desired destination (sandbox or production). Multi-carrier for Salesforce can be installed in both Sandbox (does not expire) and Production (7 day trial) instantly. Click Continue.

2

Preference Setup

If you want to test the shipping functionality then we recommend using our test FedEx preference (this is because FedEx offers the most friendly test environment). By using this test preference you won't be charged for any of your test shipments.

You can add this by going to Zenkraft Settings and turning on Demo Mode and then clicking the "Create FedEx Test Preference" button.

Otherwise please do go ahead and add your own preferences. Make sure Demo mode is off though, otherwise you might see some authentication errors.

3

Pickup Button on the Shipment Object

Your community users can easily request a pickup directly from the Shipment object by using the New Pickup button.

This will then load the Pickup page for your users to confirm their details:

and to set the pickup time and any special instructions:

Once those field are filled in your users can then see the rates and submit the request for a pickup.

4

Create a Pickup automatically

The recommended approach is to use the Custom Address Source to request a pickup when a process builder runs. For example if you can set that the pickup gets created when the Case status changes to "Requested Pickup".

This means its a lot easier and quicker for your community users to request pickups!

Below is a guide on how to do this:

Create a Pickup from a Case when the Status Changes

The first step is to create a lookup from the Pickup object to the Case object. You can do this by going to Setup > Create > Objects and finding the Pickup object.

Click on the New button:

Select the Lookup item:

Click next and then select the object we are going to use. In this guide we are using the Case object.

Continue to click next until the relation ship has been created. Confirm this has been done by going to a Case and viewing the new related list that has been added:

Pickup Custom Address Source

The next step is to create the Pickup Custom Address Source. This is where you map all the fields needed by the carrier to create the pickup.

Click on New: 

And you will see all the Fields that are available to be populated. Not all fields are needed for all carriers, but this is easy to test later on.

Give the Pickup Custom Address Source a Name and select the Lookup Field you created earlier.

Next add the address and contact name/email/phone reference fields.

Some carriers (such as FedEx) require the Location and Building Type  to be populated. .

Here are the values:

FedEx:

Package Location Field: FRONT/REAR/SIDE

Building Type Field: APARTMENT/BUILDING/DEPARTMENT/FLOOR/ROOM/SUITE

UPS:

Package Location Field: Front Door/Back Door/Side Door/Shipping/Receiving/Reception/Office/Mailroom/Garage/Upstairs/Downstairs

Building Type Field: Floor/Room

The Shipments section allows you to automatically select all shipments related to that Case to be included in the pickup.

Shipment Selection Condition Name: Is a checkbox that determines which shipments should be included. Let say you only want the shipments of type Return included, you can specify the name of that field.

Shipment Object Lookup Field: Is the related list of Shipments you want to use.

Next make sure you reference the correct Preference that you want to initiate the pickup with. 

Most carriers also want to know the date to pickup, and the available time on that day when they are able to pickup the package. This is the Ready DateTime and Close DateTime fields.

These fields are of type DateTime.

Next we can fill in the Special Information section.

Courier Remarks Field allows you to add any instruction for the courier.

Some Carriers also require you to add the Pickup Service Category Field and Carrier Code Field.

Here are the values:

FedEx:

Pickup Service Category Field: SAME_DAY/SAME_DAY_CITY

Carrier Code Field: FDXE/FDXG

The next section is Error Handling. And this allows you to reference a field on your object where we can populate any error message you might get if there is an error with the pickup.

Once all these fields are setup you can now test to make sure that the information populates correctly via the Pickup Wizard screen. Go onto your Case object and click on the New Pickup button

You should now see all your field populated correctly on the Wizard screen. 

Process Builder Setup

Now we need to create a process builder task to create the pickup when the Case status changes to a certain status. In this guide we have already created a new status called "Create Pickup" which we will use as the criteria in our Process Builder.

Go to Setup > Create > Workflow & Approvals > Process Builder

Create a new process builder.

Select you object and set it to "when a record is cerated or edited".

Next set the criteria for when this process should run.

We have set it to run when the status is changed, and when the status gets set to Create Pickup.

Finally, create a new immediate action and choose Apex, and in the possible Apex Classes choose the "Create Pickup (Multi Carrier)". 

You will then have two fields that are required to be filled in.

The first on is the record id, in this guide its the Case.Id, and the customAddressId is the Salesforce of the Pickup Custom Address Source.

Save each section and then activate your process builder. 

Go back to your case and change the status field to "Create Pickup", and see the pickup get created.

If the pickup doesn't get created you can view the error under Setup > Apex jobs.

Here are some example errors:

Create Pickup After Shipment Creation

Now we will show you how to automatically create a pickup after a shipment has been created.

First make sure that you have your shipments related to your object. In our guide we are using Case, and we can see the shipments are related to the Case correctly:

Lets create the new Pickup Custom Address Source, and this time we will call it Case Pickup after Shipment Creation

Fill in the fields as we did for the first part of this guide.

Next lets go to the process builder, and create a new process builder task.

The object to choose is Shipment and start the process "when a record is created or edited".

For the Criteria make sure you set these condition on the field "Shipment Processing Completed" to be True, and ensure you utilize the Advanced dropdown to execute the actions only when specified changes are made to the record :

Set the scheduled action to run 0 Hours After CreatedDate, this means the pickup code will run after the shipment has been created and won't interfere with any other processes.

You can now Add Action and set it to Run Apex class called "Create Pickup (Multi Carrier)". Much like the first part of this guide you can add the customAddressID and recordId, you can now specify the shipmentId.

Save the process builder and run a test.

Supported Carriers:

  • Aramex
  • Canada post
  • Canpar
  • DHL
  • DPD Germany
  • FedEx
  • FedEx Freight
  • Purolator
  • UPS
5

Test

Now it is time for you to test.

If you have any queries then please contact us and we will be happy to help