Shopify: Image URL upload from Azure server - shopify

We're trying to upload the product images from an external azure-server. The URL looks e.g. like this www.example.com/EfwService_DefaultApp.asmx/DownloadFileExternal?key=SKU&value=E0086&filename=E0086.jpg
But the generated URL fails to upload to shopify. We're not getting a clear error message and till now the support team could not help at all. From the network tab we only see this error message
{
"data":
{
"nodes":
[{
"alt":"",
"mediaContentType":"IMAGE",
"status":"FAILED",
"mediaErrors":
[{
"message":"Medienverarbeitung fehlgeschlagen",
"code":"UNKNOWN",
"__typename":"MediaError"
}]
We don't understand what could be the problem of the URL, as it is public available and a direct link to the image. Did anybody have similar problem or a suggestion?

Related

Integromat - Google Calendar - How to add attachment to event with "Make an API call"

I would like to add attachment to Google calendar event with integromat "Make an API call" module. Attachment uploaded previously to Google drive.
I dont know how to setup the "MAKE an API call" module. See screenshot below.
I tried to understand the integromat help for this, but it was a little bit difficult for me.
If somebody have a scenario for this please help me.
Thanks for any help!
I am pretty sure that Google Calendar API doesn't support external files as part of the attachment, I might be wrong though. The current working scenario, that I shared will be able to add a Google Drive File as part of the attachment. Please refer the screenshot,
You will need to use following,
URL: /v3/calendars/{{CALENDAR_ID}}/events/{{EVENT_ID}}?supportsAttachments=true
Method: PATCH
Body :
{
"attachments": [{
"fileId" : "",
"fileUrl": "https://drive.google.com/file/d/1yyVVQxgwb7wF6RckN_1KoGtSmikjk2MR/view?usp=sharing",
"mimeType": "image/png",
"title": "TestImage.png"
}]
}
You can refer the document here : https://developers.google.com/calendar/api/v3/reference/events/patch

How to save url and use out of chrome api in Vue.js for chrome extension?

I am currently facing a weird issue with developing a simple chrome extension.
Basically, I want to build an extension that saves the currently focused URL. However, seems like URL is not saved in variables that I defined.
I have tried to use an array to store it, and also a variable.
consoleClick() {
var urlss = []
var getTab = function(tab){
urlss.push(tab)
alert(tab)
};
chrome.tabs.query({'active':true}, function(tabs){
getTab(tabs[0].url)
});
console.log(urlss)
this.$store.commit('addUrl',urlss[0])
console.log(this.$store.state.urls[0])
}
Here, once button is clicked, with "chrome.tabs.query()" I was able to get currently focused url. and I saved it to "urlss", and checked it with console.log(urlss).
I could see the url in console log, however, when I tried to access to url with urlss[0], it says urlss[0] is "undefined" even though I can see that
[]
0: "https://stackoverflow.com/posts/57089954/edit"
length: 1
__proto__: Array(0)
in log. This leads to push "undefined" to my vuex storage.
I also tried to push it to vuex storage right away in chrome.tabs.query(), however it gives me that $store is not defined.
I know that my explanation is pretty messy but I need help from the community! Thanks in advance

Unable to add image to Outlook Online

I want to add an image to my mail body by Office.js but this is not working for Outlook Online.
I don't want my picture to be accessible for everyone so this is what I do (this works for Outlook Desktop):
Add an attachment by url
Office.context.mailbox.item.addFileAttachmentAsync(url, name,
{ isInline: true },
function (asyncResult) {
...
});
Add image to body
Office.context.mailbox.item.body.setSelectedDataAsync('<img src="cid:' + name + '">',
{ coercionType: Office.CoercionType.Html },
function (asyncResult) {
});
After the file is attached we remove the image so it isn't available anymore at the url.
How do I get adding file attachments to work for Outlook Online?
As I understood your issue, the recipients, as well as yourself is not able to see the photo that you've embedded on a email. Am I correct? The following are the possible reasons affecting the issue:
Possible that the file size of the picture maybe too large
A possible issue on recipients's end (browser issue)
Slow nternet connection
For more information, please refer to the link below:Unable to insert a photo in Outlook.com
Hopefully it helps you!

Is it possible to create a project documentset using graph API?

So far I haven't been able to find any information on how to create project documentsets on my Sharepoint environment using the Graph API. I've tried both Sharepoint's 'Create item' and OneDrive's 'Create Folder'. The Sharepoint API says:
"Files and folders should only be added to a DocumentLibrary via the OneDrive API"
The OneDrive API says:
"Either 'folder' or 'file' must be provided, but not both."
As you can tell from the responses, it seems limited to only having the options to create either a folder or a file. Is this correct? Is there any way to mutate a folder to a document set using a different API call?
I have tried to add the content type ID to the different request bodies, in every case providing no further solution.
Hope someone here knows a possible solution and can help me. Thanks!
I've dealt with the same issue today. I needed to create a Document Set in the root level of a Document Library after some business logic.
Here's how I've achieved to do so:
1- Get the document library's Drive Id:
GET https://graph.microsoft.com/v1.0/sites/${siteId}/lists/${listId}?$expand=drive
2- Create the folder:
POST https://graph.microsoft.com/v1.0/drives/${library.drive.id}/root/children
Remember to set the body as:
{
"name": ${nameOfTheFolder},
"folder": {},
}
3- Get the folder's SharePoint item id:
GET https://graph.microsoft.com/v1.0/sites/${siteId}/drives/${library.drive.id}/items/${folder.id}?expand=sharepointids
4- Update the item in the Document Library so that it updates to the desired Document Set:
PATCH https://graph.microsoft.com/v1.0/sites/${siteId}/lists/${listId}/items/${sharepointIds.listItemId}
Don't forget to set the body to:
{
"contentType": {
"id": "content-type-id-of-the-document-set"
},
"fields": {
//whatever fields you want to set
}
}
Hope it helps
I have been looking into this myself aswell and walked into the same wall.
At the moment, unfortunately, there is no combined method.
You can use them both to combine it to your own documentset.
Kind regards,
R Schouten

Load Dojo class from string content instead of file

For a very special situation I want to store Dojo classes (i.e. the sources) that I load from remote in the localStorage to have access to them in offline situations (we are talking about a hybrid mobile app). I got everything running but dojo.eval won't let me create the class from a string like this
var data = 'define(["dojo/_base/kernel",...'; // class definition as string
dojo.eval(data);
Any idea how to accomplish this?
If you need to have your app run offline, store the resources (css, images, js) in the app manifest. The manifest file looks like the following.
{
"name": "My App",
"description": "My elevator pitch goes here",
"launch_path": "/",
"icons": {
"128": "/img/icon-128.png"
},
"developer": {
"name": "Your name or organization",
"url": "http://your-homepage-here.org"
},
"default_locale": "en"
}
Your app could require hundreds of modules so for performance and manageability of the manifest, you'll want to create a Dojo build which will reduce the number of js files to one or maybe a couple depending on how you create the build.
I finally managed what I was trying to accomplish. However, I found no way to use the localStorage and to load the classes from a string.
The trick is to load the Dojo class source file from remote using XHR, store it using the Cordova File APIs, getting an URL to the stored file and using this URL in the require().
Does what I want and gives me full control over the cached files.