I am creating keywords using the core service with the below code, the problem is I don't want to use a hardcoded TCM ID for the Category
, as this may change between environments.
Is there any way to avoid this, as it appears you can't get a webdav
path for Categories?
CategoryData category = (CategoryData)_coreService.Read("tcm:344-10060-512", defaultReadOptions);
KeywordData keyword = (KeywordData)_coreService.GetDefaultData(ItemType.Keyword, category.Id);
keyword.Id = "tcm:0-0-0";
keyword.Title = value;
keyword.Key = key;
keyword = (KeywordData)_coreService.Create(keyword, _defaultReadOptions);