Expand my Community achievements bar.

PDFServicesSDK throws ServiceApiException Cannot send a content-body with this verb-type

Avatar

Level 1

Consistently receive this error when executing a CreatePDFOperation:

Credentials credentials = Credentials.ServicePrincipalCredentialsBuilder()
.WithClientId("myclientid")
.WithClientSecret("myclientsecret")
.Build();

Adobe.PDFServicesSDK.ExecutionContext executionContext = Adobe.PDFServicesSDK.ExecutionContext.Create(credentials);

CreatePDFOperation createPDFOperation = CreatePDFOperation.CreateNew();

FileRef flSource = FileRef.CreateFromStream(inputstream, CreatePDFOperation.SupportedSourceFormat.DOCX.GetMediaType());

createPDFOperation.SetInput(flSource);

 

Throws exception here:

FileRef flResult = createPDFOperation.Execute(executionContext);

0 Replies