• Global community
    • Language:
      • Deutsch
      • English
      • Español
      • Français
      • Português
  • 日本語コミュニティ
    Dedicated community for Japanese speakers
  • 한국 커뮤니티
    Dedicated community for Korean speakers
Exit
1

400 Error when attempting to convert word files to PDF

New Here ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

Using the NodeJS sdk we keep getting 400 errors on files that previously worked to convert.

 

2023-01-31T08:43:16.574:[INFO]: All validations successfully done. Beginning PDF conversion
ServiceApiError:
    at rejectWithServiceApiError (/Users/casper/Projects/proj/backend/node_modules/@adobe/pdfservices-node-sdk/src/internal/http/http-client.js:31:17)
    at handleJsonResponse (/Users/casper/Projects/proj/backend/node_modules/@adobe/pdfservices-node-sdk/src/internal/http/http-client.js:55:3)
    at handleErrorResponse (/Users/casper/Projects/proj/backend/node_modules/@adobe/pdfservices-node-sdk/src/internal/http/http-client.js:117:2)
    at onEnd (/Users/casper/Projects/proj/backend/node_modules/@adobe/pdfservices-node-sdk/src/internal/http/http-client.js:176:3)
    at IncomingMessage.<anonymous> (/Users/casper/Projects/proj/backend/node_modules/@adobe/pdfservices-node-sdk/src/internal/http/http-client.js:216:5)
    at /Users/casper/Projects/proj/backend/node_modules/@opentelemetry/context-async-hooks/src/AbstractAsyncHooksContextManager.ts:74:49
    at AsyncLocalStorage.run (node:async_hooks:311:14)
    at AsyncLocalStorageContextManager.with (/Users/casper/Projects/proj/backend/node_modules/@opentelemetry/context-async-hooks/src/AsyncLocalStorageContextManager.ts:40:36)
    at IncomingMessage.contextWrapper (/Users/casper/Projects/proj/backend/node_modules/@opentelemetry/context-async-hooks/src/AbstractAsyncHooksContextManager.ts:74:26)
    at IncomingMessage.emit (node:events:532:35) {
  requestTrackingId: undefined,
  statusCode: 400,
  errorCode: 'UNKNOWN'
}

Views

1.9K

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

Hi, same problem here - I have a subscription bought from AWS Marketplace - was working until Jan 30 5PM GMT...

 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Expert ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

I ran into that myself yesterday. Try updating to the latest SDKs. You shouldn't need to modify your code other than that.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

Anyone found the root cause of this issue? We also experienced the same behavior today. Our application is in production and can't update to the latest SDK version right away.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

updating the node sdk to the latest version fixed the issue (3.2.0)

Incredible that Adobe didn't handle that better, at least returning an explicit error about client being incompatible anymore...

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

By any chance do you remember which version you had before?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

@Raymond Camden we were using pdfservices-node-sdk v2.2.3 and it was working for months up until today.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Jan 31, 2023 Jan 31, 2023

Copy link to clipboard

Copied

Facing the same issue! Migrated to version 3.2.0 and see another error popping up

OCR-Extraction/node_modules/@adobe/pdfservices-node-sdk/src/internal/http/http-client.js:80
|| (result.content.error?.details?.error_code && apiGatewaySubErrorCodesForStatus[result.content.error.details.error_code]))) {
^

SyntaxError: Unexpected token .
at Module._compile (internal/modules/cjs/loader.js:723:23)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)
at Module.load (internal/modules/cjs/loader.js:653:32)
at tryModuleLoad (internal/modules/cjs/loader.js:593:12)
at Function.Module._load (internal/modules/cjs/loader.js:585:3)
at Module.require (internal/modules/cjs/loader.js:692:17)
at require (internal/modules/cjs/helpers.js:25:18)
at Object.<anonymous> (/home/ubuntu/projects/OCR-Extraction/node_modules/@adobe/pdfservices-node-sdk/src/internal/http/http-request.js:12:18)
at Module._compile (internal/modules/cjs/loader.js:778:30)
at Object.Module._extensions..js (internal/modules/cjs/loader.js:789:10)

