Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Project.PublishPackage() - An error occurred with this API request - Status code BadRequest #86

Open
halilkerimi opened this issue Sep 28, 2020 · 0 comments

Comments

@halilkerimi
Copy link

I am trying to use PublishPackage method and I get BadRequest response
The code I am using:

            try
            {
                var token = await GroupShareClient.GetRequestToken("Username", "Passwrd", new Uri("https://localhost/"), GroupShareClient.AllScopes);

                var groupshareClient = await GroupShareClient.AuthenticateClient(token, "Username", "Passwrd", "", new Uri("https://localhost/"), GroupShareClient.AllScopes);

            

                byte[] data = File.ReadAllBytes(@"D:\Projects\GroupshareAPI\Project 1.sdlppx");

                CreateProjectRequest project = new CreateProjectRequest("API06", "1f5f8f21-95b6-4eff-a1ca-bec52d8c1aa1", "desc", DateTime.Now, "7098bb30-ba69-4da6-bb44-194aafbdae3b", data);
                var res = await groupshareClient.Project.PublishPackage(project);
                Console.ReadLine();
            }
            catch (Exception e)
            {
                Console.WriteLine(e.Message);
            }

Error Message:

{"An error occurred with this API request - Status code BadRequest"}
System.Exception {Sdl.Community.GroupShareKit.Exceptions.ApiException}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant