Unable to import (422)
See original GitHub issueExpected Behavior
I would like to export an entry ‘testtitre_aq’ from ‘developmentSA’ env :
The entry is exported in the JSON generated file :
The import into another env ‘devtest’ should work.
Actual Behavior
Possible Solution
Bug ??
Steps to Reproduce
- contentful login (OAuth via browser token)
- contentful space export --environment-id ‘developmentSA’ --query-entries ‘sys.id=6uhYB6FxV1TIzxAJSkkuvk’
- contentful space import --environment-id ‘devtest’ --content-file contentful-export-<space_id>-developmentSA-2019-08-21T11-15-89.json
Context
Environment
Node : v10.16.3 Npm : 6.9.0 OS : Windows 10 - 64 bits
Contentful-CLI : 0.36.2
Issue Analytics
- State:
- Created 4 years ago
- Comments:28 (13 by maintainers)
Top Results From Across the Web
422 when importing from GitHub (logs: Username needs to ...
An error message appears, "An error occurred while importing project: Error: Request failed with status code 422". What is the expected correct ...
Read more >Unable to import Apple ProRes 422 HQ into Resolve - Reddit
Hi all, im trying to import a batch of ProRes files into Resolve for grading but have had no luck. Ive tried converting...
Read more >Error 422 When Exporting Contact From Clio Grow to Clio ...
Unable to export contact to Clio Manage; Error: Request failed with status code 401. Environment: Clio Grow. Additional Information:.
Read more >Python: FastAPI error 422 with POST request when sending ...
from fastapi import FastAPI from pydantic import BaseModel app ... if a post fails there, it's likely a syntax/logic error and not related ......
Read more >Can't import ProRes 422 files at DVinfo.net
Regular Crew. Join Date: Jul 2010. Location: Long Beach, CA. Posts: 150. Can't import ProRes 422 files. Another cross-platform problem.
Read more >Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start FreeTop Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
Top GitHub Comments
Hi @phoebeschmidt ,
Finally …
So here is my scenario. In my sandbox
devtest
, I created a new entry associated with anexisting
content type(CT), then exported using the export CLI :contentful space export --environment-id 'devtest' --query-entries 'sys.id[in]=2ZzuXC4ZDC0udbn6Fijbgp' --content-only
It is important to specify
content-only
. This will export just one entry, but will a bunch of Assets.When importing, it is important to note that the CT
MUST
exists in the importing sandbox.You can close this ticket, but I have other question in another ticket.
Thanks @Khaledgarbaya & @phoebeschmidt
Hi Baumars,
My understanding is the following:
contentful space export --environment-id 'devtest' --query-entries 'sys.id[in]=xxxx'
This command will create a JSON file with the following format:(this information is in our README, btw).
You can check this exported json file for which of your contents were actually exported. Specifically, check the
entries
array to see if your--query-entries
flag successfully found just a single entry to import.If you don’t want to import assets, content_types, webhooks, roles, etc, you can remove those arrays from the JSON file.
Important If you want to only import one entry, the space must already have the relevant content type (that is, the content type of the entry you want to import).
I hope this clears up some of your misunderstanding. I would also like to point you to some helpful resources:
guide for import/export using cli: https://www.contentful.com/developers/docs/tutorials/cli/import-and-export/ contentful import https://github.com/contentful/contentful-import contentful export https://github.com/contentful/contentful-export