# Your example is missing a crucial file

**URL:** <https://developer.squareup.com/forums/t/your-example-is-missing-a-crucial-file/7399>\
**Category:** Questions\
**Created:** [October 28, 2022, 1:10pm UTC](https://developer.squareup.com/forums/t/your-example-is-missing-a-crucial-file/7399 "2022-10-28T13:10:27Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![mudmin](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/mudmin/32/1536_2.png) [@mudmin](https://developer.squareup.com/forums/u/mudmin)\
**Post date:** [October 28, 2022, 1:10pm UTC](https://developer.squareup.com/forums/t/your-example-is-missing-a-crucial-file/7399/1 "2022-10-28T13:10:27Z")

</div>

I’m new to the square api and it seems like all examples show one set of code snippets but whenever you click on the “get the code here” link it inevitably takes you to this example…

> <https://github.com/square/web-payments-quickstart/blob/main/public/examples/card.html>

Which would be okay if it worked but it’s looking for this on line 26  
const paymentResponse = await fetch(‘/payment’, {  
method: ‘POST’,

and I’m not finding that file anywhere. Does anyone have that file in preferably php or any kind of point in the right direction.

---

<div class="post-metadata">

**Author:** ![Bryan-Square](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/bryan-square/32/38_2.png) [@Bryan-Square](https://developer.squareup.com/forums/u/Bryan-Square)\
**Post date:** [October 28, 2022, 4:48pm UTC](https://developer.squareup.com/forums/t/your-example-is-missing-a-crucial-file/7399/2 "2022-10-28T16:48:27Z")

</div>

👋 The `/payment` function is in the [server.js](https://github.com/square/web-payments-quickstart/blob/main/server.js) file of the quickstart. That’s where the tokenized card that the form generates is posting the `source_id` to. 🙂

---

<div class="post-metadata">

**Author:** ![mudmin](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/mudmin/32/1536_2.png) [@mudmin](https://developer.squareup.com/forums/u/mudmin)\
**Post date:** [October 28, 2022, 5:29pm UTC](https://developer.squareup.com/forums/t/your-example-is-missing-a-crucial-file/7399/3 "2022-10-28T17:29:12Z")

</div>

Thanks for this. Like I said, I was linked there from a bunch of various tutorials and examples I didn’t realize it was node. I thought it worked like stripe and was vanilla javascript.

---

<div class="post-metadata">

**Author:** ![Bryan-Square](https://sea1.discourse-cdn.com/square/forums/user_avatar/developer.squareup.com/bryan-square/32/38_2.png) [@Bryan-Square](https://developer.squareup.com/forums/u/Bryan-Square)\
**Post date:** [October 28, 2022, 7:00pm UTC](https://developer.squareup.com/forums/t/your-example-is-missing-a-crucial-file/7399/4 "2022-10-28T19:00:21Z")

</div>

Glad to hear you got it to work as expected. 🙂
