globalpayments / php-sdk

GNU General Public License v2.0
49 stars 66 forks source link

Heartland Form secure submit Remember me option #37

Closed acaballesfullscale closed 2 years ago

acaballesfullscale commented 5 years ago

Hi,

I am currently a developer and Im implementing Heartland/global payments solution to one of my clients. And My client request that maybe we can add "remember me" option in the embedded secure submit form, is it posible in the current SDK? If so, can someone walk me through on how to do it like api call to get card details?

Thanks, Algie

hpsTony commented 5 years ago

Hi Algie,

Yes, our SDK offers a couple of ways of going about this. The easiest path is probably to use multi-use tokens to convert and store customers' payment information in a non-sensitive way. Documentation on how to do so can be found on this page https://developer.heartlandpaymentsystems.com/Documentation/credit-card-payments under the Using Multi-Use Tokens heading (about half way down the page).

Let me know if this helps or if you have any other questions.

On Thu, Oct 17, 2019 at 8:04 AM acaballesfullscale notifications@github.com wrote:

Hi,

I am currently a developer and Im implementing Heartland/global payments solution to one of my clients. And My client request that maybe we can add "remember me" option in the embedded secure submit form, is it posible in the current SDK? If so, can someone walk me through on how to do it like api call to get card details?

Thanks, Algie

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_globalpayments_php-2Dsdk_issues_37-3Femail-5Fsource-3Dnotifications-26email-5Ftoken-3DAMSYO2FM6OAF4MY5VP36XWLQO7YH3A5CNFSM4JBUJ3PKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HSLDWMQ&d=DwMCaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=h9RKr5QNh_YWQ8j48jaEWcJeekfImwLqE82UEKrEbAw&s=ptoJQh31bcvWLOX2JuDUWCYcsQ5UGbYWpeEurEKpVwc&e=, or unsubscribe https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AMSYO2ACEFYRBMRCU2AXN2TQO7YH3ANCNFSM4JBUJ3PA&d=DwMCaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=h9RKr5QNh_YWQ8j48jaEWcJeekfImwLqE82UEKrEbAw&s=SwGxt8db5ppENjRPWyoPWltGArKX3uk_f_klkJuMpxo&e= .

--

Mark (Tony) Smedal

Product Ops Team Lead Heartland (866) 802-9753

A Global Payments Company

acaballesfullscale commented 5 years ago

Hi thanks a lot for the response.

Currently Im on my way to implement and request for a multi-use token to store credit card information, now I have a little problem that i think you can help me. Seems like I need some representative from your good organization to enable my account to take advantage of multi-token use. My Heartland developer portal account email address is devteam@facilityally.com

To be more specific, in this documentation https://developer.heartlandpaymentsystems.com/Documentation/credit-card-payments, it says a message "Multi-Use tokens are not enabled by default. You must contact your Heartland Representative to request this functionality on your account."

And also, if you can provide me a specific PHP code snippet example to store credit card information and retrieve it after, that would be awesome and helps my development fast and make my client happy.

Cheers, Algie

On Thu, Oct 17, 2019 at 8:15 PM hpsTony notifications@github.com wrote:

Hi Algie,

Yes, our SDK offers a couple of ways of going about this. The easiest path is probably to use multi-use tokens to convert and store customers' payment information in a non-sensitive way. Documentation on how to do so can be found on this page < https://developer.heartlandpaymentsystems.com/Documentation/credit-card-payments

under the Using Multi-Use Tokens heading (about half way down the page).

Let me know if this helps or if you have any other questions.

On Thu, Oct 17, 2019 at 8:04 AM acaballesfullscale < notifications@github.com> wrote:

Hi,

I am currently a developer and Im implementing Heartland/global payments solution to one of my clients. And My client request that maybe we can add "remember me" option in the embedded secure submit form, is it posible in the current SDK? If so, can someone walk me through on how to do it like api call to get card details?

