dsc/ext/Grani/GraniResource.3.7.8.3/DSCResources/Grani_GitHubApiContent/Grani_GitHubApiContent.schema.mof
[ClassVersion("1.0.0.0"), FriendlyName("cGitHubApiContent")] class Grani_GitHubApiContent : OMI_BaseResource { [Key, Description("File Path to output Donwloaded item.")] String DestinationPath; [Required, Description("GitHub Repository name to access. refer : https://developer.github.com/v3/repos/contents/")] String Repository; [Required, Description("GitHub Repository Owner Name which content owns. refer : https://developer.github.com/v3/repos/contents/")] String RepositoryOwner; [Required, Description("Path to the content. If README.md under root, then just README.md. Make sure path is case-sensitive. refer : https://developer.github.com/v3/repos/contents/")] String ContentPath; [Write, Description("Specify Branch name for the content. Default is master. refer : https://developer.github.com/v3/repos/contents/")] String Branch; [Required, EmbeddedInstance("MSFT_Credential"), Description("OAuth2 access token for GitHub Api Authorization. UserName value will not been in use. refer : https://developer.github.com/v3/#authentication")] String OAuth2Token; [Write, EmbeddedInstance("MSFT_KeyValuePair"), Description("Specify Headers for Web Request. if you need any 'if' or other header control. refer : https://developer.github.com/v3/")] String Header; [Write, Description("Select Media Type to access GitHub API Default is application/json. You need change for each content type. refer : https://developer.github.com/v3/media/"), ValueMap{"application/json","application/vnd.github+json","application/vnd.github.v3.raw","application/vnd.github.v3.html"}, Values{"application/json","application/vnd.github+json","application/vnd.github.v3.raw","application/vnd.github.v3.html"}] String ContentType; [Write, Description("Specify User-Agent for Web Request. Default is powerShell user-agent default. refer : https://developer.github.com/v3/#user-agent-required")] String UserAgent; [Write, Description("Specify if you want to control Redirect. Default is true as Github requires. refer : https://developer.github.com/v3/#http-redirects")] Boolean AllowRedirect; [Write, Description("Specify CacheLocation to hold your last configuration result.")] String CacheLocation; [Read, Description("Describe File is exist on DestinationPath or not."), ValueMap{"Present","Absent"}, Values{"Present","Absent"}] String Ensure; }; |