Apple Pay NOT Working

Any reason Apple Pay is not working on either my own website or on even Squares own Website, I know that it only works in Safari and I have tested on my iPhone iPad and macBook, I have even view the checkout process on Squares own website and its not working there either, console is throwing this error:

 

Unrecognized Content-Security-Policy directive 'require-trusted-types-for'.

and

Unrecognized Content-Security-Policy directive 'worker-src'.

Ashley Bailey
3,754 Views
Message 1 of 8
Report
1 Solution

Solution

After extensive debugging I was able to close down on the issue and traced it down to missing CSS values 

    #apple-pay-button {
        height: 48px;
        width: 100%;
        display: inline-block;
        -webkit-appearance: -apple-pay-button;
        -apple-pay-button-type: plain;
        -apple-pay-button-style: black;
        margin-bottom: 5px;
    }

 

apologies for the inconvenience, when reading documentations the wording had me believe that the CSS values were optional for further customization and that Apple Pay would take on on a default configuration otherwise.

Ashley Bailey

View Solution >

3,741 Views
Message 7 of 8
Report
7 REPLIES 7
Admin

Sorry to hear this @realashleybaile! Can you share a link to your website with me? I can take a closer look at this on my end.

Tra | she/her
Community Program Manager, Square
3,752 Views
Message 2 of 8
Report

Unfortunately the website is under private development so wouldn't be able to however I can share Screenshots and Code

Ashley Bailey
3,751 Views
Message 3 of 8
Report

I have attached screenshots of my console log and page, I am running the site on a local server on https connection with a registered domain that I have added to my Developer Dashboard and Verified, here is also a link to my Javascript code https://jsfiddle.net/0so8td47/

Screenshot 2021-10-28 at 9.51.41 am.pngScreenshot 2021-10-28 at 9.50.31 am.png

Ashley Bailey
3,750 Views
Message 4 of 8
Report
Admin

Thanks for sending that on @realashleybaile! To make sure I can get the right team to look into this, can you let me know if this was a Square Online site or if you are using our API documentations?

 

If it's a Square Online site, the team would need a link to the website in order to investigate it further. 

Tra | she/her
Community Program Manager, Square
3,749 Views
Message 5 of 8
Report

Hi, so my website is using the API documentation, however to further investigate the situation I attempted to load the checkout on my square online site and it would not load Apple Pay on there either it appears that the same error show in the console on there too.

Ashley Bailey
3,742 Views
Message 6 of 8
Report

Solution

After extensive debugging I was able to close down on the issue and traced it down to missing CSS values 

    #apple-pay-button {
        height: 48px;
        width: 100%;
        display: inline-block;
        -webkit-appearance: -apple-pay-button;
        -apple-pay-button-type: plain;
        -apple-pay-button-style: black;
        margin-bottom: 5px;
    }

 

apologies for the inconvenience, when reading documentations the wording had me believe that the CSS values were optional for further customization and that Apple Pay would take on on a default configuration otherwise.

Ashley Bailey
3,742 Views
Message 7 of 8
Report
Square

Hi @realashleybaile, we're glad to hear you resolved it. Have a great day!

Emma
Community Manager, Square
3,735 Views
Message 8 of 8
Report