@@ -65,7 +65,11 @@ async function testDocxToMarkdown() {
6565 method : 'POST' ,
6666 headers : {
6767 'Content-Type' : 'application/json' ,
68- 'Authorization' : 'Bearer YOUR_AUTH_TOKEN' // Replace with actual token
68+ // Use one of the following authentication methods:
69+ // 1. For JWT tokens:
70+ // 'Authorization': 'Bearer YOUR_JWT_TOKEN', // Replace with actual JWT token
71+ // 2. For API keys (comment out the Authorization header above and use this instead):
72+ 'X-API-Key' : 'YOUR_API_KEY' // Replace with actual API key (starts with pfs_)
6973 } ,
7074 body : JSON . stringify ( {
7175 file : testDocxBase64 ,
@@ -99,7 +103,11 @@ async function testDocToMarkdown() {
99103 method : 'POST' ,
100104 headers : {
101105 'Content-Type' : 'application/json' ,
102- 'Authorization' : 'Bearer YOUR_AUTH_TOKEN' // Replace with actual token
106+ // Use one of the following authentication methods:
107+ // 1. For JWT tokens:
108+ // 'Authorization': 'Bearer YOUR_JWT_TOKEN', // Replace with actual JWT token
109+ // 2. For API keys (comment out the Authorization header above and use this instead):
110+ 'X-API-Key' : 'YOUR_API_KEY' // Replace with actual API key (starts with pfs_)
103111 } ,
104112 body : JSON . stringify ( {
105113 file : testDocBase64 ,
@@ -133,7 +141,11 @@ async function testEpubToMarkdown() {
133141 method : 'POST' ,
134142 headers : {
135143 'Content-Type' : 'application/json' ,
136- 'Authorization' : 'Bearer YOUR_AUTH_TOKEN' // Replace with actual token
144+ // Use one of the following authentication methods:
145+ // 1. For JWT tokens:
146+ // 'Authorization': 'Bearer YOUR_JWT_TOKEN', // Replace with actual JWT token
147+ // 2. For API keys (comment out the Authorization header above and use this instead):
148+ 'X-API-Key' : 'YOUR_API_KEY' // Replace with actual API key (starts with pfs_)
137149 } ,
138150 body : JSON . stringify ( {
139151 file : testEpubBase64 ,
@@ -167,7 +179,11 @@ async function testTextToMarkdown() {
167179 method : 'POST' ,
168180 headers : {
169181 'Content-Type' : 'application/json' ,
170- 'Authorization' : 'Bearer YOUR_AUTH_TOKEN' // Replace with actual token
182+ // Use one of the following authentication methods:
183+ // 1. For JWT tokens:
184+ // 'Authorization': 'Bearer YOUR_JWT_TOKEN', // Replace with actual JWT token
185+ // 2. For API keys (comment out the Authorization header above and use this instead):
186+ 'X-API-Key' : 'YOUR_API_KEY' // Replace with actual API key (starts with pfs_)
171187 } ,
172188 body : JSON . stringify ( {
173189 file : testTextBase64 ,
@@ -201,7 +217,11 @@ async function testPptxToMarkdown() {
201217 method : 'POST' ,
202218 headers : {
203219 'Content-Type' : 'application/json' ,
204- 'Authorization' : 'Bearer YOUR_AUTH_TOKEN' // Replace with actual token
220+ // Use one of the following authentication methods:
221+ // 1. For JWT tokens:
222+ // 'Authorization': 'Bearer YOUR_JWT_TOKEN', // Replace with actual JWT token
223+ // 2. For API keys (comment out the Authorization header above and use this instead):
224+ 'X-API-Key' : 'YOUR_API_KEY' // Replace with actual API key (starts with pfs_)
205225 } ,
206226 body : JSON . stringify ( {
207227 file : testPptxBase64 ,
@@ -235,7 +255,11 @@ async function testXlsxToMarkdown() {
235255 method : 'POST' ,
236256 headers : {
237257 'Content-Type' : 'application/json' ,
238- 'Authorization' : 'Bearer YOUR_AUTH_TOKEN' // Replace with actual token
258+ // Use one of the following authentication methods:
259+ // 1. For JWT tokens:
260+ // 'Authorization': 'Bearer YOUR_JWT_TOKEN', // Replace with actual JWT token
261+ // 2. For API keys (comment out the Authorization header above and use this instead):
262+ 'X-API-Key' : 'YOUR_API_KEY' // Replace with actual API key (starts with pfs_)
239263 } ,
240264 body : JSON . stringify ( {
241265 file : testXlsxBase64 ,
0 commit comments