Cosmic JS Blog Stay tuned for community news, company announcements and updates from the Cosmic JS team.

Creating Extendable Content Objects Served via API

In this blog I will show you how to create an extendable content object in 4 Steps using the Cosmic JS Content Management Platform. Once my object is created, it is available via API endpoint. The following 4 steps are an easy way to create new extendable objects for your web-connected application, so I would encourage you to Sign Up for Cosmic JS and begin the demo. If you're just starting out with Cosmic JS, I'd recommend reviewing the Getting Started and Documentation Pages. I'll be using the Cosmic JS CMS Web Application as I walk through the 4 steps. 

Once you've signed up, you will be prompted to Create a New Bucket, which you can think of as your project: your new website, your new iOS application or your new Android application. I created my bucket and created an Object Type called "Page". Below you can see how I created a page of content that can be delivered via API to any web-connected device. 

1.1 Adding an Object - Object Title

1.2 Adding an Object - Auto-Generated Slug

2. Adding an Object's Content

3. Adding Metafields To Your Object

4. Saving Object Draft | Publishing Object

Cosmic JS is an API-first cloud-based content management platform that makes it easy to manage applications and content. If you have questions about the Cosmic JS API, please reach out to the founders on Twitter or Slack

Read More

You may also like

In this installment of the Cosmic JS Developer Spotlight Series, we sat down with Rick Hanlon, a Front End Engineer  and recent New Yorker that is now residing in London, England working on the front end team at Facebook. Rick is also on the core team of Jest, a JavaScript testing platform. Follow Rick on Twitter or LinkedIn and enjoy the Q/A.

You can now use Cosmic JS to deploy your GitHub private repos to the web.  All you have to do is sign up or sign in using your GitHub account and authorize access to your private repos. (Don't worry, we only access your private repos when you are ready to deploy them to the web).

After you authorize access the process is super easy.  Just go to Your Bucket > Settings > Deploy Web App and choose which private (or public) GitHub repo you would like to deploy. You can also deploy an app from any public Git repo url (make sure your app follows the Heroku deployment guidelines).

Click Deploy Web App and your private repo will be deployed to the world!

We are excited to announce the addition of our GraphQL API to help you get content from your Cosmic JS Buckets faster and more efficiently.  The Cosmic JS community has been very supportive of adding GraphQL as an alternative to our REST API and we are happy to now make this available.

Variety is the spice of life and it is essential to flexible content management.  Currently I'm seeing the trend of data storage move from relational to on-the-fly structures.  Relational databases like MSSQL and MySQL are being less favored and more developers are choosing to move to NoSQL databases like MongoDB.  By more developers I include myself because this is a very flexible and intuitive way to store data.  Key / Value, or as I like to call on-the-fly, content storage is the next stage of content management.  Relational structures bind where on-the-fly sets free.  This is the theory behind Cosmic JS metafields.

Content items are like people in that they come in all shapes, sizes and colors.  Cosmic JS objects allow you to create metafields which give you the power to add on-the-fly key / value pairs.  Create infinite metafields and drag and drop them into parent / child relationships. 

I find it so much easier to keep track of my key / value pairs per object rather than managing a relational schema.  I believe this is the new way of on-the-fly content management that will allow for flexibility and scalability of future content.

In this installment of the Cosmic JS Developer Spotlight Series, we sat down with Brandy Morgan, a JavaScript developer residing in sunny Florida who's currently spearheading her startup CreatorsCode. Brandy is a creative technology influencer, speaker, and consultant with large followings of developer advocates and students alike. Follow Brandy on Instagram, LinkedIn or Twitter, and enjoy the Q/A.

Cosmic JS makes it easy to build slick apps and websites for any vertical or industry.