softlayer / softlayer-api-perl-client Goto Github PK
View Code? Open in Web Editor NEWA set of Perl libraries that assist in calling the SoftLayer API.
License: Other
A set of Perl libraries that assist in calling the SoftLayer API.
License: Other
Using the following guest definition and createObject call results in an HTTP 500 Internal Error:
my $client = SoftLayer::API::SOAP->new('SoftLayer_Virtual_Guest', undef, $api_username, $api_key);
my $myGuest = {
hostname => 'sl-test',
domain => 'softlayer.com',
startCpus => 1,
maxMemory => 1024,
hourlyBillingFlag => 1,
localDiskFlag => 1,
operatingSystemReferenceCode => 'CENTOS_6_64',
datacenter => {
name => "SJC01",
}
};
my $orderRet = $client->createObject($myGuest);
I'm trying to verify my CCI order before placing it. If I include primaryBackendNetworkComponent => { networkVlan => { id => 807505 } }
, I receive "Could not verify order. An uncaught exception was generated. Please contact development." If I remove the networkVlan, the order verification goes through fine.
Here's the object I'm handing to generateOrderTemplate:
$VAR1 = bless( {
'datacenter' => {
'name' => 'sea01'
},
'operatingSystemReferenceCode' => 'CENTOS_LATEST',
'hourlyBillingFlag' => 1,
'startCpus' => 1,
'localDiskFlag' => 1,
'hostname' => 'sea-tst-vlan-01a',
'maxMemory' => 1024,
'domain' => 'test.local',
'primaryBackendNetworkComponent' => {
'networkVlan' => {
'id' => 807505
}
}
}, 'slapi:SoftLayer_Virtual_Guest' );
I first raised this as a support ticket in the portal and received the following reply:
This is an specific issue with the Perl Client it is not handle properly the primaryBackendNetworkComponent" field when the field is specified the request fails, only the developers in charge of the client can fix this issue please report the issue here: >https://github.com/softlayer/softlayer-api-perl-client/issues
Meanwhile I can suggest you to use the Softlayer_Virtual_Guest:createObject method in order to create the new VSI.
Hi,
I am trying to do an advanced filter to search some tags, but I was not able to make my filter to work, I have this filter in python and I am trying to do the same filter in Perl:
objectFilter= {'virtualGuests':{'tagReferences':{'tag':{'name':{'operation':'in','options':[{'name': 'data','value': tags}]}}}}}
I am only was able to do simple filters in perl, is it possible to do the advanced filter? do you have any example?
The "SoftLayer_Billing_Order_Quote::getRecalculatedOrderContainer" method fails and raises the following exception when is used with the perl client
"SOAP-ENV:Client , Missing parameter"
Please try the following code:
use SoftLayer::API::SOAP;
use strict;
use Data::Dumper;
my $apiUsername = 'set-me';
my $apiKey = 'set-me';
my $quoteId = 123456;
my $client = SoftLayer::API::SOAP->new('SoftLayer_Billing_Order_Quote', $quoteId, $apiUsername, $apiKey);
my $order_templates = $client->getRecalculatedOrderContainer();
if ($order_templates->fault) {
die "Unable to retrieve quotes. " . $order_templates->faultcode . " , " .$order_templates->faultstring;
}
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.