hey every one!! i am trying to upload SS 2.0 vers...
# suitescript
h
hey every one!! i am trying to upload SS 2.0 version but facing this error while uploading file in file cabinet
Failed to validate script file: Invalid SuiteScript Runtime VersionFailed to validate script file: Invalid SuiteScript Runtime Version
please help to figure out this error i am dealing first time with ssp version 2.0 here is my SS file header
Copy code
/**
 * @NApiVersion 2.0
 *  <http://getCustomer2_0.ss|getCustomer2_0.ss>
 */
define(['N/https','/SuiteScripts/oauth','/SuiteScripts/secret','N/log'],
d
Try
Copy code
*@NApiVersion 2.x
h
okay
name error returns ! can i upload SS 2.x file in SSP1.0 folder ?
d
I would suggest (Or this is how I do it) upload your scripts by means of Customizations -> Scripts
From my knowledge the File Cabinet really doesn’t have a assigned place for 1.0 and 2.0 scripts… they general go into the same area
h
@David Durst there is restriction on file uploading through Customizations -> Scripts we can only upload ".js" files but i want to upload ".ss" file
d
Why do you have the requirement of .ss?
Just seems like a non-required complication… and in the world of SS I would suggest against such complications
k
Your JSDOC does not include the requird @ ScriptType
h
okay i am working on SSP applications. for server request i have to use .SS file please guide me if their is any other method.
k
.ss files would be within hosting files not filecebinet
for SSP application anyway so it is accesibe from a domain.
h
yes i am trying to upload in hosting files and facing this issue ? can you please tell me if we can call restlet through .ss file ?
k
The JSDOC you posted it that from your restlet?
You would want something like
Copy code
/**
 * @NApiVersion 2.x
 * @NScriptType Restlet
 * @NModuleScope SameAccount
 * Date: 31/01/2020
 * Version: 1.0
 */
h
no that was actually .SS file 2.0 ! previously i am working with .ss 1.0 and this is works fine now i want to move on version 2.0 .. i am trying to call restlet thought .ss file in 1.0 i send request through ssp>ss>suitelet>restlet i want to know either if we can call restlet directly through SS file without involving suitelet ?
k
I would have thought that calling a restlet from an SS file would be possible.