Anyone face the same?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Feb 01, 2023 Feb 01, 2023

Copy link to clipboard

Copied

We've been able to discover why the earlier SDKs stopped working and we're working on a fix asap. As to this issue, it may be something else. Do you mind sharing what you were trying to do (ie, what action), and your input?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 01, 2023 Feb 01, 2023

Copy link to clipboard

Copied

Raymond, we are using functionality to split the pdf. Upon debugging, we found the issue arising at module import line below:

const PDFServicesSdk = require('@adobe/pdfservices-node-sdk');
The current version of the sdk being used is --> @adobe/pdfservices-node-sdk@3.2.0

FYI, the exact code was working with the older version

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 01, 2023 Feb 01, 2023

Copy link to clipboard

Copied

Yes I was having the same problem then you. It happen because you use a version of Node < 14. 

So you have three possibilities to fix it:
- Upgrade your project to Node version >= 14
- Waiting Adobe's team fix this issue
- Make the new version working on Node < 14 by yourself

In my project, I choose the 3rd one. For that, you need:

- Copy the last version of the adobe librairy in your porject

- Replace in that librairy  all ".?" by "."
- Replace your require("@adobe/pdfservices-node-sdk") by require('<path to custom library>/pdfservices-sdk');

But it's really important to understand that this solution is just an unstable fix waiting for adobe's team to fix that more clean. Removing all the ".?" can create a lot of issues.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Feb 01, 2023 Feb 01, 2023

Copy link to clipboard

Copied

I'd highly recommend 1 myself, or even better, the LTS version.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Feb 01, 2023 Feb 01, 2023

Copy link to clipboard

Copied

Totally agree, but not possible for a lot of legacy project.

I will really appreciate that the Adobe's team find a solution. I have that probleme using Node 11 and Adobe librairy 2.2.3.

 

@Raymond Camden Don't hesitate to contact me if you need some help to understand better our probleme.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 01, 2023 Feb 01, 2023

Copy link to clipboard

Copied

Thanks @Glenn263035267yqi for the potential fix! Let me try and revert back!

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Community Beginner ,
Feb 01, 2023 Feb 01, 2023

Copy link to clipboard

Copied

Updated node to version 14.21.2 and it worked! Thanks for the support 🙂

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Feb 02, 2023 Feb 02, 2023

Copy link to clipboard

Copied

Update:

Today we released a new 2.x version of the SDK, 2.3.0. For folks who can't upgrade to 3.x, you can select this version, but we *highly* recommend migrating to 3.x as soon as possible. 2.X is EOL by September of 2023. 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 20, 2023 Apr 20, 2023

Copy link to clipboard

Copied

We are getting same issue all of a sudden with Node v12.x and 

@adobe/pdfservices-node-sdk 2.1.0

We have solution deployed in production, so updating to latest is non-starter. 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Apr 20, 2023 Apr 20, 2023

Copy link to clipboard

Copied

You can't update to 2.3.0? That's a minor update, not a major one.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 20, 2023 Apr 20, 2023

Copy link to clipboard

Copied

This is not how it works. Our production site has been broken since yesterday because of this and we come to find out 12 hours later. I can't just upgrade package in production just like that regardless of whether its minor or major. Also, we are now getting 500 error code now. We were getting 400 earlier.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Adobe Employee ,
Apr 20, 2023 Apr 20, 2023

Copy link to clipboard

Copied

I'm not sure what you want me to say here though. If the issue is corrected through an updated package... than that's the only recorse. In your dev environment, can you recreate and confirm you get the same issue, and then test there?

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 20, 2023 Apr 20, 2023

Copy link to clipboard

Copied

Looks like 500 error was intermittent. 

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
New Here ,
Apr 20, 2023 Apr 20, 2023

Copy link to clipboard

Copied

LATEST

We are doing this upgrade and test in dev environment. Now, we need to figure how to create a patch and deploy to production as emergency patch. Not expecting company like Adobe to not see the impact this can have.

Votes

Translate

Translate

Report

Report
Community guidelines
Be kind and respectful, give credit to the original source of content, and search for duplicates before posting. Learn more
community guidelines
Resources