dotcms REST API

classic Classic list List threaded Threaded
5 messages Options
Reply | Threaded
Open this post in threaded view
|

dotcms REST API

Henry Versemann

We’re currently using  dotcms version 3.7.1 and we’re trying to automate our campus directory weekly update process, if possible, and I was wondering if the built-in REST API feature could be used to both inquire against and then used to perform needed structure updates to existing data entries, as well as add brand new structure entries?

 

I don’t know much about the REST API, and am still trying to research and better comprehend how it can be used.

 

Thanks for the help.

 

Henry

 

 

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: dotcms REST API

Jason Tesser-2
you can search content and save new content. You would need a little java to alter content types 

On Wed, Aug 30, 2017 at 11:13 AM Henry Versemann <[hidden email]> wrote:

We’re currently using  dotcms version 3.7.1 and we’re trying to automate our campus directory weekly update process, if possible, and I was wondering if the built-in REST API feature could be used to both inquire against and then used to perform needed structure updates to existing data entries, as well as add brand new structure entries?

 

I don’t know much about the REST API, and am still trying to research and better comprehend how it can be used.

 

Thanks for the help.

 

Henry

 

 

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/CALDe1GPXGwgzOy2gkZ6v-5_sJ9yby45NYkgXFxGTuejtE4WpuA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

RE: dotcms REST API

Henry Versemann

So it sounds like adds and updates shouldn’t be a problem then.

What about specifying relationships for adds and updates through the REST API? Possible?

What about deleting entries?

Are they also possible through the REST API?

 

 

From: [hidden email] [mailto:[hidden email]] On Behalf Of Jason Tesser
Sent: Wednesday, August 30, 2017 10:36 AM
To: [hidden email]
Subject: Re: [dotcms] dotcms REST API

 

you can search content and save new content. You would need a little java to alter content types 

 

On Wed, Aug 30, 2017 at 11:13 AM Henry Versemann <[hidden email]> wrote:

We’re currently using  dotcms version 3.7.1 and we’re trying to automate our campus directory weekly update process, if possible, and I was wondering if the built-in REST API feature could be used to both inquire against and then used to perform needed structure updates to existing data entries, as well as add brand new structure entries?

 

I don’t know much about the REST API, and am still trying to research and better comprehend how it can be used.

 

Thanks for the help.

 

Henry

 

 

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/CALDe1GPXGwgzOy2gkZ6v-5_sJ9yby45NYkgXFxGTuejtE4WpuA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/BY2PR0501MB170245923C8E61790A9A71AAAD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

Re: dotcms REST API

John Michael Thomas
Yes, you can apply relationships on each content item that you add or update through the REST API.  You have to specify the name of each relationship to be updated as one of the fields in the POST (see here: https://dotcms.com/docs/latest/save-content-using-rest-api#relationships).

There isn't a direct REST API endpoint to delete content, but you can delete content (or just unpublish or archive it - which is often a better way to remove it from your site) using the workflow REST API.  Basically you use the REST API to trigger a workflow action, so anything you can do in a workflow action you can do via the REST API.  For more information on this see https://dotcms.com/docs/latest/save-content-using-rest-api#workflows and https://dotcms.com/docs/latest/workflows.


On Wednesday, August 30, 2017 at 8:45:52 AM UTC-7, newbie23 wrote:

So it sounds like adds and updates shouldn’t be a problem then.

What about specifying relationships for adds and updates through the REST API? Possible?

What about deleting entries?

Are they also possible through the REST API?

 

 

From: <a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">dot...@... [mailto:<a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">dot...@googlegroups.com] On Behalf Of Jason Tesser
Sent: Wednesday, August 30, 2017 10:36 AM
To: <a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">dot...@...
Subject: Re: [dotcms] dotcms REST API

 

you can search content and save new content. You would need a little java to alter content types 

 

On Wed, Aug 30, 2017 at 11:13 AM Henry Versemann <<a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">hvers...@...> wrote:

We’re currently using  dotcms version 3.7.1 and we’re trying to automate our campus directory weekly update process, if possible, and I was wondering if the built-in REST API feature could be used to both inquire against and then used to perform needed structure updates to existing data entries, as well as add brand new structure entries?

 

I don’t know much about the REST API, and am still trying to research and better comprehend how it can be used.

 

Thanks for the help.

 

Henry

 

 

--
<a href="http://dotcms.com" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fdotcms.com\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGFT4ej1MQxQ2vu3iAUqYQgS59efw&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fdotcms.com\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGFT4ej1MQxQ2vu3iAUqYQgS59efw&#39;;return true;">http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">dotcms+un...@googlegroups.com.
To post to this group, send email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;"> do...@....
To view this discussion on the web visit <a href="https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com?utm_medium=email&amp;utm_source=footer" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;"> https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;"> https://groups.google.com/d/optout.