Thanks, Algie

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub < https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_globalpayments_php-2Dsdk_issues_37-3Femail-5Fsource-3Dnotifications-26email-5Ftoken-3DAMSYO2FM6OAF4MY5VP36XWLQO7YH3A5CNFSM4JBUJ3PKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HSLDWMQ&d=DwMCaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=h9RKr5QNh_YWQ8j48jaEWcJeekfImwLqE82UEKrEbAw&s=ptoJQh31bcvWLOX2JuDUWCYcsQ5UGbYWpeEurEKpVwc&e= , or unsubscribe < https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AMSYO2ACEFYRBMRCU2AXN2TQO7YH3ANCNFSM4JBUJ3PA&d=DwMCaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=h9RKr5QNh_YWQ8j48jaEWcJeekfImwLqE82UEKrEbAw&s=SwGxt8db5ppENjRPWyoPWltGArKX3uk_f_klkJuMpxo&e=

.

--

Mark (Tony) Smedal

Product Ops Team Lead Heartland (866) 802-9753

A Global Payments Company

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/globalpayments/php-sdk/issues/37?email_source=notifications&email_token=ALUIIRFYXXBIW57L4PF4EYLQPBJNFA5CNFSM4JBUJ3PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBP4DTI#issuecomment-543146445, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALUIIRHVN4AHDJ5AJP5R6K3QPBJNFANCNFSM4JBUJ3PA .

--

Algie Caballes

Sr. PHP Developer / Software Engineer

acaballes@fullscale.io change@me.com

www.fullscale.io https://fullscale.io/

[image: Full Scale Facebook] https://www.facebook.com/fullscalellc/ [image: Full Scale Linkedin] https://www.linkedin.com/company/fullscale-io/ [image: Full Scale Linkedin] https://startuphustle.xyz/ [image: Full Scale] https://fullscale.io/

hpsTony commented 5 years ago

Hi Algie,

Sure thing, I'll provide an update as soon as multi-use tokens are enabled on your developer account.

I don't think we have any examples that'd be useful to you aside from the transaction examples that show how to obtain and utilize the multi-use tokens themselves on this page: https://developer.heartlandpaymentsystems.com/Documentation/credit-card-payments

Our gateway/SDKs support various reporting functionality which might help depending on what you need to retrieve: https://developer.heartlandpaymentsystems.com/Documentation/reporting

Let me know if this helps.

On Thu, Oct 17, 2019 at 8:11 PM acaballesfullscale notifications@github.com wrote:

Hi thanks a lot for the response.

Currently Im on my way to implement and request for a multi-use token to store credit card information, now I have a little problem that i think you can help me. Seems like I need some representative from your good organization to enable my account to take advantage of multi-token use. My Heartland developer portal account email address is devteam@facilityally.com

To be more specific, in this documentation

https://developer.heartlandpaymentsystems.com/Documentation/credit-card-payments , it says a message "Multi-Use tokens are not enabled by default. You must contact your Heartland Representative to request this functionality on your account."

And also, if you can provide me a specific PHP code snippet example to store credit card information and retrieve it after, that would be awesome and helps my development fast and make my client happy.

Cheers, Algie

On Thu, Oct 17, 2019 at 8:15 PM hpsTony notifications@github.com wrote:

Hi Algie,

Yes, our SDK offers a couple of ways of going about this. The easiest path is probably to use multi-use tokens to convert and store customers' payment information in a non-sensitive way. Documentation on how to do so can be found on this page <

https://developer.heartlandpaymentsystems.com/Documentation/credit-card-payments

under the Using Multi-Use Tokens heading (about half way down the page).

Let me know if this helps or if you have any other questions.

On Thu, Oct 17, 2019 at 8:04 AM acaballesfullscale < notifications@github.com> wrote:

Hi,

I am currently a developer and Im implementing Heartland/global payments solution to one of my clients. And My client request that maybe we can add "remember me" option in the embedded secure submit form, is it posible in the current SDK? If so, can someone walk me through on how to do it like api call to get card details?

Thanks, Algie

— You are receiving this because you are subscribed to this thread. Reply to this email directly, view it on GitHub <

