Your achievements

Level 1

0% to

Level 2

Tip /
Sign in

Sign in to Community

to gain points, level up, and earn exciting badges like the new
Bedrock Mission!

Learn more

View all

Sign in to view all badges

SOLVED

Implement Transactional Email in Website php

lindapri123
Level 1
Level 1

Hi,

Could anyone share how to implement transactional email (welcome email) in website php ?

This is my first attempt and quite confused how to implement RTEVENT & SESSION wsdl file in my website.

What endpoint URLs that I need to hit ?

 

Please help & advice

Thanks

Topics

Topics help categorize Community content and increase your ability to discover relevant content.

1 Accepted Solution
SatheeskannaK
Correct answer by
Community Advisor
Community Advisor

Hi @lindapri123,

 

Api documentation link to refer for transactional events on ACS. From my understanding you will be creating profile and then send welcome email for the profile created from ACS.

 

Transactional Event REST API 

Creating Profiles Using REST API 

How you connect to ACS REST API has to happen through adobe i/o,

ACS REST API using Adobe I/O 

Sharing the php library information that can be used to exchange the token through program to connect ACS via adobe i/o.

JWT Library 

 

Let me know if you have any questions.

 

Thanks!

SK

View solution in original post

4 Replies
SatheeskannaK
Correct answer by
Community Advisor
Community Advisor

Hi @lindapri123,

 

Api documentation link to refer for transactional events on ACS. From my understanding you will be creating profile and then send welcome email for the profile created from ACS.

 

Transactional Event REST API 

Creating Profiles Using REST API 

How you connect to ACS REST API has to happen through adobe i/o,

ACS REST API using Adobe I/O 

Sharing the php library information that can be used to exchange the token through program to connect ACS via adobe i/o.

JWT Library 

 

Let me know if you have any questions.

 

Thanks!

SK

View solution in original post

lindapri123
Level 1
Level 1

Hi skk44926872,
Thanks for your answer.

I think my adobe developer already create those API and generate it into wsdl file.

So, I only need to implement those wsdl right ?
my question : is there any guideline how to consume those wsdl file to my website that use php  ?

 

Thank You 🙂

SatheeskannaK
Community Advisor
Community Advisor

Hi @lindapri123,

 

If i understand correctly you have endpoint created on ACS already and you want to make a call when anyone submits their email. If so, whatever the document i shared has enough information to call the endpoint which you need to include.

Sharing the process that may look like,

- Call the profileAndServicesExt endpoint to check whether profile exists for the email submitted. I assume your ACS profile resource has been extended.

GET https://mc.adobe.io/<ORGANIZATION>/campaign/profileAndServices/profile/byEmail?email=example@example.com

- If the profile don't exists with the email then create the profile using POST call.

Refer this page: Profile Creation 

- Then hit the transaction endpoint to send the welcome email.

POST https://mc.adobe.io/<ORGANIZATION>/campaign/<transactionalAPI>/<eventID>

 And you can find more information on this link: Transactional event api 

- If you find the profile with email using GET call then don't hit the transactional endpoint.

- For all of this calls ensure you use library, i gave to get access token via adobe i/o to interact with all of this endpoints on ACS.

 

Let me know if you still have any questions.

 

Thanks!

SK

Manoj_Kumar_
Community Advisor
Community Advisor

Hello @lindapri123 ,

Your developer can use the any library which can be used to get and post response over HTTP. I would recommend using the GuzzleHTTP library for this purpose.

You can use this library to post data in rest/soap format to first get the access token from Adobe I/O.
The code will look like this.

$client = new \GuzzleHttp\Client();
$response = $client->request('POST', 'https://ims-na1.adobelogin.com/ims/exchange/jwt', [
'form_params' => [
'client_id' => 'YOUR_CLIENT_ID',
'client_secret' => 'YOUR_CLIENT_SECRET',
'jwt_token' => 'YOUR _JTW_TOKEN'
]
]);
);


Then the developer will have to make another similar type of call. But this time instead of posting the client_id and secret the payload will be the SOAP data and http headers should have the access token to authorize the call.

You can ask your developer to read more here http://docs.guzzlephp.org/en/stable/quickstart.html#making-a-request

Thanks