--
<a href="http://dotcms.com" target="_blank" rel="nofollow" onmousedown="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fdotcms.com\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGFT4ej1MQxQ2vu3iAUqYQgS59efw&#39;;return true;" onclick="this.href=&#39;http://www.google.com/url?q\x3dhttp%3A%2F%2Fdotcms.com\x26sa\x3dD\x26sntz\x3d1\x26usg\x3dAFQjCNGFT4ej1MQxQ2vu3iAUqYQgS59efw&#39;;return true;">http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">dotcms+un...@googlegroups.com.
To post to this group, send email to <a href="javascript:" target="_blank" gdf-obfuscated-mailto="dFdSElBeAAAJ" rel="nofollow" onmousedown="this.href=&#39;javascript:&#39;;return true;" onclick="this.href=&#39;javascript:&#39;;return true;">dot...@....
To view this discussion on the web visit <a href="https://groups.google.com/d/msgid/dotcms/CALDe1GPXGwgzOy2gkZ6v-5_sJ9yby45NYkgXFxGTuejtE4WpuA%40mail.gmail.com?utm_medium=email&amp;utm_source=footer" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/msgid/dotcms/CALDe1GPXGwgzOy2gkZ6v-5_sJ9yby45NYkgXFxGTuejtE4WpuA%40mail.gmail.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/msgid/dotcms/CALDe1GPXGwgzOy2gkZ6v-5_sJ9yby45NYkgXFxGTuejtE4WpuA%40mail.gmail.com?utm_medium\x3demail\x26utm_source\x3dfooter&#39;;return true;"> https://groups.google.com/d/msgid/dotcms/CALDe1GPXGwgzOy2gkZ6v-5_sJ9yby45NYkgXFxGTuejtE4WpuA%40mail.gmail.com.
For more options, visit <a href="https://groups.google.com/d/optout" target="_blank" rel="nofollow" onmousedown="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;" onclick="this.href=&#39;https://groups.google.com/d/optout&#39;;return true;">https://groups.google.com/d/optout.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/ecf93ebe-9614-4eb7-8fa7-50e786cd4d7a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.
Reply | Threaded
Open this post in threaded view
|

RE: dotcms REST API

Henry Versemann

John,

 

I’ve not used the REST API much before so any new information about how to use it is very welcome.

Thanks for the help.

 

Henry

 

From: [hidden email] [mailto:[hidden email]] On Behalf Of John Michael Thomas
Sent: Thursday, August 31, 2017 11:40 AM
To: dotCMS User Group <[hidden email]>
Subject: Re: [dotcms] dotcms REST API

 

Yes, you can apply relationships on each content item that you add or update through the REST API.  You have to specify the name of each relationship to be updated as one of the fields in the POST (see here: https://dotcms.com/docs/latest/save-content-using-rest-api#relationships).

 

There isn't a direct REST API endpoint to delete content, but you can delete content (or just unpublish or archive it - which is often a better way to remove it from your site) using the workflow REST API.  Basically you use the REST API to trigger a workflow action, so anything you can do in a workflow action you can do via the REST API.  For more information on this see https://dotcms.com/docs/latest/save-content-using-rest-api#workflows and https://dotcms.com/docs/latest/workflows.



On Wednesday, August 30, 2017 at 8:45:52 AM UTC-7, newbie23 wrote:

So it sounds like adds and updates shouldn’t be a problem then.

What about specifying relationships for adds and updates through the REST API? Possible?

What about deleting entries?

Are they also possible through the REST API?

 

 

From: <a href="javascript:" target="_blank">dot...@... [mailto:<a href="javascript:" target="_blank">dot...@...] On Behalf Of Jason Tesser
Sent: Wednesday, August 30, 2017 10:36 AM
To: <a href="javascript:" target="_blank">dot...@...
Subject: Re: [dotcms] dotcms REST API

 

you can search content and save new content. You would need a little java to alter content types 

 

On Wed, Aug 30, 2017 at 11:13 AM Henry Versemann <<a href="javascript:" target="_blank">hvers...@...> wrote:

We’re currently using  dotcms version 3.7.1 and we’re trying to automate our campus directory weekly update process, if possible, and I was wondering if the built-in REST API feature could be used to both inquire against and then used to perform needed structure updates to existing data entries, as well as add brand new structure entries?

 

I don’t know much about the REST API, and am still trying to research and better comprehend how it can be used.

 

Thanks for the help.

 

Henry

 

 

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank">dotcms+un...@....
To post to this group, send email to <a href="javascript:" target="_blank">do...@....
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/BY2PR0501MB1702F5E4082AAC2D42AC9A80AD9C0%40BY2PR0501MB1702.namprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to <a href="javascript:" target="_blank">dotcms+un...@....
To post to this group, send email to <a href="javascript:" target="_blank">dot...@....
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/CALDe1GPXGwgzOy2gkZ6v-5_sJ9yby45NYkgXFxGTuejtE4WpuA%40mail.gmail.com.
For more options, visit https://groups.google.com/d/optout.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/ecf93ebe-9614-4eb7-8fa7-50e786cd4d7a%40googlegroups.com.
For more options, visit https://groups.google.com/d/optout.

--
http://dotcms.com - Open Source Java Content Management
---
You received this message because you are subscribed to the Google Groups "dotCMS User Group" group.
To unsubscribe from this group and stop receiving emails from it, send an email to [hidden email].
To post to this group, send email to [hidden email].
To view this discussion on the web visit https://groups.google.com/d/msgid/dotcms/BLUPR0501MB1700D379859C06FFBF00D499AD9D0%40BLUPR0501MB1700.namprd05.prod.outlook.com.
For more options, visit https://groups.google.com/d/optout.