https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_globalpayments_php-2Dsdk_issues_37-3Femail-5Fsource-3Dnotifications-26email-5Ftoken-3DAMSYO2FM6OAF4MY5VP36XWLQO7YH3A5CNFSM4JBUJ3PKYY3PNVWWK3TUL52HS4DFUVEXG43VMWVGG33NNVSW45C7NFSM4HSLDWMQ&d=DwMCaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=h9RKr5QNh_YWQ8j48jaEWcJeekfImwLqE82UEKrEbAw&s=ptoJQh31bcvWLOX2JuDUWCYcsQ5UGbYWpeEurEKpVwc&e=

, or unsubscribe <

https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AMSYO2ACEFYRBMRCU2AXN2TQO7YH3ANCNFSM4JBUJ3PA&d=DwMCaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=h9RKr5QNh_YWQ8j48jaEWcJeekfImwLqE82UEKrEbAw&s=SwGxt8db5ppENjRPWyoPWltGArKX3uk_f_klkJuMpxo&e=

.

--

Mark (Tony) Smedal

Product Ops Team Lead Heartland (866) 802-9753

A Global Payments Company

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub < https://github.com/globalpayments/php-sdk/issues/37?email_source=notifications&email_token=ALUIIRFYXXBIW57L4PF4EYLQPBJNFA5CNFSM4JBUJ3PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBP4DTI#issuecomment-543146445 , or unsubscribe < https://github.com/notifications/unsubscribe-auth/ALUIIRHVN4AHDJ5AJP5R6K3QPBJNFANCNFSM4JBUJ3PA

.

--

Algie Caballes

Sr. PHP Developer / Software Engineer

acaballes@fullscale.io change@me.com

www.fullscale.io https://fullscale.io/

[image: Full Scale Facebook] https://www.facebook.com/fullscalellc/ [image: Full Scale Linkedin] https://www.linkedin.com/company/fullscale-io/ [image: Full Scale Linkedin] https://startuphustle.xyz/ [image: Full Scale] https://fullscale.io/

— You are receiving this because you commented. Reply to this email directly, view it on GitHub https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_globalpayments_php-2Dsdk_issues_37-3Femail-5Fsource-3Dnotifications-26email-5Ftoken-3DAMSYO2AMKB7RKLKTBNTGCC3QPD5KRA5CNFSM4JBUJ3PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBR6ZXY-23issuecomment-2D543419615&d=DwMFaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=U3wCwfwqH8_Dv7uVqwNEbFa6W0IQNm4KWgiZXAGx3Vs&s=Ba9ly_j-jSwXfnVD5Di3mc0xOiZieFzPqZCLTkmxPFI&e=, or unsubscribe https://urldefense.proofpoint.com/v2/url?u=https-3A__github.com_notifications_unsubscribe-2Dauth_AMSYO2AY3X3PE24GRB5LHX3QPD5KRANCNFSM4JBUJ3PA&d=DwMFaQ&c=f7K5vTjsy0ldRUVHx_C48Q&r=_27fn_8_IhzJN4MY8P68scjUx2U8z-w6F9lyRqIndSk&m=U3wCwfwqH8_Dv7uVqwNEbFa6W0IQNm4KWgiZXAGx3Vs&s=zhyt5qgiNxmTT0dLHj3TDoJHVrD4nkwuctwqL11y_4o&e= .

--

Mark (Tony) Smedal

Product Ops Team Lead Heartland (866) 802-9753

A Global Payments Company

eric-vest commented 5 years ago

Hi Algie,

To have multi-use tokenization enabled on your developer account, please contact SecureSubmitCert@e-hps.com. Just say you need multi-use tokens enabled and supply them with the email address associated with your developer portal account.

Here is an example for how to retrieve a multi-use token and then charge it: https://github.com/globalpayments/php-sdk/blob/f4c53927add6be18825860a216f605eb334dcfc2/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.php#L67-L84

In this example, we're running a verify transaction and setting withRequestMultiUseToken to true. If we've successfully retrieved the token, we can get it from the response, add it to our card object, then charge that card object.

