restapi.Object
Explore with Pulumi AI
Acting as a wrapper of cURL, this object supports POST, GET, PUT and DELETE on the specified url
Example Usage
import * as pulumi from "@pulumi/pulumi";
import * as restapi from "@pulumi/restapi";
const foo2 = new restapi.Object("foo2", {
path: "/api/objects",
data: "{ \"id\": \"55555\", \"first\": \"Foo\", \"last\": \"Bar\" }",
}, {
provider: restapi.restapi_headers,
});
import pulumi
import pulumi_restapi as restapi
foo2 = restapi.Object("foo2",
path="/api/objects",
data="{ \"id\": \"55555\", \"first\": \"Foo\", \"last\": \"Bar\" }",
opts = pulumi.ResourceOptions(provider=restapi["restapi_headers"]))
package main
import (
"github.com/pulumi/pulumi-terraform-provider/sdks/go/restapi/v2/restapi"
"github.com/pulumi/pulumi/sdk/v3/go/pulumi"
)
func main() {
pulumi.Run(func(ctx *pulumi.Context) error {
_, err := restapi.NewObject(ctx, "foo2", &restapi.ObjectArgs{
Path: pulumi.String("/api/objects"),
Data: pulumi.String("{ \"id\": \"55555\", \"first\": \"Foo\", \"last\": \"Bar\" }"),
}, pulumi.Provider(restapi.Restapi_headers))
if err != nil {
return err
}
return nil
})
}
using System.Collections.Generic;
using System.Linq;
using Pulumi;
using Restapi = Pulumi.Restapi;
return await Deployment.RunAsync(() =>
{
var foo2 = new Restapi.Object("foo2", new()
{
Path = "/api/objects",
Data = "{ \"id\": \"55555\", \"first\": \"Foo\", \"last\": \"Bar\" }",
}, new CustomResourceOptions
{
Provider = restapi.Restapi_headers,
});
});
package generated_program;
import com.pulumi.Context;
import com.pulumi.Pulumi;
import com.pulumi.core.Output;
import com.pulumi.restapi.Object;
import com.pulumi.restapi.ObjectArgs;
import com.pulumi.resources.CustomResourceOptions;
import java.util.List;
import java.util.ArrayList;
import java.util.Map;
import java.io.File;
import java.nio.file.Files;
import java.nio.file.Paths;
public class App {
public static void main(String[] args) {
Pulumi.run(App::stack);
}
public static void stack(Context ctx) {
var foo2 = new Object("foo2", ObjectArgs.builder()
.path("/api/objects")
.data("{ \"id\": \"55555\", \"first\": \"Foo\", \"last\": \"Bar\" }")
.build(), CustomResourceOptions.builder()
.provider(restapi.restapi_headers())
.build());
}
}
resources:
foo2:
type: restapi:Object
properties:
path: /api/objects
data: '{ "id": "55555", "first": "Foo", "last": "Bar" }'
options:
provider: ${restapi.restapi_headers}
Create Object Resource
Resources are created with functions called constructors. To learn more about declaring and configuring resources, see Resources.
Constructor syntax
new Object(name: string, args: ObjectArgs, opts?: CustomResourceOptions);
@overload
def Object(resource_name: str,
args: ObjectArgs,
opts: Optional[ResourceOptions] = None)
@overload
def Object(resource_name: str,
opts: Optional[ResourceOptions] = None,
data: Optional[str] = None,
path: Optional[str] = None,
ignore_changes_tos: Optional[Sequence[str]] = None,
object_id: Optional[str] = None,
destroy_data: Optional[str] = None,
destroy_method: Optional[str] = None,
destroy_path: Optional[str] = None,
force_news: Optional[Sequence[str]] = None,
id_attribute: Optional[str] = None,
ignore_all_server_changes: Optional[bool] = None,
create_method: Optional[str] = None,
debug: Optional[bool] = None,
create_path: Optional[str] = None,
query_string: Optional[str] = None,
read_data: Optional[str] = None,
read_method: Optional[str] = None,
read_path: Optional[str] = None,
read_search: Optional[Mapping[str, str]] = None,
restapi_object_id: Optional[str] = None,
update_data: Optional[str] = None,
update_method: Optional[str] = None,
update_path: Optional[str] = None)
func NewObject(ctx *Context, name string, args ObjectArgs, opts ...ResourceOption) (*Object, error)
public Object(string name, ObjectArgs args, CustomResourceOptions? opts = null)
public Object(String name, ObjectArgs args)
public Object(String name, ObjectArgs args, CustomResourceOptions options)
type: restapi:Object
properties: # The arguments to resource properties.
options: # Bag of options to control resource's behavior.
Parameters
- name string
- The unique name of the resource.
- args ObjectArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- resource_name str
- The unique name of the resource.
- args ObjectArgs
- The arguments to resource properties.
- opts ResourceOptions
- Bag of options to control resource's behavior.
- ctx Context
- Context object for the current deployment.
- name string
- The unique name of the resource.
- args ObjectArgs
- The arguments to resource properties.
- opts ResourceOption
- Bag of options to control resource's behavior.
- name string
- The unique name of the resource.
- args ObjectArgs
- The arguments to resource properties.
- opts CustomResourceOptions
- Bag of options to control resource's behavior.
- name String
- The unique name of the resource.
- args ObjectArgs
- The arguments to resource properties.
- options CustomResourceOptions
- Bag of options to control resource's behavior.
Constructor example
The following reference example uses placeholder values for all input properties.
var objectResource = new Restapi.Object("objectResource", new()
{
Data = "string",
Path = "string",
IgnoreChangesTos = new[]
{
"string",
},
ObjectId = "string",
DestroyData = "string",
DestroyMethod = "string",
DestroyPath = "string",
ForceNews = new[]
{
"string",
},
IdAttribute = "string",
IgnoreAllServerChanges = false,
CreateMethod = "string",
Debug = false,
CreatePath = "string",
QueryString = "string",
ReadData = "string",
ReadMethod = "string",
ReadPath = "string",
ReadSearch =
{
{ "string", "string" },
},
RestapiObjectId = "string",
UpdateData = "string",
UpdateMethod = "string",
UpdatePath = "string",
});
example, err := restapi.NewObject(ctx, "objectResource", &restapi.ObjectArgs{
Data: pulumi.String("string"),
Path: pulumi.String("string"),
IgnoreChangesTos: pulumi.StringArray{
pulumi.String("string"),
},
ObjectId: pulumi.String("string"),
DestroyData: pulumi.String("string"),
DestroyMethod: pulumi.String("string"),
DestroyPath: pulumi.String("string"),
ForceNews: pulumi.StringArray{
pulumi.String("string"),
},
IdAttribute: pulumi.String("string"),
IgnoreAllServerChanges: pulumi.Bool(false),
CreateMethod: pulumi.String("string"),
Debug: pulumi.Bool(false),
CreatePath: pulumi.String("string"),
QueryString: pulumi.String("string"),
ReadData: pulumi.String("string"),
ReadMethod: pulumi.String("string"),
ReadPath: pulumi.String("string"),
ReadSearch: pulumi.StringMap{
"string": pulumi.String("string"),
},
RestapiObjectId: pulumi.String("string"),
UpdateData: pulumi.String("string"),
UpdateMethod: pulumi.String("string"),
UpdatePath: pulumi.String("string"),
})
var objectResource = new Object("objectResource", ObjectArgs.builder()
.data("string")
.path("string")
.ignoreChangesTos("string")
.objectId("string")
.destroyData("string")
.destroyMethod("string")
.destroyPath("string")
.forceNews("string")
.idAttribute("string")
.ignoreAllServerChanges(false)
.createMethod("string")
.debug(false)
.createPath("string")
.queryString("string")
.readData("string")
.readMethod("string")
.readPath("string")
.readSearch(Map.of("string", "string"))
.restapiObjectId("string")
.updateData("string")
.updateMethod("string")
.updatePath("string")
.build());
object_resource = restapi.Object("objectResource",
data="string",
path="string",
ignore_changes_tos=["string"],
object_id="string",
destroy_data="string",
destroy_method="string",
destroy_path="string",
force_news=["string"],
id_attribute="string",
ignore_all_server_changes=False,
create_method="string",
debug=False,
create_path="string",
query_string="string",
read_data="string",
read_method="string",
read_path="string",
read_search={
"string": "string",
},
restapi_object_id="string",
update_data="string",
update_method="string",
update_path="string")
const objectResource = new restapi.Object("objectResource", {
data: "string",
path: "string",
ignoreChangesTos: ["string"],
objectId: "string",
destroyData: "string",
destroyMethod: "string",
destroyPath: "string",
forceNews: ["string"],
idAttribute: "string",
ignoreAllServerChanges: false,
createMethod: "string",
debug: false,
createPath: "string",
queryString: "string",
readData: "string",
readMethod: "string",
readPath: "string",
readSearch: {
string: "string",
},
restapiObjectId: "string",
updateData: "string",
updateMethod: "string",
updatePath: "string",
});
type: restapi:Object
properties:
createMethod: string
createPath: string
data: string
debug: false
destroyData: string
destroyMethod: string
destroyPath: string
forceNews:
- string
idAttribute: string
ignoreAllServerChanges: false
ignoreChangesTos:
- string
objectId: string
path: string
queryString: string
readData: string
readMethod: string
readPath: string
readSearch:
string: string
restapiObjectId: string
updateData: string
updateMethod: string
updatePath: string
Object Resource Properties
To learn more about resource properties and how to use them, see Inputs and Outputs in the Architecture and Concepts docs.
Inputs
In Python, inputs that are objects can be passed either as argument classes or as dictionary literals.
The Object resource accepts the following input properties:
- Data string
- Valid JSON object that this provider will manage with the API server.
- Path string
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- Create
Method string - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - Create
Path string - Debug bool
- Whether to emit verbose debug output while working with the API object on the server.
- Destroy
Data string - Valid JSON object to pass during to destroy requests.
- Destroy
Method string - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - Destroy
Path string - Force
News List<string> - Any changes to these values will result in recreating the resource instead of updating.
- Id
Attribute string - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - Ignore
All boolServer Changes - Ignore
Changes List<string>Tos - Object
Id string - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - Query
String string - Query string to be included in the path
- Read
Data string - Valid JSON object to pass during read requests.
- Read
Method string - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - Read
Path string - Read
Search Dictionary<string, string> - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - Restapi
Object stringId - The ID of this resource.
- Update
Data string - Valid JSON object to pass during to update requests.
- Update
Method string - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - Update
Path string
- Data string
- Valid JSON object that this provider will manage with the API server.
- Path string
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- Create
Method string - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - Create
Path string - Debug bool
- Whether to emit verbose debug output while working with the API object on the server.
- Destroy
Data string - Valid JSON object to pass during to destroy requests.
- Destroy
Method string - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - Destroy
Path string - Force
News []string - Any changes to these values will result in recreating the resource instead of updating.
- Id
Attribute string - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - Ignore
All boolServer Changes - Ignore
Changes []stringTos - Object
Id string - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - Query
String string - Query string to be included in the path
- Read
Data string - Valid JSON object to pass during read requests.
- Read
Method string - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - Read
Path string - Read
Search map[string]string - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - Restapi
Object stringId - The ID of this resource.
- Update
Data string - Valid JSON object to pass during to update requests.
- Update
Method string - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - Update
Path string
- data String
- Valid JSON object that this provider will manage with the API server.
- path String
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- create
Method String - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create
Path String - debug Boolean
- Whether to emit verbose debug output while working with the API object on the server.
- destroy
Data String - Valid JSON object to pass during to destroy requests.
- destroy
Method String - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy
Path String - force
News List<String> - Any changes to these values will result in recreating the resource instead of updating.
- id
Attribute String - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore
All BooleanServer Changes - ignore
Changes List<String>Tos - object
Id String - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - query
String String - Query string to be included in the path
- read
Data String - Valid JSON object to pass during read requests.
- read
Method String - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read
Path String - read
Search Map<String,String> - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi
Object StringId - The ID of this resource.
- update
Data String - Valid JSON object to pass during to update requests.
- update
Method String - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update
Path String
- data string
- Valid JSON object that this provider will manage with the API server.
- path string
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- create
Method string - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create
Path string - debug boolean
- Whether to emit verbose debug output while working with the API object on the server.
- destroy
Data string - Valid JSON object to pass during to destroy requests.
- destroy
Method string - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy
Path string - force
News string[] - Any changes to these values will result in recreating the resource instead of updating.
- id
Attribute string - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore
All booleanServer Changes - ignore
Changes string[]Tos - object
Id string - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - query
String string - Query string to be included in the path
- read
Data string - Valid JSON object to pass during read requests.
- read
Method string - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read
Path string - read
Search {[key: string]: string} - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi
Object stringId - The ID of this resource.
- update
Data string - Valid JSON object to pass during to update requests.
- update
Method string - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update
Path string
- data str
- Valid JSON object that this provider will manage with the API server.
- path str
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- create_
method str - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create_
path str - debug bool
- Whether to emit verbose debug output while working with the API object on the server.
- destroy_
data str - Valid JSON object to pass during to destroy requests.
- destroy_
method str - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy_
path str - force_
news Sequence[str] - Any changes to these values will result in recreating the resource instead of updating.
- id_
attribute str - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore_
all_ boolserver_ changes - ignore_
changes_ Sequence[str]tos - object_
id str - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - query_
string str - Query string to be included in the path
- read_
data str - Valid JSON object to pass during read requests.
- read_
method str - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read_
path str - read_
search Mapping[str, str] - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi_
object_ strid - The ID of this resource.
- update_
data str - Valid JSON object to pass during to update requests.
- update_
method str - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update_
path str
- data String
- Valid JSON object that this provider will manage with the API server.
- path String
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- create
Method String - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create
Path String - debug Boolean
- Whether to emit verbose debug output while working with the API object on the server.
- destroy
Data String - Valid JSON object to pass during to destroy requests.
- destroy
Method String - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy
Path String - force
News List<String> - Any changes to these values will result in recreating the resource instead of updating.
- id
Attribute String - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore
All BooleanServer Changes - ignore
Changes List<String>Tos - object
Id String - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - query
String String - Query string to be included in the path
- read
Data String - Valid JSON object to pass during read requests.
- read
Method String - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read
Path String - read
Search Map<String> - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi
Object StringId - The ID of this resource.
- update
Data String - Valid JSON object to pass during to update requests.
- update
Method String - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update
Path String
Outputs
All input properties are implicitly available as output properties. Additionally, the Object resource produces the following output properties:
- Api
Data Dictionary<string, string> - Api
Response string - The raw body of the HTTP response from the last read of the object.
- Create
Response string - The raw body of the HTTP response returned when creating the object.
- Id string
- The provider-assigned unique ID for this managed resource.
- Api
Data map[string]string - Api
Response string - The raw body of the HTTP response from the last read of the object.
- Create
Response string - The raw body of the HTTP response returned when creating the object.
- Id string
- The provider-assigned unique ID for this managed resource.
- api
Data Map<String,String> - api
Response String - The raw body of the HTTP response from the last read of the object.
- create
Response String - The raw body of the HTTP response returned when creating the object.
- id String
- The provider-assigned unique ID for this managed resource.
- api
Data {[key: string]: string} - api
Response string - The raw body of the HTTP response from the last read of the object.
- create
Response string - The raw body of the HTTP response returned when creating the object.
- id string
- The provider-assigned unique ID for this managed resource.
- api_
data Mapping[str, str] - api_
response str - The raw body of the HTTP response from the last read of the object.
- create_
response str - The raw body of the HTTP response returned when creating the object.
- id str
- The provider-assigned unique ID for this managed resource.
- api
Data Map<String> - api
Response String - The raw body of the HTTP response from the last read of the object.
- create
Response String - The raw body of the HTTP response returned when creating the object.
- id String
- The provider-assigned unique ID for this managed resource.
Look up Existing Object Resource
Get an existing Object resource’s state with the given name, ID, and optional extra properties used to qualify the lookup.
public static get(name: string, id: Input<ID>, state?: ObjectState, opts?: CustomResourceOptions): Object
@staticmethod
def get(resource_name: str,
id: str,
opts: Optional[ResourceOptions] = None,
api_data: Optional[Mapping[str, str]] = None,
api_response: Optional[str] = None,
create_method: Optional[str] = None,
create_path: Optional[str] = None,
create_response: Optional[str] = None,
data: Optional[str] = None,
debug: Optional[bool] = None,
destroy_data: Optional[str] = None,
destroy_method: Optional[str] = None,
destroy_path: Optional[str] = None,
force_news: Optional[Sequence[str]] = None,
id_attribute: Optional[str] = None,
ignore_all_server_changes: Optional[bool] = None,
ignore_changes_tos: Optional[Sequence[str]] = None,
object_id: Optional[str] = None,
path: Optional[str] = None,
query_string: Optional[str] = None,
read_data: Optional[str] = None,
read_method: Optional[str] = None,
read_path: Optional[str] = None,
read_search: Optional[Mapping[str, str]] = None,
restapi_object_id: Optional[str] = None,
update_data: Optional[str] = None,
update_method: Optional[str] = None,
update_path: Optional[str] = None) -> Object
func GetObject(ctx *Context, name string, id IDInput, state *ObjectState, opts ...ResourceOption) (*Object, error)
public static Object Get(string name, Input<string> id, ObjectState? state, CustomResourceOptions? opts = null)
public static Object get(String name, Output<String> id, ObjectState state, CustomResourceOptions options)
resources: _: type: restapi:Object get: id: ${id}
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- resource_name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- name
- The unique name of the resulting resource.
- id
- The unique provider ID of the resource to lookup.
- state
- Any extra arguments used during the lookup.
- opts
- A bag of options that control this resource's behavior.
- Api
Data Dictionary<string, string> - Api
Response string - The raw body of the HTTP response from the last read of the object.
- Create
Method string - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - Create
Path string - Create
Response string - The raw body of the HTTP response returned when creating the object.
- Data string
- Valid JSON object that this provider will manage with the API server.
- Debug bool
- Whether to emit verbose debug output while working with the API object on the server.
- Destroy
Data string - Valid JSON object to pass during to destroy requests.
- Destroy
Method string - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - Destroy
Path string - Force
News List<string> - Any changes to these values will result in recreating the resource instead of updating.
- Id
Attribute string - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - Ignore
All boolServer Changes - Ignore
Changes List<string>Tos - Object
Id string - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - Path string
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- Query
String string - Query string to be included in the path
- Read
Data string - Valid JSON object to pass during read requests.
- Read
Method string - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - Read
Path string - Read
Search Dictionary<string, string> - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - Restapi
Object stringId - The ID of this resource.
- Update
Data string - Valid JSON object to pass during to update requests.
- Update
Method string - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - Update
Path string
- Api
Data map[string]string - Api
Response string - The raw body of the HTTP response from the last read of the object.
- Create
Method string - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - Create
Path string - Create
Response string - The raw body of the HTTP response returned when creating the object.
- Data string
- Valid JSON object that this provider will manage with the API server.
- Debug bool
- Whether to emit verbose debug output while working with the API object on the server.
- Destroy
Data string - Valid JSON object to pass during to destroy requests.
- Destroy
Method string - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - Destroy
Path string - Force
News []string - Any changes to these values will result in recreating the resource instead of updating.
- Id
Attribute string - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - Ignore
All boolServer Changes - Ignore
Changes []stringTos - Object
Id string - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - Path string
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- Query
String string - Query string to be included in the path
- Read
Data string - Valid JSON object to pass during read requests.
- Read
Method string - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - Read
Path string - Read
Search map[string]string - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - Restapi
Object stringId - The ID of this resource.
- Update
Data string - Valid JSON object to pass during to update requests.
- Update
Method string - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - Update
Path string
- api
Data Map<String,String> - api
Response String - The raw body of the HTTP response from the last read of the object.
- create
Method String - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create
Path String - create
Response String - The raw body of the HTTP response returned when creating the object.
- data String
- Valid JSON object that this provider will manage with the API server.
- debug Boolean
- Whether to emit verbose debug output while working with the API object on the server.
- destroy
Data String - Valid JSON object to pass during to destroy requests.
- destroy
Method String - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy
Path String - force
News List<String> - Any changes to these values will result in recreating the resource instead of updating.
- id
Attribute String - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore
All BooleanServer Changes - ignore
Changes List<String>Tos - object
Id String - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - path String
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- query
String String - Query string to be included in the path
- read
Data String - Valid JSON object to pass during read requests.
- read
Method String - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read
Path String - read
Search Map<String,String> - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi
Object StringId - The ID of this resource.
- update
Data String - Valid JSON object to pass during to update requests.
- update
Method String - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update
Path String
- api
Data {[key: string]: string} - api
Response string - The raw body of the HTTP response from the last read of the object.
- create
Method string - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create
Path string - create
Response string - The raw body of the HTTP response returned when creating the object.
- data string
- Valid JSON object that this provider will manage with the API server.
- debug boolean
- Whether to emit verbose debug output while working with the API object on the server.
- destroy
Data string - Valid JSON object to pass during to destroy requests.
- destroy
Method string - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy
Path string - force
News string[] - Any changes to these values will result in recreating the resource instead of updating.
- id
Attribute string - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore
All booleanServer Changes - ignore
Changes string[]Tos - object
Id string - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - path string
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- query
String string - Query string to be included in the path
- read
Data string - Valid JSON object to pass during read requests.
- read
Method string - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read
Path string - read
Search {[key: string]: string} - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi
Object stringId - The ID of this resource.
- update
Data string - Valid JSON object to pass during to update requests.
- update
Method string - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update
Path string
- api_
data Mapping[str, str] - api_
response str - The raw body of the HTTP response from the last read of the object.
- create_
method str - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create_
path str - create_
response str - The raw body of the HTTP response returned when creating the object.
- data str
- Valid JSON object that this provider will manage with the API server.
- debug bool
- Whether to emit verbose debug output while working with the API object on the server.
- destroy_
data str - Valid JSON object to pass during to destroy requests.
- destroy_
method str - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy_
path str - force_
news Sequence[str] - Any changes to these values will result in recreating the resource instead of updating.
- id_
attribute str - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore_
all_ boolserver_ changes - ignore_
changes_ Sequence[str]tos - object_
id str - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - path str
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- query_
string str - Query string to be included in the path
- read_
data str - Valid JSON object to pass during read requests.
- read_
method str - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read_
path str - read_
search Mapping[str, str] - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi_
object_ strid - The ID of this resource.
- update_
data str - Valid JSON object to pass during to update requests.
- update_
method str - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update_
path str
- api
Data Map<String> - api
Response String - The raw body of the HTTP response from the last read of the object.
- create
Method String - Defaults to
create_method
set on the provider. Allows per-resource override ofcreate_method
(seecreate_method
provider config documentation) - create
Path String - create
Response String - The raw body of the HTTP response returned when creating the object.
- data String
- Valid JSON object that this provider will manage with the API server.
- debug Boolean
- Whether to emit verbose debug output while working with the API object on the server.
- destroy
Data String - Valid JSON object to pass during to destroy requests.
- destroy
Method String - Defaults to
destroy_method
set on the provider. Allows per-resource override ofdestroy_method
(seedestroy_method
provider config documentation) - destroy
Path String - force
News List<String> - Any changes to these values will result in recreating the resource instead of updating.
- id
Attribute String - Defaults to
id_attribute
set on the provider. Allows per-resource override ofid_attribute
(seeid_attribute
provider config documentation) - ignore
All BooleanServer Changes - ignore
Changes List<String>Tos - object
Id String - Defaults to the id learned by the provider during normal operations and
id_attribute
. Allows you to set the id manually. This is used in conjunction with the*_path
attributes. - path String
- The API path on top of the base URL set in the provider that represents objects of this type on the API server.
- query
String String - Query string to be included in the path
- read
Data String - Valid JSON object to pass during read requests.
- read
Method String - Defaults to
read_method
set on the provider. Allows per-resource override ofread_method
(seeread_method
provider config documentation) - read
Path String - read
Search Map<String> - Custom search for
read_path
. This map will takesearch_data
,search_key
,search_value
,results_key
andquery_string
(see datasource config documentation) - restapi
Object StringId - The ID of this resource.
- update
Data String - Valid JSON object to pass during to update requests.
- update
Method String - Defaults to
update_method
set on the provider. Allows per-resource override ofupdate_method
(seeupdate_method
provider config documentation) - update
Path String
Import
identifier: /
Examples:
$ pulumi import restapi:index/object:Object objects /api/objects
$ pulumi import restapi:index/object:Object object /api/objects/123
To learn more about importing existing cloud resources, see Importing resources.
Package Details
- Repository
- restapi mastercard/terraform-provider-restapi
- License
- Notes
- This Pulumi package is based on the
restapi
Terraform Provider.