Protected
Replaces the mapping definition with the given ID by the new mapping definition you provide.
Use a bare-bones client and the command you need to make an API call.
import { MappingsClient, UpdateMappingCommand } from "@stedi/sdk-client-mappings"; // ES Modules import// const { MappingsClient, UpdateMappingCommand } = require("@stedi/sdk-client-mappings"); // CommonJS importconst client = new MappingsClient(config);const input = { // UpdateMappingInput id: "STRING_VALUE", // required publish: true || false, type: "only_mapped_keys" || "merge_with_target_example" || "pass_through", name: "STRING_VALUE", mapping: "STRING_VALUE", source: { // MappingSource name: "STRING_VALUE", type: "jsonschema@2020-12", // required content: "STRING_VALUE", // required connection: { // MappingDocumentConnection Union: only one key present stediGuides: { // MappingDocumentStediGuidesConnection guideId: "STRING_VALUE", // required guideName: "STRING_VALUE", subGuideName: "STRING_VALUE", ediSampleId: "STRING_VALUE", ediSamplesNames: [ // EDISamplesNames "STRING_VALUE", ], pulledAt: "STRING_VALUE", // required }, stediEvents: { // MappingDocumentStediEventsConnection eventType: "STRING_VALUE", // required guideId: "STRING_VALUE", guideName: "STRING_VALUE", subGuideName: "STRING_VALUE", ediSampleId: "STRING_VALUE", ediSamplesNames: [ "STRING_VALUE", ], pulledAt: "STRING_VALUE", // required }, }, }, target: { // MappingTarget name: "STRING_VALUE", type: "jsonschema@2020-12", // required content: "STRING_VALUE", // required connection: {// Union: only one key present stediGuides: { guideId: "STRING_VALUE", // required guideName: "STRING_VALUE", subGuideName: "STRING_VALUE", ediSampleId: "STRING_VALUE", ediSamplesNames: [ "STRING_VALUE", ], pulledAt: "STRING_VALUE", // required }, stediEvents: { eventType: "STRING_VALUE", // required guideId: "STRING_VALUE", guideName: "STRING_VALUE", subGuideName: "STRING_VALUE", ediSampleId: "STRING_VALUE", ediSamplesNames: [ "STRING_VALUE", ], pulledAt: "STRING_VALUE", // required }, }, }, lookupTables: [ // LookupTables { // LookupTable name: "STRING_VALUE", // required values: [ // LookupTableValues // required { // LookupTableValuesMember "<keys>": "STRING_VALUE", }, ], }, ],};const command = new UpdateMappingCommand(input);const response = await client.send(command);// { // UpdateMappingOutput// id: "STRING_VALUE", // required// name: "STRING_VALUE", // required// mapping: "STRING_VALUE", // required// type: "only_mapped_keys" || "merge_with_target_example" || "pass_through", // required// source: { // MappingSource// name: "STRING_VALUE",// type: "jsonschema@2020-12", // required// content: "STRING_VALUE", // required// connection: { // MappingDocumentConnection Union: only one key present// stediGuides: { // MappingDocumentStediGuidesConnection// guideId: "STRING_VALUE", // required// guideName: "STRING_VALUE",// subGuideName: "STRING_VALUE",// ediSampleId: "STRING_VALUE",// ediSamplesNames: [ // EDISamplesNames// "STRING_VALUE",// ],// pulledAt: "STRING_VALUE", // required// },// stediEvents: { // MappingDocumentStediEventsConnection// eventType: "STRING_VALUE", // required// guideId: "STRING_VALUE",// guideName: "STRING_VALUE",// subGuideName: "STRING_VALUE",// ediSampleId: "STRING_VALUE",// ediSamplesNames: [// "STRING_VALUE",// ],// pulledAt: "STRING_VALUE", // required// },// },// },// target: { // MappingTarget// name: "STRING_VALUE",// type: "jsonschema@2020-12", // required// content: "STRING_VALUE", // required// connection: {// Union: only one key present// stediGuides: {// guideId: "STRING_VALUE", // required// guideName: "STRING_VALUE",// subGuideName: "STRING_VALUE",// ediSampleId: "STRING_VALUE",// ediSamplesNames: [// "STRING_VALUE",// ],// pulledAt: "STRING_VALUE", // required// },// stediEvents: {// eventType: "STRING_VALUE", // required// guideId: "STRING_VALUE",// guideName: "STRING_VALUE",// subGuideName: "STRING_VALUE",// ediSampleId: "STRING_VALUE",// ediSamplesNames: [// "STRING_VALUE",// ],// pulledAt: "STRING_VALUE", // required// },// },// },// lookupTables: [ // LookupTables // required// { // LookupTable// name: "STRING_VALUE", // required// values: [ // LookupTableValues // required// { // LookupTableValuesMember// "<keys>": "STRING_VALUE",// },// ],// },// ],// lockStatus: "unlocked" || "locked", // required// lockingScope: [ // MappingLockScopeList // required// "mapping" || "source" || "target" || "lookup_tables",// ],// lockedBy: "STRING_VALUE",// unpublishedChanges: true || false, // required// publishedAt: "STRING_VALUE",// createdAt: "STRING_VALUE", // required// updatedAt: "STRING_VALUE", // required// };
UpdateMappingCommandInput
UpdateMappingCommandOutput
input
response
config
ResourceNotFoundException (client fault) The server response when the specified resource cannot be found after an API request passes authentication and authorization.
AccessDeniedException (client fault) The server response for authorization failure.
ResourceLockedException (client fault) The server response when the resource is locked and updates are not allowed.
ThrottlingException (client fault) The server response when usage plan or account-level throttling limits exceeded.
UnauthorizedException (client fault) The server response when the authorizer failed to authenticate the caller.
RequestTooLargeException (client fault) The server response for the request too large error.
ResponseTooLargeException (client fault) The server response for the request too large error.
MappingValidationException (client fault) The server cannot process the request due to an apparent client error.
MappingsServiceException
Base exception class for all service exceptions from Mappings service.
Readonly
Static
Replaces the mapping definition with the given ID by the new mapping definition you provide.
Example
Use a bare-bones client and the command you need to make an API call.
Param
UpdateMappingCommandInput
Returns
UpdateMappingCommandOutput
See
input
shape.response
shape.config
shape.Throws
ResourceNotFoundException (client fault) The server response when the specified resource cannot be found after an API request passes authentication and authorization.
Throws
AccessDeniedException (client fault) The server response for authorization failure.
Throws
ResourceLockedException (client fault) The server response when the resource is locked and updates are not allowed.
Throws
ThrottlingException (client fault) The server response when usage plan or account-level throttling limits exceeded.
Throws
UnauthorizedException (client fault) The server response when the authorizer failed to authenticate the caller.
Throws
RequestTooLargeException (client fault) The server response for the request too large error.
Throws
ResponseTooLargeException (client fault) The server response for the request too large error.
Throws
MappingValidationException (client fault) The server cannot process the request due to an apparent client error.
Throws
MappingsServiceException
Base exception class for all service exceptions from Mappings service.