If you wanted to request the multi-use token during a charge rather than a verify, you can simply perform a charge with the single-use token and add withRequestMultiUseToken(true) to that transaction.

$response = $card->charge(10) ->withCurrency('USD') ->withRequestMultiUseToken(true) ->execute();

acaballesfullscale commented 5 years ago

Hi Eric,

My goals for implementing globalpayment are these:

  1. Create customer / retrieve customer (we can currently retrieve data by its ID) Create: $customer = new Customer(); $customer->id = $this->getIdentifier('Person'); ........ ........ $newCustomer = $customer->create();

Retrieve: customer = new Customer(); $customerData = $customer->find($id);

  1. charge and process payment with the specific customer $card = new CreditCardData(); $card->token = $token;

    try {
        // create customer
        if (empty($customer)) {
            $customer = $this->createCustomer();
        }
    
        $response = $card->charge($this->amount)
            ->withCurrency(strtoupper($this->currency))
            ->withAddress($this->address)
            ->withCustomerData($customer)
            ->withRequestMultiUseToken(true)
            ->execute();
        $transactionId = $response->transactionId;
    } catch (Exception $e) {
        throw new \Exception($e->getMessage());
    }

I already implemented this one currently using single token as what generated in the embedded secure submit form using global payment javascript library. And My questions are:

  1. During client pay again a specific amount, what ID or reference key to use when charging a recurring customer? is it transaction ID? will appreciate more if add a simple example. or this will do during charge we also include customer data $response = $card->charge($this->amount) ->withCurrency(strtoupper($this->currency)) ->withAddress($this->address) ->withCustomerData($customer) ->withRequestMultiUseToken(true) ->execute();

  2. How can we get payment data information for that specific recurring customer? is it correct to use transaction ID to get the transaction details? like this? $details = ReportingService::transactionDetail($transactionId);

In summary, I am going to implement remember me option for customer to not input over and over again in the form their card details, instead they are going only to pay using thier previous most used credit card and In getting those stored card from the customer data. Any feedbacks regarding my issue will be more appreciated.

Cheers, Algie

On Fri, Oct 18, 2019 at 11:24 PM eric-vest notifications@github.com wrote:

Hi Algie,

To have multi-use tokenization enabled on your developer account, please contact SecureSubmitCert@e-hps.com. Just say you need multi-use tokens enabled and supply them with the email address associated with your developer portal account.

Here is an example for how to retrieve a multi-use token and then charge it:

https://github.com/globalpayments/php-sdk/blob/f4c53927add6be18825860a216f605eb334dcfc2/test/Integration/Gateways/PorticoConnector/Certifications/RetailTest.php#L67-L84

In this example, we're running a verify transaction and setting withRequestMultiUseToken to true. If we've successfully retrieved the token, we can get it from the response, add it to our card object, then charge that card object.

If you wanted to request the multi-use token during a charge rather than a verify, you can simply perform a charge with the single-use token and add withRequestMultiUseToken(true) to that transaction.

$response = $card->charge(10) ->withCurrency('USD') ->withRequestMultiUseToken(true) ->execute();

— You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub https://github.com/globalpayments/php-sdk/issues/37?email_source=notifications&email_token=ALUIIRCJLT3UETFRK5W7B7TQPHILTA5CNFSM4JBUJ3PKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEBU2WRQ#issuecomment-543796038, or unsubscribe https://github.com/notifications/unsubscribe-auth/ALUIIRDUVCVQTJ46X2PCZA3QPHILTANCNFSM4JBUJ3PA .

--

Algie Caballes

Sr. PHP Developer / Software Engineer

acaballes@fullscale.io change@me.com

www.fullscale.io https://fullscale.io/

[image: Full Scale Facebook] https://www.facebook.com/fullscalellc/ [image: Full Scale Linkedin] https://www.linkedin.com/company/fullscale-io/ [image: Full Scale Linkedin] https://startuphustle.xyz/ [image: Full Scale] https://fullscale.io/