{"id":8512,"date":"2025-01-21T09:30:51","date_gmt":"2025-01-21T04:00:51","guid":{"rendered":"https:\/\/pheonixsolutions.com\/blog\/?p=8512"},"modified":"2025-01-21T09:37:54","modified_gmt":"2025-01-21T04:07:54","slug":"using-graphql-to-create-blogs-with-image-uploads-in-mongodb","status":"publish","type":"post","link":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/","title":{"rendered":"Using GraphQL to Create Blogs with Image Uploads in MongoDB"},"content":{"rendered":"\n<p><strong>Using GraphQL to Create Blogs with Image Uploads in MongoDB<\/strong><\/p>\n\n\n\n<p>To implement blog creation with image uploads, we\u2019ll use <strong>Apollo Server<\/strong> for GraphQL, <strong>MongoDB<\/strong> for data storage, and <strong>GridFS<\/strong> for handling binary file storage. Follow the steps below for seamless integration.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\" \/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Prerequisites<\/strong><\/h3>\n\n\n\n<p>Install the required dependencies using Yarn:<\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>yarn add apollo-server graphql multer graphql-upload mongodb<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p>Enable file uploads in Apollo Server with the graphql-upload package.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\" \/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Implementation<\/strong><\/h3>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>1. Setup Apollo Server with File Uploads<\/strong><\/h4>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td><strong>const<\/strong> resolvers = {<br>&nbsp; Upload: GraphQLUpload,<br>&nbsp; Mutation: {<br>&nbsp; &nbsp; createBlog: <strong>async<\/strong> (<br>&nbsp; &nbsp; &nbsp; _: any,<br>&nbsp; &nbsp; &nbsp; { title, content, image }: { title: string; content: string; image?: FileUpload }<br>&nbsp; &nbsp; ) =&gt; {<br>&nbsp; &nbsp; &nbsp; <strong>let<\/strong> imageId = null;<br><br>&nbsp; &nbsp; &nbsp; <strong>if<\/strong> (image) {<br>&nbsp; &nbsp; &nbsp; &nbsp; <strong>const<\/strong> { createReadStream, filename, mimetype } = <strong>await<\/strong> image;<br>&nbsp; &nbsp; &nbsp; &nbsp; <strong>const<\/strong> stream = createReadStream();<br><br>&nbsp; &nbsp; &nbsp; &nbsp; imageId = <strong>await<\/strong> <strong>new<\/strong> Promise((resolve, reject) =&gt; {<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; <strong>const<\/strong> uploadStream = bucket.openUploadStream(filename, { contentType: mimetype });<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; stream.pipe(uploadStream);<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; uploadStream.on(&#8220;finish&#8221;, () =&gt; resolve(uploadStream.id.toString()));<br>&nbsp; &nbsp; &nbsp; &nbsp; &nbsp; uploadStream.on(&#8220;error&#8221;, reject);<br>&nbsp; &nbsp; &nbsp; &nbsp; });<br>&nbsp; &nbsp; &nbsp; }<br><br>&nbsp; &nbsp; &nbsp; <strong>const<\/strong> blog = {<br>&nbsp; &nbsp; &nbsp; &nbsp; title,<br>&nbsp; &nbsp; &nbsp; &nbsp; content,<br>&nbsp; &nbsp; &nbsp; &nbsp; imageId,<br>&nbsp; &nbsp; &nbsp; &nbsp; createdAt: <strong>new<\/strong> Date().toISOString(),<br>&nbsp; &nbsp; &nbsp; };<br><br>&nbsp; &nbsp; &nbsp; <em>\/\/ Assume `saveBlog` is a function to insert data into MongoDB or another database<\/em><br>&nbsp; &nbsp; &nbsp; <strong>const<\/strong> result = <strong>await<\/strong> saveBlog(blog);<br><br>&nbsp; &nbsp; &nbsp; <strong>return<\/strong> { id: result.id, &#8230;blog };<br>&nbsp; &nbsp; },<br>&nbsp; },<br>};<br><\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\" \/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Explanation<\/strong><\/h3>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>GraphQL Schema<\/strong><\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>Upload Scalar<\/strong>: Handles file uploads using the graphql-upload package.<\/li>\n\n\n\n<li><strong>createBlog Mutation<\/strong>: Accepts title, content, and an optional image file.<\/li>\n\n\n\n<li><strong>blogs Query<\/strong>: Retrieves all blog posts with their metadata.<\/li>\n<\/ul>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>Resolvers<\/strong><\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li><strong>createBlog Mutation<\/strong>:\n<ul class=\"wp-block-list\">\n<li>Processes the image file using createReadStream and stores it in MongoDB GridFS.<\/li>\n\n\n\n<li>Saves the blog metadata (title, content, and imageId) in the blogs collection.<\/li>\n<\/ul>\n<\/li>\n\n\n\n<li><strong>blogs Query<\/strong>:\n<ul class=\"wp-block-list\">\n<li>Fetches all blogs from MongoDB and returns them, including the imageId.<\/li>\n<\/ul>\n<\/li>\n<\/ul>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>MongoDB GridFS<\/strong><\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Manages uploaded files in binary format.<\/li>\n\n\n\n<li>Generates a unique imageId for each file, stored alongside blog metadata.<\/li>\n<\/ul>\n\n\n\n<h4 class=\"wp-block-heading\"><strong>Apollo Server<\/strong><\/h4>\n\n\n\n<ul class=\"wp-block-list\">\n<li>Configured to support file uploads using graphql-upload.<\/li>\n<\/ul>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\" \/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Postman Operations<\/strong><\/h3>\n\n\n\n<p><strong>Mutation Name:<\/strong><strong><br><\/strong> createBlog<\/p>\n\n\n\n<p><strong>Description:<\/strong><strong><br><\/strong> The createBlog mutation allows you to create a blog post with the following parameters:<\/p>\n\n\n\n<ul class=\"wp-block-list\">\n<li>title (String, required): Title of the blog post.<\/li>\n\n\n\n<li>content (String, required): Content of the blog post.<\/li>\n\n\n\n<li>image (Upload, optional): An optional image file for the blog.<\/li>\n<\/ul>\n\n\n\n<p><strong>Mapping Example (Variables Section):<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>{<br>&nbsp; &#8220;map&#8221;: {<br>&nbsp; &nbsp; &#8220;&#8221;: [&#8220;variables.file&#8221;]<br>&nbsp; }<br>}<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong>File Input (Index 0):<\/strong><strong><br><\/strong> Map the file being uploaded as &#8220;variables.file&#8221;, specifying its name in Postman\u2019s file upload section.<\/p>\n\n\n\n<hr class=\"wp-block-separator has-alpha-channel-opacity\" \/>\n\n\n\n<h3 class=\"wp-block-heading\"><strong>Retrieving Blogs<\/strong><\/h3>\n\n\n\n<p><strong>Query:<\/strong><\/p>\n\n\n\n<figure class=\"wp-block-table\"><table class=\"has-fixed-layout\"><tbody><tr><td>query GetBlogs {<br>&nbsp; blogs {<br>&nbsp; &nbsp; id<br>&nbsp; &nbsp; title<br>&nbsp; &nbsp; content<br>&nbsp; &nbsp; imageId<br>&nbsp; &nbsp; createdAt<br>&nbsp; }<br>}<\/td><\/tr><\/tbody><\/table><\/figure>\n\n\n\n<p><strong>Description:<\/strong><strong><br><\/strong> This query retrieves all blog posts, including their metadata such as title, content, imageId, and createdAt.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Using GraphQL to Create Blogs with Image Uploads in MongoDB To implement blog creation with image uploads, we\u2019ll use Apollo Server for GraphQL, MongoDB for data storage, and GridFS for handling binary file storage. Follow the steps below for seamless integration. Prerequisites Install the required dependencies using Yarn: yarn add&hellip; <a href=\"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/\" class=\"more-link read-more\" rel=\"bookmark\">Continue Reading <span class=\"screen-reader-text\">Using GraphQL to Create Blogs with Image Uploads in MongoDB<\/span><i class=\"fa fa-arrow-right\"><\/i><\/a><\/p>\n","protected":false},"author":507,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"jetpack_post_was_ever_published":false,"_jetpack_newsletter_access":"","_jetpack_dont_email_post_to_subs":false,"_jetpack_newsletter_tier_id":0,"_jetpack_memberships_contains_paywalled_content":false,"_jetpack_memberships_contains_paid_content":false,"footnotes":""},"categories":[1],"tags":[],"class_list":{"0":"post-8512","1":"post","2":"type-post","3":"status-publish","4":"format-standard","5":"hentry","6":"category-uncategorized","7":"h-entry","9":"h-as-article"},"yoast_head":"<!-- This site is optimized with the Yoast SEO plugin v27.3 - https:\/\/yoast.com\/product\/yoast-seo-wordpress\/ -->\n<title>Pheonix Solutions - We Empower Your Business Growth<\/title>\n<meta name=\"robots\" content=\"index, follow, max-snippet:-1, max-image-preview:large, max-video-preview:-1\" \/>\n<link rel=\"canonical\" href=\"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/\" \/>\n<meta property=\"og:locale\" content=\"en_US\" \/>\n<meta property=\"og:type\" content=\"article\" \/>\n<meta property=\"og:title\" content=\"Pheonix Solutions - We Empower Your Business Growth\" \/>\n<meta property=\"og:description\" content=\"Using GraphQL to Create Blogs with Image Uploads in MongoDB To implement blog creation with image uploads, we\u2019ll use Apollo Server for GraphQL, MongoDB for data storage, and GridFS for handling binary file storage. Follow the steps below for seamless integration. Prerequisites Install the required dependencies using Yarn: yarn add&hellip; Continue Reading Using GraphQL to Create Blogs with Image Uploads in MongoDB\" \/>\n<meta property=\"og:url\" content=\"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/\" \/>\n<meta property=\"og:site_name\" content=\"PHEONIXSOLUTIONS\" \/>\n<meta property=\"article:publisher\" content=\"https:\/\/www.facebook.com\/PheonixSolutions-209942982759387\/\" \/>\n<meta property=\"article:published_time\" content=\"2025-01-21T04:00:51+00:00\" \/>\n<meta property=\"article:modified_time\" content=\"2025-01-21T04:07:54+00:00\" \/>\n<meta property=\"og:image\" content=\"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/09\/PX2.png\" \/>\n\t<meta property=\"og:image:width\" content=\"3837\" \/>\n\t<meta property=\"og:image:height\" content=\"2540\" \/>\n\t<meta property=\"og:image:type\" content=\"image\/png\" \/>\n<meta name=\"author\" content=\"bharat\" \/>\n<meta name=\"twitter:card\" content=\"summary_large_image\" \/>\n<meta name=\"twitter:creator\" content=\"@pheonixsolution\" \/>\n<meta name=\"twitter:site\" content=\"@pheonixsolution\" \/>\n<meta name=\"twitter:label1\" content=\"Written by\" \/>\n\t<meta name=\"twitter:data1\" content=\"bharat\" \/>\n\t<meta name=\"twitter:label2\" content=\"Est. reading time\" \/>\n\t<meta name=\"twitter:data2\" content=\"2 minutes\" \/>\n<script type=\"application\/ld+json\" class=\"yoast-schema-graph\">{\"@context\":\"https:\\\/\\\/schema.org\",\"@graph\":[{\"@type\":\"Article\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/#article\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/\"},\"author\":{\"name\":\"bharat\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/5e146ea8682be704a2553a73c97c786b\"},\"headline\":\"Using GraphQL to Create Blogs with Image Uploads in MongoDB\",\"datePublished\":\"2025-01-21T04:00:51+00:00\",\"dateModified\":\"2025-01-21T04:07:54+00:00\",\"mainEntityOfPage\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/\"},\"wordCount\":483,\"commentCount\":0,\"publisher\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#organization\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"CommentAction\",\"name\":\"Comment\",\"target\":[\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/#respond\"]}]},{\"@type\":\"WebPage\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/\",\"name\":\"Pheonix Solutions - We Empower Your Business Growth\",\"isPartOf\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#website\"},\"datePublished\":\"2025-01-21T04:00:51+00:00\",\"dateModified\":\"2025-01-21T04:07:54+00:00\",\"breadcrumb\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/#breadcrumb\"},\"inLanguage\":\"en-US\",\"potentialAction\":[{\"@type\":\"ReadAction\",\"target\":[\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/\"]}]},{\"@type\":\"BreadcrumbList\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\\\/#breadcrumb\",\"itemListElement\":[{\"@type\":\"ListItem\",\"position\":1,\"name\":\"Home\",\"item\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/\"},{\"@type\":\"ListItem\",\"position\":2,\"name\":\"Using GraphQL to Create Blogs with Image Uploads in MongoDB\"}]},{\"@type\":\"WebSite\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#website\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/\",\"name\":\"Pheonix Solutions\",\"description\":\"We Empower Your Business Growth\",\"publisher\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#organization\"},\"potentialAction\":[{\"@type\":\"SearchAction\",\"target\":{\"@type\":\"EntryPoint\",\"urlTemplate\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/?s={search_term_string}\"},\"query-input\":{\"@type\":\"PropertyValueSpecification\",\"valueRequired\":true,\"valueName\":\"search_term_string\"}}],\"inLanguage\":\"en-US\"},{\"@type\":\"Organization\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#organization\",\"name\":\"PheonixSolutions\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/\",\"logo\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\",\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/12\\\/logo.png\",\"contentUrl\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/wp-content\\\/uploads\\\/2016\\\/12\\\/logo.png\",\"width\":454,\"height\":300,\"caption\":\"PheonixSolutions\"},\"image\":{\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/logo\\\/image\\\/\"},\"sameAs\":[\"https:\\\/\\\/www.facebook.com\\\/PheonixSolutions-209942982759387\\\/\",\"https:\\\/\\\/x.com\\\/pheonixsolution\"]},{\"@type\":\"Person\",\"@id\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/#\\\/schema\\\/person\\\/5e146ea8682be704a2553a73c97c786b\",\"name\":\"bharat\",\"image\":{\"@type\":\"ImageObject\",\"inLanguage\":\"en-US\",\"@id\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/d82d0f7350e396f4195f9cbac82c8173f0a2abae54e34fe15122bf92b23dca79?s=96&r=g\",\"url\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/d82d0f7350e396f4195f9cbac82c8173f0a2abae54e34fe15122bf92b23dca79?s=96&r=g\",\"contentUrl\":\"https:\\\/\\\/secure.gravatar.com\\\/avatar\\\/d82d0f7350e396f4195f9cbac82c8173f0a2abae54e34fe15122bf92b23dca79?s=96&r=g\",\"caption\":\"bharat\"},\"url\":\"https:\\\/\\\/pheonixsolutions.com\\\/blog\\\/author\\\/bharat\\\/\"}]}<\/script>\n<!-- \/ Yoast SEO plugin. -->","yoast_head_json":{"title":"Pheonix Solutions - We Empower Your Business Growth","robots":{"index":"index","follow":"follow","max-snippet":"max-snippet:-1","max-image-preview":"max-image-preview:large","max-video-preview":"max-video-preview:-1"},"canonical":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/","og_locale":"en_US","og_type":"article","og_title":"Pheonix Solutions - We Empower Your Business Growth","og_description":"Using GraphQL to Create Blogs with Image Uploads in MongoDB To implement blog creation with image uploads, we\u2019ll use Apollo Server for GraphQL, MongoDB for data storage, and GridFS for handling binary file storage. Follow the steps below for seamless integration. Prerequisites Install the required dependencies using Yarn: yarn add&hellip; Continue Reading Using GraphQL to Create Blogs with Image Uploads in MongoDB","og_url":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/","og_site_name":"PHEONIXSOLUTIONS","article_publisher":"https:\/\/www.facebook.com\/PheonixSolutions-209942982759387\/","article_published_time":"2025-01-21T04:00:51+00:00","article_modified_time":"2025-01-21T04:07:54+00:00","og_image":[{"width":3837,"height":2540,"url":"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/09\/PX2.png","type":"image\/png"}],"author":"bharat","twitter_card":"summary_large_image","twitter_creator":"@pheonixsolution","twitter_site":"@pheonixsolution","twitter_misc":{"Written by":"bharat","Est. reading time":"2 minutes"},"schema":{"@context":"https:\/\/schema.org","@graph":[{"@type":"Article","@id":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/#article","isPartOf":{"@id":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/"},"author":{"name":"bharat","@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/person\/5e146ea8682be704a2553a73c97c786b"},"headline":"Using GraphQL to Create Blogs with Image Uploads in MongoDB","datePublished":"2025-01-21T04:00:51+00:00","dateModified":"2025-01-21T04:07:54+00:00","mainEntityOfPage":{"@id":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/"},"wordCount":483,"commentCount":0,"publisher":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#organization"},"inLanguage":"en-US","potentialAction":[{"@type":"CommentAction","name":"Comment","target":["https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/#respond"]}]},{"@type":"WebPage","@id":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/","url":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/","name":"Pheonix Solutions - We Empower Your Business Growth","isPartOf":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#website"},"datePublished":"2025-01-21T04:00:51+00:00","dateModified":"2025-01-21T04:07:54+00:00","breadcrumb":{"@id":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/#breadcrumb"},"inLanguage":"en-US","potentialAction":[{"@type":"ReadAction","target":["https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/"]}]},{"@type":"BreadcrumbList","@id":"https:\/\/pheonixsolutions.com\/blog\/using-graphql-to-create-blogs-with-image-uploads-in-mongodb\/#breadcrumb","itemListElement":[{"@type":"ListItem","position":1,"name":"Home","item":"https:\/\/pheonixsolutions.com\/blog\/"},{"@type":"ListItem","position":2,"name":"Using GraphQL to Create Blogs with Image Uploads in MongoDB"}]},{"@type":"WebSite","@id":"https:\/\/pheonixsolutions.com\/blog\/#website","url":"https:\/\/pheonixsolutions.com\/blog\/","name":"Pheonix Solutions","description":"We Empower Your Business Growth","publisher":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#organization"},"potentialAction":[{"@type":"SearchAction","target":{"@type":"EntryPoint","urlTemplate":"https:\/\/pheonixsolutions.com\/blog\/?s={search_term_string}"},"query-input":{"@type":"PropertyValueSpecification","valueRequired":true,"valueName":"search_term_string"}}],"inLanguage":"en-US"},{"@type":"Organization","@id":"https:\/\/pheonixsolutions.com\/blog\/#organization","name":"PheonixSolutions","url":"https:\/\/pheonixsolutions.com\/blog\/","logo":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/logo\/image\/","url":"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/12\/logo.png","contentUrl":"https:\/\/pheonixsolutions.com\/blog\/wp-content\/uploads\/2016\/12\/logo.png","width":454,"height":300,"caption":"PheonixSolutions"},"image":{"@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/logo\/image\/"},"sameAs":["https:\/\/www.facebook.com\/PheonixSolutions-209942982759387\/","https:\/\/x.com\/pheonixsolution"]},{"@type":"Person","@id":"https:\/\/pheonixsolutions.com\/blog\/#\/schema\/person\/5e146ea8682be704a2553a73c97c786b","name":"bharat","image":{"@type":"ImageObject","inLanguage":"en-US","@id":"https:\/\/secure.gravatar.com\/avatar\/d82d0f7350e396f4195f9cbac82c8173f0a2abae54e34fe15122bf92b23dca79?s=96&r=g","url":"https:\/\/secure.gravatar.com\/avatar\/d82d0f7350e396f4195f9cbac82c8173f0a2abae54e34fe15122bf92b23dca79?s=96&r=g","contentUrl":"https:\/\/secure.gravatar.com\/avatar\/d82d0f7350e396f4195f9cbac82c8173f0a2abae54e34fe15122bf92b23dca79?s=96&r=g","caption":"bharat"},"url":"https:\/\/pheonixsolutions.com\/blog\/author\/bharat\/"}]}},"jetpack_featured_media_url":"","jetpack_shortlink":"https:\/\/wp.me\/p7F4uM-2di","jetpack_sharing_enabled":true,"_links":{"self":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/8512","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/users\/507"}],"replies":[{"embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/comments?post=8512"}],"version-history":[{"count":0,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/posts\/8512\/revisions"}],"wp:attachment":[{"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/media?parent=8512"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/categories?post=8512"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/pheonixsolutions.com\/blog\/wp-json\/wp\/v2\/tags?post=8512"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}