question

HarikrishnanP-2692 avatar image
0 Votes"
HarikrishnanP-2692 asked AllenXu-MSFT commented

Content Type synchronization and site script issue while adding content type to list

Hi,

In our current setup site provisioning is done using flow, site design, and azure runbooks. Since our site uses different custom content types we have added 1-hour delay in the flow to sync the content types to the newly created site. After that using site design, different lists will be created and respective content types will be added to the list.

Due to the changes happening in content type synchronization logic we are redesigning the current system. So just after creating the site, I used the command Add-PnPContentTypesFromContentTypeHub to sync the content types to the new site. Even though it's throwing an error the content types are getting synced. however, the issue is the site design scripts are not able to add the content types to the list, it's just creating the list. Since the site design option is replaced by site template , I'm not able to see the log of applying site design.

Does anybody face this issue?

I also read that,

A new verb is also being developed (addContentTypesFromHub) for use within SharePoint site script actions. This is expected to be available by the end of 2021.

https://support.microsoft.com/en-us/office/what-s-changed-in-content-type-publishing-609399c7-5c42-4e25-aff0-b59d4aa1867f

Do I need to wait to get addContentTypesFromHub action to successfully implement the system I described in this post?


office-sharepoint-online
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

HarikrishnanP-2692 avatar image
0 Votes"
HarikrishnanP-2692 answered AllenXu-MSFT commented

@AllenXu-MSFT Sorry for the late response. So if I want to add the content type using site design I need to use the new verb 'Add-PnPContentTypesFromContentTypeHub' right?

In the latest update from Microsoft (MC295852), I read that automatic content type synchronization will be stopped by end of January.

Blockquote any scripts that add a published content type in a site for the first time need to use one of these methods. Any solutions that depend on waiting for a published content type to get copied to all sites won’t work going forward.
Blockquote

So this verb 'Add-PnPContentTypesFromContentTypeHub' is the only way to add content type in the site and this verb is not released yet, so if the auto-syncing is stopped it will break my site provisioning.

· 1
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@HarikrishnanP-2692 ,

As per my knowledgem, I‘m afraid yes, currently this is the only way. You can new a service request in Microsoft 365 admin center to confirm it with Micorosft experts.

0 Votes 0 ·
AllenXu-MSFT avatar image
0 Votes"
AllenXu-MSFT answered AllenXu-MSFT commented

Hi @HarikrishnanP-2692 ,

Yes due to the changes in content type publishing, I think in your case the only way is to wait for the new verb that is being developed for use to update the site design scripts so that you can implement the sysytem then.


If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

· 2
5 |1600 characters needed characters left characters exceeded

Up to 10 attachments (including images) can be used with a maximum of 3.0 MiB each and 30.0 MiB total.

@HarikrishnanP-2692 ,

Just cheking how things are going on this thrad, is there any progress?

0 Votes 0 ·

@HarikrishnanP-2692 ,

Feel free to reply if you still need any help.


If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".
Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread.

0 Votes 0 ·